aboutsummaryrefslogtreecommitdiff
path: root/ld/ld.texinfo
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2000-01-07 19:06:46 +0000
committerNick Clifton <nickc@redhat.com>2000-01-07 19:06:46 +0000
commit4e53152f8faf67e5af38e7b8e755113ea1719124 (patch)
treec76948704a7d4e607a8b716e853d1119c43d15ca /ld/ld.texinfo
parentc3f6f71df382eaaaac4440a91e6f310d03fb8da6 (diff)
downloadfsf-binutils-gdb-4e53152f8faf67e5af38e7b8e755113ea1719124.zip
fsf-binutils-gdb-4e53152f8faf67e5af38e7b8e755113ea1719124.tar.gz
fsf-binutils-gdb-4e53152f8faf67e5af38e7b8e755113ea1719124.tar.bz2
Remind users about -Wl,
Diffstat (limited to 'ld/ld.texinfo')
-rw-r--r--ld/ld.texinfo14
1 files changed, 14 insertions, 0 deletions
diff --git a/ld/ld.texinfo b/ld/ld.texinfo
index 382dd7e..9b822bd 100644
--- a/ld/ld.texinfo
+++ b/ld/ld.texinfo
@@ -228,6 +228,20 @@ requires them. For example, @samp{--oformat srec} and
@samp{--oformat=srec} are equivalent. Unique abbreviations of the names
of multiple-letter options are accepted.
+Note - if the linker is being invoked indirectly, via a compiler driver
+(eg @samp{gcc}) then all the linker command line options should be
+prefixed by @samp{-Wl,} like this:
+
+@smallexample
+ gcc -Wl,--startgroup foo.o bar.o -Wl,--endgroup
+@end smallexample
+
+This is important, because otherwise the compiler driver program may
+silently drop the linker options, resulting in a bad link.
+
+Here is a table of the generic command line switches accepted by the GNU
+linker:
+
@table @code
@kindex -a@var{keyword}
@item -a@var{keyword}