bug-libtool
[Top][All Lists]
Advanced

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

cannot relink when installing to a DESTDIR


From: Thayne Harbaugh
Subject: cannot relink when installing to a DESTDIR
Date: 07 Jul 2001 13:28:08 -0600

I'm using libtool 1.4 on athlon-plug-linux.

I'm building libgii that has inter-library dependencies.  Everything
builds fine but fails during install.  I'm installing to a DESTDIR such
as "gmake DESTDIR=/tmp/libgii-root install" to capture all of the files
for packaging.  I get these errors during install:

/bin/sh ../mkinstalldirs /tmp/libgii-root/usr/lib
/bin/sh ../libtool  --mode=install /usr/bin/install -c libgii.la
/tmp/libgii-root/usr/lib/libgii.la
libtool: install: warning: relinking `libgii.la'
cd /export/home/tharbaug/rpm/BUILD/libgii-cvs/gii; /bin/sh ../libtool
--mode=relink gcc -O3 -funroll-loops -march=athlon -D_REENTRANT
-D_THREAD_SAFE -g -Wall -o libgii.la -rpath /usr/lib -version-info 0:7
-no-undefined -export-symbols ./EXPSYMS dl.lo gii.lo init.lo unix.lo
../gg/libgg.la
gcc -shared  dl.lo gii.lo init.lo unix.lo  -L/usr/lib -lgg   -Wl,-soname
-Wl,libgii.so.0 -Wl,-retain-symbols-file -Wl,./EXPSYMS -o
.libs/libgii.so.0.0.7
/usr/bin/ld: cannot find -lgg
collect2: ld returned 1 exit status
libtool: install: error: relink `libgii.la' with the above command
before installing it
libtool: install: warning: remember to run `libtool --finish /usr/lib'

Obviously libtool wants to find the dependent libraries in the system
library dirs but the libraries have been installed into /tmp/libgii-root
and can't be found.

This same problem was reported here:

http://www.geocrawler.com/mail/thread.php3?subject=install+phase+fails&list=404

I believe this bug is very significant and shouldn't be overlooked by
saying, "You can't install to a DESTDIR".  The big issue is that all
packaging systems that I know of exploit this feature so that files can
easily be found and enumerated without mixing them with already existing
files in system directories.

A simple patch was posted here:

http://www.linuxarkivet.nu/mlists/debian-devel/0105/msg02183.html

This is incorrect in that the building of lib_add should be reversed as
such:

test -d "$ladir/.libs" && add_dir="-L$ladir/.libs $add_dir"

It's also not very elegant.  It would be nice if there was a command
line switch that notifies libtool of installing to a DESTDIR.

-- 
Thayne Harbaugh




reply via email to

[Prev in Thread] Current Thread [Next in Thread]