This is the mail archive of the gcc-help@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]

Adding '-R' to specs file


Okay, this is really frustrating.  I am compiling a bunch of software
for one of my projects at work.  The problem is that I am running into
run-time errors because some of the apps cannot locate shared libraries
that are installed in /usr/local/lib.  If I prefix the command with
LD_LIBRARY_PATH=/usr/local/lib, they tend to work, but I really don't
want to use LD_LIBRARY_PATH -- it's such a kludge and because it does
not get passed by sudo, it's such an inconvenience when I need to start
daemons.

I have read the FAQ on the egcs web site that explains why the -R option
is not included by default, and I can understand the reasoning.  The FAQ
goes on to explain that it is possible to modify the specs file to
include libraries in the run path automatically, but it does not explain
how to do it.  I read through the docs with respect to the specs file
and it might have well had been written in Chinese.

I am spending way too much time compiling (and recompiling) software.  I
have little time to work on this project as it is; I would rather not
spend all my time fighting just to get the software to run.  Can someone
please explain how to have gcc automatically add "-L /usr/local/lib -R
/usr/local/lib" at link time using the specs file?

Why isn't /usr/local/lib included as a "standard" place to find things
anyway?


Sent via Deja.com http://www.deja.com/
Before you buy.


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