On Jun 14, 2011, at 8:06 PM, Christopher Samuel wrote:

>> Chris -- can you try linking this simple app to see if
>> it causes the linker error, and further try adding
>> -lresolv to see if that fixes the error?
> 
> Yup - that does it and the error confirms the symbol
> that is causing this odd behaviour in libpci.a.
> 
> $ gcc -o conftest conftest.c -lpci
> /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/libpci.a(names-net.o):
>  In function `pci_id_net_lookup':
> (.text+0x1bc): undefined reference to `__res_query'
> collect2: ld returned 1 exit status
> $
> 
> $ gcc -o conftest conftest.c -lpci -lresolv
> $
> 
> Same behaviour on both RHEL 5.6 and CentOS 5.6 (as you'd
> hope for!).

Ok, good.  I'll see if I can code this up.

...done.  Try a nightly trunk tarball >=r3516 (new nightly should be made in 
about 6 hours).

>> FWIW, on my RHEL 5 machine (with only libpci.a), both
>> link commands seem to work (but my libpci.a doesn't
>> have a __res_query symbol).
> 
> Hmm, which release of RHEL5 is that ?

[11:47] svbu-mpi:~ % nm /usr/lib/libpci.a | grep res_query
[11:47] svbu-mpi:~ % nm /usr/lib64/libpci.a | grep res_query
[11:47] svbu-mpi:~ % cat /etc/issue
Red Hat Enterprise Linux Server release 5.4 (Tikanga)
Kernel \r on an \m

[11:47] svbu-mpi:~ %

-- 
Jeff Squyres
jsquy...@cisco.com
For corporate legal information go to:
http://www.cisco.com/web/about/doing_business/legal/cri/


Reply via email to