tech-pkg archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: library search path order



On Thu, 21 Feb 2008 04:57:10 +0100
Tobias Nygren <tnn%NetBSD.org@localhost> wrote:

> On Wed, 20 Feb 2008 22:21:19 -0500
> Neil Ludban <nludban%columbus.rr.com@localhost> wrote:
> 
> > Hi,
> > 
> > I'm attempting to use pkgsrc on some Redhat Linux machines at work
> > to keep up with recent releases of various programs (these are
> > production systems, the sysadmins prefer stability over features).
> > I'm able to bootstrap pkgsrc and build a bunch of packages, but they
> > are linked incorrectly any time an older version of a shared library
> > exists in the base system:
> > 
> > $ cd lang/python24
> > $ ldd work/Python-2.4.4/python
> >         libpython2.4.so.1.0 => /usr/lib64/libpython2.4.so.1.0 
> > (0x00000033ac000000)
> >         libpthread.so.0 => /lib64/libpthread.so.0 (0x000000339a200000)
> >         libdl.so.2 => /lib64/libdl.so.2 (0x0000003398e00000)
> >         libdb4-4.5.so.5 => 
> > /home/nludban/_pkg2007Q4_glenn/lib/libdb4-4.5.so.5 (0x00002aaaaaaea000)
> >         libutil.so.1 => /lib64/libutil.so.1 (0x00000033a7c00000)
> >         libm.so.6 => /lib64/libm.so.6 (0x0000003399e00000)
> >         libc.so.6 => /lib64/libc.so.6 (0x0000003399a00000)
> >         /lib64/ld-linux-x86-64.so.2 (0x0000003398a00000)
> > $ ./work/Python-2.4.4/python
> > Python 2.4.3 (#1, Dec 11 2006, 11:39:03) 
> > [GCC 4.1.1 20061130 (Red Hat 4.1.1-43)] on linux2
> > Type "help", "copyright", "credits" or "license" for more information.
> > >>>
> > 
> > 
> > I'm guessing this is caused by the -L/usr/lib64 that's appearing
> > first in the linker flags:
> > 
> > ===> Configuring for python24-2.4.4
> > ...
> > checking LDSHARED... $(CC) -shared -L/usr/lib64 -Wl,-R/usr/lib64 
> > -Wl,-R/home/nludban/_pkg2007Q4_glenn/lib
> > 
> > 
> > I've tried figuring out where these are initially configured but
> > got lost in the maze of wrapper scripts and pkgsrc makefiles.  Can
> > somebody please point me in the right direction?
> > 
> > Thanks-
> > -Neil
> 
> This is probably of relevance:
> 
> http://mail-index.netbsd.org/tech-pkg/2006/06/22/0006.html
> 
> Someone ought to fix that properly, whatever the proper fix is.

Grep'ing for LIBABISUFFIX in mk/* suggests that you may not
run into this problem if you switch to X11_TYPE=modular.


Home | Main Index | Thread Index | Old Index