Hi Cristoph, * Christoph Bartoschek wrote on Sun, Jun 05, 2005 at 06:17:13PM CEST: > > I try to compile KDE on a very old system and have one problem. Let me first > describe the situation:
*snip typical cross compilation situation* > Why does libtool resolve -lstdc++ to /usr/lib/libstdc++.so? As far as > I know each g++ knows where its own libstdc++ resides, such that -lstdc++ > would be more correct. But because g++ also implies -lstdc++ it should > be omitted at all. > > If it is not possible that libtool omits the -lstdc++, how can I achieve > that ROOT/gcc/lib/libstdc++.so is used? Right now I use a dirty hack. > After the configuration step I patch the resulting libtool such that > sys_lib_search_path_spec begins with ROOT/gcc/lib and ROOT/lib. > > What is the correct way to force libtool to always first search in ROOT/lib > and ROOT/gcc/lib? One Right Way[tm] would be to add some kind of DESTDIR support for link time (or even compile time) already. So that every path would be prefixed with it if not already. Then you'd only also need to fix the rpaths for the installed libraries and convince the linker to override the rpaths for the installed libs you link against (and strip off the prefix for Libtool's library search). Exploiting $ORIGIN where available comes to mind as well,... Basically. I don't know if that would be The Right Way[tm]. :) There have been several similar requests/bug reports like yours. It's also listed in TODO. It would be great if someone could work on this (for CVS HEAD). :) Cheers, Ralf _______________________________________________ http://lists.gnu.org/mailman/listinfo/libtool