The following changes avoid polluting global namespace with the
[deliverable/binutils-gdb.git] / ld / ld.texinfo
index 354d2a745b4b6619eac7893d3e7a118ff325d3c6..b763dfe39675f9e678e598b183a350cf4e8c9766 100644 (file)
@@ -52,7 +52,8 @@ END-INFO-DIR-ENTRY
 @ifinfo
 This file documents the @sc{gnu} linker LD version @value{VERSION}.
 
-Copyright (C) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000 Free Software Foundation, Inc.
+Copyright (C) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000,
+2001 Free Software Foundation, Inc.
 
 @ignore
 
@@ -444,6 +445,10 @@ back to the symbols defined by the program, rather than some other
 dynamic object, then you will probably need to use this option when
 linking the program itself.
 
+You can also use the version script to control what symbols should
+be added to the dynamic symbol table if the output format supports it.
+See the description of @samp{--version-script} in @ref{VERSION}.
+
 @cindex big-endian objects
 @cindex endianness
 @kindex -EB
@@ -697,6 +702,12 @@ If this option is not specified, an absolute file is produced.  When
 linking C++ programs, this option @emph{will not} resolve references to
 constructors; to do that, use @samp{-Ur}.
 
+When an input file does not have the same format as the output file,
+partial linking is only supported if that input file does not contain any
+relocations.  Different output formats can have further restrictions; for
+example some @code{a.out}-based formats do not support partial linking
+with input files in other formats at all.
+
 This option does the same thing as @samp{-i}.
 
 @kindex -R @var{file}
@@ -966,6 +977,7 @@ demangle by default unless the environment variable @samp{COLLECT_NO_DEMANGLE}
 is set.  These options may be used to override the default.
 
 @cindex dynamic linker, from command line
+@kindex -I@var{file}
 @kindex --dynamic-linker @var{file}
 @item --dynamic-linker @var{file}
 Set the name of the dynamic linker.  This is only meaningful when
@@ -2213,7 +2225,7 @@ SECTIONS
       *(.text)
       _etext = .;
     @}
-  _bdata = (. + 3) & ~ 4;
+  _bdata = (. + 3) & ~ 3;
   .data : @{ *(.data) @}
 @}
 @end smallexample
@@ -3536,6 +3548,17 @@ within the shared library, you can use the aliases of convenience
 (i.e. @samp{old_foo}), or you can use the @samp{.symver} directive to
 specifically bind to an external version of the function in question.
 
+You can also specify the language in the version script:
+
+@smallexample
+VERSION extern "lang" @{ version-script-commands @}
+@end smallexample
+
+The supported @samp{lang}s are @samp{C}, @samp{C++}, and @samp{Java}. 
+The linker will iterate over the list of symbols at the link time and
+demangle them according to @samp{lang} before matching them to the
+patterns specified in @samp{version-script-commands}.
+
 @node Expressions
 @section Expressions in Linker Scripts
 @cindex expressions
This page took 0.024938 seconds and 4 git commands to generate.