libtool
[Top][All Lists]
Advanced

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

Re: libtool/ltmain linking wrong stdc++


From: Taj Morton
Subject: Re: libtool/ltmain linking wrong stdc++
Date: Mon, 9 Oct 2006 16:42:18 +0000 (UTC)
User-agent: Loom/3.14 (http://gmane.org/)

Mike Frysinger <vapier <at> gentoo.org> writes:
> 
> On Monday 09 October 2006 11:07, Taj Morton wrote:
> > My problem is that I have 2 compilers installed on my computer: gcc-3.4 in
> > /usr (system compiler), and gcc-3.3 in /opt/gcc-3.3.
> 
> what you want to do just wont work regardless of the issue you raise below 
> ... 
> gcc 3.3 and gcc 3.4 have incompatible ABI's so you cannot mix things built 
> with the two compilers as you'll just end up with some things using 
> libstdc++.so.5 while others use libstdc++.so.6
Yes, I know that gcc-3.2/3.3 and gcc 3.4/4.0 have different ABIs. The reason I'm
doing this is to build compatible binaries that can be run on systems with
gcc-3.3 AND on systems with gcc-3.4 (I'm using autopackage, see
www.autopackage.org).

> 
> > I'm not sure where libstdc++.so is being resolved. Any ideas how I can
> > force libstdc++.so to be resolved to the compilers libstdc++?
> 
> this is a feature of libtool and will always cause you problems when you try 
> to mix compilers that use gcc libtool files
> 
> the linker scripts (.la) encode the full path to the actual linker script ... 
> so when you build a C++ app, the .la file will encode the full path to the 
> libstdc++.la file from the gcc compiler that was used to build it
> -mike
The .la file for me libstdc++.so.5 contains no references to /usr/. I have
libdir='/opt/gcc-3.3/lib/.' and dependency_libs contains no -L flags for /usr,
/usr/local, /lib, etc.

Cheers,
Taj






reply via email to

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