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

Re: help: disabling relinking stupidity in libtool

Nope, it seems that patching libtool in that way ends up causing unresolved symbols when linking some of the libraries the first time around.

Matthew Garrett wrote:
I have the following in the configure.in for one of my projects - it
needs to be able to cross-compile, and libtool kept trying to link x86
libraries into my ARM code because there happened to be a library of
that name in /usr/lib. Sigh. (I actually gave up on libtool in the end
because it refuses to support linking .a files into dynamic libraries as
it's not portable, despite me only ever needing this part of the build
to work on Linux. I /could/ rewrite my entire build system to do things
the libtool way, but instead I decided to just do stuff by hand :) )

AC_MSG_RESULT(patching libtool to fix HIDEOUS BREAKAGE)
test -f libtool.old || (mv libtool libtool.old && cp libtool.old
sed -e s/^hardcode_direct.*$/hardcode_direct=yes/g libtool | \
sed -e s/^hardcode_minus_L.*$/hardcode_minus_L=yes/g | \
sed -e s/^hardcode_shlibpath_var.*$/hardcode_shlibpath_var=no/g >libtool.new mv libtool.new libtool

Doubtless this breaks stuff somewhere else, but it seems to have the
desired effect...

Reply to: