This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: modifying ld options in the enviroment
- From: Nick Clifton <nickc at redhat dot com>
- To: Marty Leisner <leisner at rochester dot rr dot com>
- Cc: binutils at sources dot redhat dot com
- Date: Sun, 15 May 2005 17:52:44 +0100
- Subject: Re: modifying ld options in the enviroment
- References: <200505142045.j4EKjkgG002877@dell.home>
Hi Marty,
I inserted a environemnt variable
LD_ENV_OPTIONS
which allows you to inject options into ld
This is wrt 2.16 -- I've had this for a few years...I've found it
very useful...I'm thinking of duplicating something like this for gcc...
The big problem with this approach, and the reason why it has been
rejected before (both for ld and gcc) is that it makes reproducing a bug
much harder. Unless you remember that the environment variable has been
set, (assuming that you know about it, quite often this kind of thing is
done for you in a system wide initialisation script), then you might not
report it when submitting a bug report or take it into consideration
when investigating a bug.
Using wrapper scripts also has the same problem. By far the best way is
to spend the effort to create a good build environment where extra
linker command line switches can be set on the build command line.
Cheers
Nick