Ignore:
Timestamp:
Aug 16, 2003, 6:59:22 PM (22 years ago)
Author:
bird
Message:

binutils v2.14 - offical sources.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/GNU/src/binutils/ld/ld.info-3

    • Property cvs2svn:cvs-rev changed from 1.1 to 1.1.1.2
    r608 r609  
    1 This is ld.info, produced by makeinfo version 4.0 from ./ld.texinfo.
     1This is ld.info, produced by makeinfo version 4.3 from ./ld.texinfo.
    22
    33START-INFO-DIR-ENTRY
     
    55END-INFO-DIR-ENTRY
    66
    7    This file documents the GNU linker LD version 2.11.2.
    8 
    9    Copyright (C) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000 Free
    10 Software Foundation, Inc.
     7   This file documents the GNU linker LD version 2.14.
     8
     9   Copyright (C) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001,
     102002, 2003 Free Software Foundation, Inc.
    1111
    1212
     
    1717
    1818   You can change the behavior of `ld' with the environment variables
    19 `GNUTARGET', `LDEMULATION', and `COLLECT_NO_DEMANGLE'.
     19`GNUTARGET', `LDEMULATION' and `COLLECT_NO_DEMANGLE'.
    2020
    2121   `GNUTARGET' determines the input-file object format if you don't use
     
    255255File: ld.info,  Node: Entry Point,  Next: File Commands,  Up: Simple Commands
    256256
    257 Setting the entry point
     257Setting the Entry Point
    258258-----------------------
    259259
     
    279279File: ld.info,  Node: File Commands,  Next: Format Commands,  Prev: Entry Point,  Up: Simple Commands
    280280
    281 Commands dealing with files
     281Commands Dealing with Files
    282282---------------------------
    283283
     
    303303     option.
    304304
    305      The linker will first try to open the file in the current
    306      directory.  If it is not found, the linker will search through the
    307      archive library search path.  See the description of `-L' in *Note
    308      Command Line Options: Options.
     305     In case a "sysroot prefix" is configured, and the filename starts
     306     with the `/' character, and the script being processed was located
     307     inside the "sysroot prefix", the filename will be looked for in
     308     the "sysroot prefix".  Otherwise, the linker will try to open the
     309     file in the current directory.  If it is not found, the linker
     310     will search through the archive library search path.  See the
     311     description of `-L' in *Note Command Line Options: Options.
    309312
    310313     If you use `INPUT (-lFILE)', `ld' will transform the name to
     
    350353File: ld.info,  Node: Format Commands,  Next: Miscellaneous Commands,  Prev: File Commands,  Up: Simple Commands
    351354
    352 Commands dealing with object file formats
     355Commands Dealing with Object File Formats
    353356-----------------------------------------
    354357
     
    359362     The `OUTPUT_FORMAT' command names the BFD format to use for the
    360363     output file (*note BFD::).  Using `OUTPUT_FORMAT(BFDNAME)' is
    361      exactly like using `-oformat BFDNAME' on the command line (*note
     364     exactly like using `--oformat BFDNAME' on the command line (*note
    362365     Command Line Options: Options.).  If both are used, the command
    363366     line option takes precedence.
     
    392395File: ld.info,  Node: Miscellaneous Commands,  Prev: Format Commands,  Up: Simple Commands
    393396
    394 Other linker script commands
     397Other Linker Script Commands
    395398----------------------------
    396399
     
    412415     to make `ld' assign space to common symbols even if a relocatable
    413416     output file is specified (`-r').
     417
     418`INHIBIT_COMMON_ALLOCATION'
     419     This command has the same effect as the `--no-define-common'
     420     command-line option: to make `ld' omit the assignment of addresses
     421     to common symbols even for a non-relocatable output file.
    414422
    415423`NOCROSSREFS(SECTION SECTION ...)'
     
    495503           _etext = .;
    496504         }
    497        _bdata = (. + 3) & ~ 4;
     505       _bdata = (. + 3) & ~ 3;
    498506       .data : { *(.data) }
    499507     }
     
    540548File: ld.info,  Node: SECTIONS,  Next: MEMORY,  Prev: Assignments,  Up: Scripts
    541549
    542 SECTIONS command
     550SECTIONS Command
    543551================
    544552
     
    595603File: ld.info,  Node: Output Section Description,  Next: Output Section Name,  Up: SECTIONS
    596604
    597 Output section description
     605Output Section Description
    598606--------------------------
    599607
     
    626634File: ld.info,  Node: Output Section Name,  Next: Output Section Address,  Prev: Output Section Description,  Up: SECTIONS
    627635
    628 Output section name
     636Output Section Name
    629637-------------------
    630638
     
    645653File: ld.info,  Node: Output Section Address,  Next: Input Section,  Prev: Output Section Name,  Up: SECTIONS
    646654
    647 Output section address
    648 ----------------------
     655Output Section Description
     656--------------------------
    649657
    650658   The ADDRESS is an expression for the VMA (the virtual memory
     
    687695File: ld.info,  Node: Input Section,  Next: Output Section Data,  Prev: Output Section Address,  Up: SECTIONS
    688696
    689 Input section description
     697Input Section Description
    690698-------------------------
    691699
     
    709717File: ld.info,  Node: Input Section Basics,  Next: Input Section Wildcards,  Up: Input Section
    710718
    711 Input section basics
     719Input Section Basics
    712720....................
    713721
     
    737745The difference between these is the order in which the `.text' and
    738746`.rdata' input sections will appear in the output section.  In the
    739 first example, they will be intermingled.  In the second example, all
    740 `.text' input sections will appear first, followed by all `.rdata'
    741 input sections.
     747first example, they will be intermingled, appearing in the same order as
     748they are found in the linker input.  In the second example, all `.text'
     749input sections will appear first, followed by all `.rdata' input
     750sections.
    742751
    743752   You can specify a file name to include sections from a particular
     
    762771File: ld.info,  Node: Input Section Wildcards,  Next: Input Section Common,  Prev: Input Section Basics,  Up: Input Section
    763772
    764 Input section wildcard patterns
     773Input Section Wildcard Patterns
    765774...............................
    766775
     
    832841File: ld.info,  Node: Input Section Common,  Next: Input Section Keep,  Prev: Input Section Wildcards,  Up: Input Section
    833842
    834 Input section for common symbols
     843Input Section for Common Symbols
    835844................................
    836845
     
    864873File: ld.info,  Node: Input Section Keep,  Next: Input Section Example,  Prev: Input Section Common,  Up: Input Section
    865874
    866 Input section and garbage collection
     875Input Section and Garbage Collection
    867876....................................
    868877
     
    875884File: ld.info,  Node: Input Section Example,  Prev: Input Section Keep,  Up: Input Section
    876885
    877 Input section example
     886Input Section Example
    878887.....................
    879888
     
    908917File: ld.info,  Node: Output Section Data,  Next: Output Section Keywords,  Prev: Input Section,  Up: SECTIONS
    909918
    910 Output section data
     919Output Section Data
    911920-------------------
    912921
     
    938947stored in the endianness of the first input object file.
    939948
    940    Note - these commands only work inside a section description and not
     949   Note--these commands only work inside a section description and not
    941950between them, so the following will produce an error from the linker:
    942951     SECTIONS { .text : { *(.text) } LONG(1) .data : { *(.data) } }
     
    948957otherwise unspecified regions of memory within the section (for example,
    949958gaps left due to the required alignment of input sections) are filled
    950 with the two least significant bytes of the expression, repeated as
    951 necessary.  A `FILL' statement covers memory locations after the point
    952 at which it occurs in the section definition; by including more than
    953 one `FILL' statement, you can have different fill patterns in different
    954 parts of an output section.
     959with the value of the expression, repeated as necessary.  A `FILL'
     960statement covers memory locations after the point at which it occurs in
     961the section definition; by including more than one `FILL' statement,
     962you can have different fill patterns in different parts of an output
     963section.
    955964
    956965   This example shows how to fill unspecified regions of memory with the
    957 value `0x9090':
    958      FILL(0x9090)
     966value `0x90':
     967     FILL(0x90909090)
    959968
    960969   The `FILL' command is similar to the `=FILLEXP' output section
    961 attribute (*note Output Section Fill::), but it only affects the part
    962 of the section following the `FILL' command, rather than the entire
    963 section.  If both are used, the `FILL' command takes precedence.
     970attribute, but it only affects the part of the section following the
     971`FILL' command, rather than the entire section.  If both are used, the
     972`FILL' command takes precedence.  *Note Output Section Fill::, for
     973details on the fill expression.
    964974
    965975
    966976File: ld.info,  Node: Output Section Keywords,  Next: Output Section Discarding,  Prev: Output Section Data,  Up: SECTIONS
    967977
    968 Output section keywords
     978Output Section Keywords
    969979-----------------------
    970980
     
    10391049File: ld.info,  Node: Output Section Discarding,  Next: Output Section Attributes,  Prev: Output Section Keywords,  Up: SECTIONS
    10401050
    1041 Output section discarding
     1051Output Section Discarding
    10421052-------------------------
    10431053
     
    10621072File: ld.info,  Node: Output Section Attributes,  Next: Overlay Description,  Prev: Output Section Discarding,  Up: SECTIONS
    10631073
    1064 Output section attributes
     1074Output Section Attributes
    10651075-------------------------
    10661076
     
    10881098File: ld.info,  Node: Output Section Type,  Next: Output Section LMA,  Up: Output Section Attributes
    10891099
    1090 Output section type
     1100Output Section Type
    10911101...................
    10921102
     
    11211131File: ld.info,  Node: Output Section LMA,  Next: Output Section Region,  Prev: Output Section Type,  Up: Output Section Attributes
    11221132
    1123 Output section LMA
     1133Output Section LMA
    11241134..................
    11251135
     
    11751185File: ld.info,  Node: Output Section Region,  Next: Output Section Phdr,  Prev: Output Section LMA,  Up: Output Section Attributes
    11761186
    1177 Output section region
     1187Output Section Region
    11781188.....................
    11791189
     
    11881198File: ld.info,  Node: Output Section Phdr,  Next: Output Section Fill,  Prev: Output Section Region,  Up: Output Section Attributes
    11891199
    1190 Output section phdr
     1200Output Section Phdr
    11911201...................
    11921202
     
    12051215File: ld.info,  Node: Output Section Fill,  Prev: Output Section Phdr,  Up: Output Section Attributes
    12061216
    1207 Output section fill
     1217Output Section Fill
    12081218...................
    12091219
     
    12121222otherwise unspecified regions of memory within the output section (for
    12131223example, gaps left due to the required alignment of input sections)
    1214 will be filled with the two least significant bytes of the value,
    1215 repeated as necessary.
     1224will be filled with the value, repeated as necessary.  If the fill
     1225expression is a simple hex number, ie. a string of hex digit starting
     1226with `0x' and without a trailing `k' or `M', then an arbitrarily long
     1227sequence of hex digits can be used to specify the fill pattern;
     1228Leading zeros become part of the pattern too.  For all other cases,
     1229including extra parentheses or a unary `+', the fill pattern is the
     1230four least significant bytes of the value of the expression.  In all
     1231cases, the number is big-endian.
    12161232
    12171233   You can also change the fill value with a `FILL' command in the
    1218 output section commands; see *Note Output Section Data::.
     1234output section commands; (*note Output Section Data::).
    12191235
    12201236   Here is a simple example:
    1221      SECTIONS { .text : { *(.text) } =0x9090 }
    1222 
     1237     SECTIONS { .text : { *(.text) } =0x90909090 }
     1238
Note: See TracChangeset for help on using the changeset viewer.