gold patch committed: Add --add-needed/--copy-dt-needed-entries options
Ian Lance Taylor
iant@google.com
Tue Jan 5 00:35:00 GMT 2010
For the GNU linker --add-needed aka --copy-dt-needed-entries is the
default. For gold it is not. Implementing --add-needed requires
emulating the dynamic linker's search path, and as I've discussed
elsewhere I don't think that is a good idea.
This patch adds the --add-needed/--copy-dt-needed-entries options to
gold. If they are used and they would otherwise affect gold's output,
gold will give an error. Since the defaults are different, the main
benefit of this patch is that gold now supports --no-add-needed.
Committed to mainline.
Ian
2010-01-04 Ian Lance Taylor <iant@google.com>
PR 10980
* options.h (class General_options): Add --add-needed and
--copy-dt-needed-entries. Tweak --as-needed help entry.
* object.cc (Input_objects::check_dynamic_dependencies): Give an
error if --copy-dt-needed-entries aka --add-needed is used and
would cause a change in behaviour.
More information about the Binutils
mailing list