On Tue, 14 Jul 2009, Lorenzo Bettini wrote:
I was trying to build, in linux, a completely static executable that uses
libboost_regex;
I issued
configure LDFLAGS="-static"
make LDFLAGS="-all-static"
but when it comes to linking I get this error:
/bin/bash ../libtool --tag=CXX --mode=link g++ -g -O2 -L/usr/lib
-all-static -o check-regexp check-regexp_cmd.o check-regexp.o -lboost_regex
../gl/libgnu.la
libtool: link: g++ -g -O2 -static -o check-regexp check-regexp_cmd.o
check-regexp.o -L/usr/lib -lboost_regex ../gl/.libs/libgnu.a
/usr/lib/libboost_regex.a(static_mutex.o): In function
`boost::scoped_static_mutex_lock::unlock()':
what am I doing wrong?
Your project is lacking a dependency on the thread library. When
static linking, all the libraries that your library depends on need to
be listed.
Bob
--
Bob Friesenhahn
bfrie...@simple.dallas.tx.us, http://www.simplesystems.org/users/bfriesen/
GraphicsMagick Maintainer, http://www.GraphicsMagick.org/
_______________________________________________
http://lists.gnu.org/mailman/listinfo/libtool