This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Shared library annoyance with gcc-3_0-branch


On Wed, Feb 14, 2001 at 12:18:10PM -0800, Joe Buck wrote:
> Brad Lucier writes:
> 
> > ../../../gsc/gsc: error in loading shared libraries: libgcc_s.so.0: cannot open shared object file: No such file or directory
> > 
> > This goes away when I add /export/u10/egcs-test/lib (gcc was installed
> > with prefix /export/u10/egcs-test) to my LD_LIBRARY_PATH.
> 
> > So, are you expecting gcc to be installed in standard places now, or
> > are you expecting people to know about LD_LIBRARY_PATH to use the new
> > gcc, or is this just a bust?
> 
> For C++, it has always been this way, and this should not be surprising.
> Since the compiler does not "wire in" the path by default, shared libraries
> must be in the standard shared library search path, or in LD_LIBRARY_PATH
> for OSes that use that variable.
> 
> The only alternatives are: wire in the path, then you can't give your
> binary to anyone who doesn't have /export/u10/egcs-test/lib on their
> system, go back to a static libgcc, or the present option.
> 
> You could put -R/export/u10/egcs-test/lib on some OSes, or
> -Wl,-R/export/u10/egcs-test/lib on others.  (I think that -R
> should be usable on all OSes that support the concept of wired
> in search path, but I lost that battle).
> 

That is one main reason I don't like shared libgcc. It should be in
the standard place where ld.so will find it and independent of gcc.
We don't want people to install gcc just to get shared libgcc, do we?
It is especially true for Linux.

-- 
H.J. Lu (hjl@valinux.com)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]