[OpenAFS] libafsauthent.so and libresolv.so

Andrej Filipcic andrej.filipcic@ijs.si
Sat, 21 Aug 2010 14:23:17 +0200


when building shared libraries (openafs, the 
/usr/lib64/libafsauthent.so.1.1 is missing the libresolv.so:
af ~ # ldd /usr/lib64/libafsauthent.so.1.1
        linux-vdso.so.1 =>  (0x00007fff723ff000)
        libafsrpc.so.1 => /usr/lib/libafsrpc.so.1 (0x00007fcd9cdf1000)
        libpthread.so.0 => /lib/libpthread.so.0 (0x00007fcd9cbd5000)
        libc.so.6 => /lib/libc.so.6 (0x00007fcd9c87b000)
        /lib64/ld-linux-x86-64.so.2 (0x00007fcd9d30f000)

Several packages using the openafs libraries are trying the following in 

# cat > conftest.c <<EOF
extern int ka_GetAFSTicket (); 
int main() { ka_GetAFSTicket (); return 0; }
# gcc conftest.c -o conftest -lafsauthent
/usr/lib64/libafsauthent.so: undefined reference to `__res_search'
/usr/lib64/libafsauthent.so: undefined reference to `__dn_expand

My question is where is the problem? Should other packages add -lresolv in 
conftest or should the libafsauthent.so be built with "-lresolv"?
If the second is true, all the *_linux* lines in src/cf/osconf.m4 should use 
MT_LIBS="-lpthread -lresolv"


   prof. dr. Andrej Filipcic,   E-mail: Andrej.Filipcic@ijs.si
   Department of Experimental High Energy Physics - F9
   Jozef Stefan Institute, Jamova 39, P.o.Box 3000
   SI-1001 Ljubljana, Slovenia
   Tel.: +386-1-477-3674    Fax: +386-1-425-7074