[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Problem with '-L' switch.
From: |
Ralf Wildenhues |
Subject: |
Re: Problem with '-L' switch. |
Date: |
Wed, 16 Aug 2006 18:46:31 +0200 |
User-agent: |
Mutt/1.5.12 (2006-08-10) |
Hello Vaclav,
Please keep the mailing list in Cc:. Thanks.
* Vaclav Havlik wrote on Wed, Aug 16, 2006 at 04:28:06PM CEST:
> >
> /bin/sh ~/work/PAS/libtool --debug --tag=CXX --mode=link g++ -Wall -g
> -D_REENTRANT -D_FILE_OFFSET_BITS=64 -pedantic -Wno-long-long -L../../lib
> -L/opt/pas/lib -L/opt/pas/lib64 -L../../lib -L/opt/pas/lib -L/opt/pas/lib64
> -o libPASncl.la -rpath /home/Vaclav/shared/lib -version-info 1:0:0 PASncl.lo
> PASnclThreads.lo PASnclSimple.lo PASnclMt.lo PASnclUtils.lo PASnclQueue.lo
> PASnclSSL.lo CJobNumber.lo -lpas -lssl 1>debug1.txt 2>debug2.txt
[...]
> g++ -shared -nostdlib /usr/lib/gcc/i386-redhat-linux/3.4.5/../../../crti.o
> /usr/lib/gcc/i386-redhat-linux/3.4.5/crtbeginS.o .libs/PASncl.o
> .libs/PASnclThreads.o .libs/PASnclSimple.o .libs/PASnclMt.o
> .libs/PASnclUtils.o .libs/PASnclQueue.o .libs/PASnclSSL.o .libs/CJobNumber.o
> -Wl,--rpath -Wl,/home/Vaclav/work/PAS/lib/.libs -Wl,--rpath
> -Wl,/home/Vaclav/shared/lib -L/usr/lib -L/home/Vaclav/work/PAS/lib/.libs
> -L/home/Vaclav/work/PAS/lib -L/opt/pas/lib -L/opt/pas/lib64
> /home/Vaclav/work/PAS/lib/.libs/libpas.so -lssl
> -L/usr/lib/gcc/i386-redhat-linux/3.4.5
> -L/usr/lib/gcc/i386-redhat-linux/3.4.5/../../.. -lstdc++ -lm -lc -lgcc_s
> /usr/lib/gcc/i386-redhat-linux/3.4.5/crtendS.o
> /usr/lib/gcc/i386-redhat-linux/3.4.5/../../../crtn.o -Wl,-soname
> -Wl,libPASncl.so.1 -o .libs/libPASncl.so.1.0.0
The addition of `-L/usr/lib' is a genuine Libtool bug.
The cause is the non-normalization of the search paths:
> # Compile-time system search path for libraries
> sys_lib_search_path_spec=" /usr/lib/gcc/i386-redhat-linux/3.4.5/
> /usr/lib/gcc/i386-redhat-linux/3.4.5/
> /usr/lib/gcc/i386-redhat-linux/3.4.5/../../../../i386-redhat-linux/lib/i386-redhat-linux/3.4.5/
> /usr/lib/gcc/i386-redhat-linux/3.4.5/../../../../i386-redhat-linux/lib/
> /usr/lib/gcc/i386-redhat-linux/3.4.5/../../../i386-redhat-linux/3.4.5/
> /usr/lib/gcc/i386-redhat-linux/3.4.5/../../../ /lib/i386-redhat-linux/3.4.5/
> /lib/ /usr/lib/i386-redhat-linux/3.4.5/ /usr/lib/"
Note how the above contains `/usr/lib/' instead of `/usr/lib' at the
very end? Please try the following: edit the libtool script, and remove
the final slash. (The sys_lib_search_path_spec is initialized once near
the beginning of the libtool script, and several times at the end, for
C++ and other languages. Edit all instances.) Please report back if
that fixes it.
By the way:
> # Run-time system search path for libraries
> sys_lib_dlsearch_path_spec="/lib /usr/lib include ld.so.conf.d/*.conf
> /usr/X11R6/lib /usr/local/lib "
This should be fixed in a newer Libtool release.
Cheers,
Ralf
- Problem with '-L' switch., Vaclav Havlik, 2006/08/16
- Re: Problem with '-L' switch., Ralf Wildenhues, 2006/08/16
- Message not available
- Re: Problem with '-L' switch.,
Ralf Wildenhues <=
- Re: Problem with '-L' switch., Vaclav Havlik, 2006/08/17
- Re: Problem with '-L' switch., Ralf Wildenhues, 2006/08/17
- Re: Problem with '-L' switch., Vaclav Havlik, 2006/08/17
- Re: Problem with '-L' switch., Ralf Wildenhues, 2006/08/19
- Re: Problem with '-L' switch., Vaclav Havlik, 2006/08/21
- Re: Problem with '-L' switch., Ralf Wildenhues, 2006/08/21
- Re: Problem with '-L' switch., Vaclav Havlik, 2006/08/21