[Top][All Lists]

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

Re: relinking error

From: Monty Taylor
Subject: Re: relinking error
Date: Fri, 05 Mar 2010 10:01:15 -0800
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv: Gecko/20100222 Thunderbird/3.0.1

On 03/05/2010 09:26 AM, Monty Taylor wrote:

I've got an install-time re-linking error happening in two different
projects now, and it's confusing me. (GNU libtool) 2.2.6b
automake (GNU automake) 1.11.1

The simple case where it's happening is in libcassandra. We have to
lib_LTLIBRARIES defined, and

lib_LTLIBRARIES+= libcassandra/
lib_LTLIBRARIES+= libgenthrift/

As a follow up, if I reverse the order of the above declaration to:

lib_LTLIBRARIES+= libgenthrift/
lib_LTLIBRARIES+= libcassandra/

It works. So it does seem to be that install doesn't pay attention to dependency information here.

Additionally, libcassandra uses libgenthrift:

libcassandra_libcassandra_la_DEPENDENCIES= libgenthrift/
libcassandra_libcassandra_la_LIBADD= libgenthrift/

All works fine in tree. When we try to run make install, however, it
doesn't seem to grok dependency order and tries to install and re-link
libcassandra first - but of course has not yet been
installed into the install dir, so there is a re-link error.

Here's the output from the simple project.

address@hidden:~/tmp/libcassandra$ make install
make install-recursive
make[1]: Entering directory `/home/posulliv/tmp/libcassandra'
make[2]: Entering directory `/home/posulliv/tmp/libcassandra'
make[3]: Entering directory `/home/posulliv/tmp/libcassandra'
test -z "/usr/local/lib" || /bin/mkdir -p "/usr/local/lib"
/bin/bash ./libtool --mode=install /usr/bin/install -c
libcassandra/ libgenthrift/
libtool: install: warning: relinking `libcassandra/'
libtool: install: (cd /home/posulliv/tmp/libcassandra; /bin/bash
/home/posulliv/tmp/libcassandra/libtool --silent --tag CXX
--mode=relink g++ -pipe -std=gnu++0x -O3 -pedantic -Wall -Wundef
-Wshadow -fdiagnostics-show-option -fvisibility=hidden -Wformat
-fno-strict-aliasing -Wno-strict-aliasing -Wextra -Woverloaded-virtual
-Wnon-virtual-dtor -Wctor-dtor-privacy -Wno-long-long
-Wmissing-declarations -Wredundant-decls -I/usr/local/include/thrift
-Wno-conversion -version-info 1:0:0 -o libcassandra/
-rpath /usr/local/lib
libgenthrift/ -lrt )
/usr/bin/ld: cannot find -lgenthrift
collect2: ld returned 1 exit status
libtool: install: error: relink `libcassandra/' with
the above command before installing it
make[3]: *** [install-libLTLIBRARIES] Error 1
make[3]: Leaving directory `/home/posulliv/tmp/libcassandra'
make[2]: *** [install-am] Error 2
make[2]: Leaving directory `/home/posulliv/tmp/libcassandra'
make[1]: *** [install-recursive] Error 1
make[1]: Leaving directory `/home/posulliv/tmp/libcassandra'
make: *** [install] Error 2

Is there a declarative something I've missed or some other way around
this? I feel like I've got to be doing something stoopid if I can't get
a tree to install two shared libs with a depend properly. :)


reply via email to

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