ld: improve linker script section
commit93304b1fe865343eed40219bf37c32191c9e205b
authorMike Frysinger <vapier@gentoo.org>
Tue, 20 Jul 2010 19:25:42 +0000 (20 19:25 +0000)
committerMike Frysinger <vapier@gentoo.org>
Tue, 20 Jul 2010 19:25:42 +0000 (20 19:25 +0000)
tree9a990f1c6ca9e4d211d1a6415e7b6b6974550c2d
parentfe58de404e6f2d451880714526c8ca3b8d733187
ld: improve linker script section

The example version script in the manual currently suggests:
extern "C++" { "int f(int, double)"; }

But a C++ function like that doesn't encode the return type into the
mangled  name, so when the linker demangles things, it ends up with
"f(int, double)"  and so it never matches.

The example also lacks a trailing semicolon after the brace, so the
linker always complains about a syntax error in the file.

While the language section documents the possibilities, it isn't clear
as to which is the default language.  So explicitly state that the C
language is the default.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
ld/ChangeLog
ld/ld.texinfo