[LLVMdev] Problems building cfrontend 4 source on SUSE 10.1

Reid Spencer rspencer at reidspencer.com
Mon Nov 6 12:50:36 PST 2006


Hi Scooter,

On Mon, 2006-11-06 at 12:07 -0800, Scott Michel wrote:
> Reid Spencer wrote:
> > This is an libpath problem.  When xgcc runs it wants to dynamically linkthe libgcc.so.
> > When you run it from the command line it will find yoursystem
> libgcc.so (which works)
> 
> Not really. For systems that have gcc 4.2 natively installed, like the
> current Debian testing, the compiler gets GCC_4.2.0 version errors. It
> isn't easy to work around b/c xgcc wants to link in the 4.2 version of
> the library.

You're right. If your system GCC is > 4.0.1 then linking to the system
library could cause problems (i.e. the command line xgcc run won't
work). In the instant case, that isn't the situation because the command
line xgcc did work.  Either way, setting LD_LIBRARY_PATH appropriately
for the command line run should fix this and allow the original problem
(segfault) to appear. 

The original question was about how to reproduce an error which is only
tangentially related to accidentally linking xgcc to a newer libgcc.so. 

> 
> Basically, this is a "me too!"

I've run into this too, but it doesn't come up in practice if llvm-gcc
would just build properly :)

Reid.





More information about the llvm-dev mailing list