Including -R /usr/local/lib?
Martin von Loewis
martin@mira.isdn.cs.tu-berlin.de
Sat Apr 18 16:05:00 GMT 1998
> It seems like the g++ command should know where libstdc++ is, and
> automatically add the `-R /usr/local/lib' business for the user.
> Is there an option or environment setting for configure that I
> can use to get egcs to automatically add the `-R /usr/local/lib'?
I believe this has been discussed in the past, you may want to search
the list archives. I would dislike g++ automatically adding -R options
to the binary. That way, you get binaries that work only on the
machine you compile on, and not on any other Solaris machine.
I recommend to use either of two solutions:
- configure egcs with --disable-shared, so you'll link libstdc++
statically. This seems reasonable especially since the ABI of
g++ is in the permanent state of flux (I believe since g++ 1).
- add the -R option to the spec file after installation. This is
what we do in-house; we also add /usr/local/X11/lib. Since this
is a site-specific configuration, I would not want g++ to do
it by default.
Regards,
Martin
More information about the Gcc
mailing list