This is the mail archive of the
cygwin
mailing list for the Cygwin project.
minires undefined '___res_search'
- From: King Lung Chiu <csklc at farrer dot hpc dot csiro dot au>
- To: Cygwin Mailing List <cygwin at cygwin dot com>
- Date: Wed, 11 Feb 2004 15:18:54 +1100 (EST)
- Subject: minires undefined '___res_search'
Hi,
I'm trying to port some code (KX509) to cygwin that needs to use librsolv.
I've installed minires-devl-0.98-1, but make (of KX509) always fails with
'undefined reference to '___res_search' and '___dn_expand':
...
gcc -o kx509 -g -O2 -DUSE_KRB5 kx509.o debug.o getcert.o\
get_kca_list.o
get_realm.o store_in_cc.o store_tkt.o ../lib/libkx.a -L/usr/lib -L/usr
-lcrypto -L/opt/krb5-1.3.1//lib -lkrb5 -lk5crypto -lcom_err
get_kca_list.o(.text+0xf9): In function `get_kca_list':
/opt/src/kx509/cygwin_w2k/client/../../src/client/get_kca_list.c:266:
undefined reference to `___res_search'
get_kca_list.o(.text+0x174):/opt/src/kx509/cygwin_w2k/client/../../src/\
client/get_kca_list.c:294: undefined reference to `___dn_expand'
...
collect2: ld returned 1 exit status
make[1]: *** [kx509] Error 1
make[1]: Leaving directory `/opt/src/kx509/cygwin_w2k/client'
I've set up the lib links as follows:
$ cd /usr/lib; ls -l libresolv* libminires.*
-rwxrwxrwx 1 guest Users 453200 Jan 22 11:45 libminires.a
-rwxrwxrwx 1 guest Users 21784 Jan 22 11:45 libminires.dll.a
lrwxrwxrwx 1 guest Users 135 Feb 10 12:20 libresolv.dll.a ->
/usr/lib/libminires.dll.a
lrwxrwxrwx 1 guest Users 127 Feb 11 13:22 libresolv.a ->
/usr/lib/libminires.a
and the libraries seem to have the required functions:
$ nm -s libresolv.dll.a | grep ___res_search
___res_search in d000016.o
__imp____res_search in d000016.o
00000000 T ___res_search
00000000 I __imp____res_search
$ nm -s libresolv.a | grep ___res_search
___res_search in minires.o
00001b78 T ___res_search
So how can I make gcc find ___res_search and ___dn_expand? Did I miss
something?
regards
King Lung Chiu
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/