diff options
| author | sandra <sandra@138bc75d-0d04-0410-961f-82ee72b054a4> | 2009-02-25 01:44:45 +0000 |
|---|---|---|
| committer | sandra <sandra@138bc75d-0d04-0410-961f-82ee72b054a4> | 2009-02-25 01:44:45 +0000 |
| commit | 95e9d9cdaae16c7f2852fa176b5ad0899096eb27 (patch) | |
| tree | ba04787445c6bbba14464d73e553971b9ff74b09 | |
| parent | 8ea26fd570d092fd885d14ae14e7020267fe5097 (diff) | |
| download | ppe42-gcc-95e9d9cdaae16c7f2852fa176b5ad0899096eb27.tar.gz ppe42-gcc-95e9d9cdaae16c7f2852fa176b5ad0899096eb27.zip | |
2009-02-24 Sandra Loosemore <sandra@codesourcery.com>
gcc/
* doc/invoke.texi (Link Options): Document an easier way to pass
options that take arguments to the GNU linker using -Xlinker and
-Wl.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@144423 138bc75d-0d04-0410-961f-82ee72b054a4
| -rw-r--r-- | gcc/ChangeLog | 6 | ||||
| -rw-r--r-- | gcc/doc/invoke.texi | 15 |
2 files changed, 19 insertions, 2 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index d7b5d37d47f..fb344c85692 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2009-02-24 Sandra Loosemore <sandra@codesourcery.com> + + * doc/invoke.texi (Link Options): Document an easier way to pass + options that take arguments to the GNU linker using -Xlinker and + -Wl. + 2009-02-24 Steve Ellcey <sje@cup.hp.com> PR target/33785 diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index f12124ccdc1..75acf036150 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -8042,17 +8042,28 @@ Pass @var{option} as an option to the linker. You can use this to supply system-specific linker options which GCC does not know how to recognize. -If you want to pass an option that takes an argument, you must use +If you want to pass an option that takes a separate argument, you must use @option{-Xlinker} twice, once for the option and once for the argument. For example, to pass @option{-assert definitions}, you must write @samp{-Xlinker -assert -Xlinker definitions}. It does not work to write @option{-Xlinker "-assert definitions"}, because this passes the entire string as a single argument, which is not what the linker expects. +When using the GNU linker, it is usually more convenient to pass +arguments to linker options using the @option{@var{option}=@var{value}} +syntax than as separate arguments. For example, you can specify +@samp{-Xlinker -Map=output.map} rather than +@samp{-Xlinker -Map -Xlinker output.map}. Other linkers may not support +this syntax for command-line options. + @item -Wl,@var{option} @opindex Wl Pass @var{option} as an option to the linker. If @var{option} contains -commas, it is split into multiple options at the commas. +commas, it is split into multiple options at the commas. You can use this +syntax to pass an argument to the option. +For example, @samp{-Wl,-Map,output.map} passes @samp{-Map output.map} to the +linker. When using the GNU linker, you can also get the same effect with +@samp{-Wl,-Map=output.map}. @item -u @var{symbol} @opindex u |

