Hello Adam,

* Adam Nielsen wrote on Wed, Jan 21, 2009 at 12:32:57PM CET:
> x86_64-pc-linux-gnu/bin/ld: 
> .../lib64/libboost_system-mt-1_37.a(error_code.o): relocation 
> R_X86_64_32S against `a local symbol' can not be used when making a  
> shared object; recompile with -fPIC
> .../lib64/libboost_system-mt-1_37.a: could not read symbols: Bad value

Please post the full command that causes this (libtool --mode=link ...)
including all of its output.

> lib_LTLIBRARIES = libtest.la
> libtest_la_SOURCES = main.cpp $(top_srcdir)/include/gamearchive.hpp
> libtest_la_CPPFLAGS = $(BOOST_CPPFLAGS)
> libtest_la_LDFLAGS = $(BOOST_SYSTEM_LDFLAGS) $(BOOST_FILESYSTEM_LDFLAGS)
> libtest_la_LIBADD = $(BOOST_SYSTEM_LIBS) $(BOOST_FILESYSTEM_LIBS)
>
> The $(BOOST_*) variables are set by the "boost.m4" file from the Boost  
> website.  This does work fine if I use $(BOOST_*) in my executable, but 
> it doesn't work with the shared library.

Please post an URL to the macro file you have downloaded (IIRC there is
more than one set of such macros).  It may be necessary to also see the
output of configure and/or parts of config.log in order to fully
understand what's going on, but I'll be able to ask more specific
questions with the information asked above.

Thanks,
Ralf


Reply via email to