DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 
COFF link editor

Nonrelocatable input files

If a file produced by ld is intended to be used in a subsequent ld run, the first ld run should have the -r option set. This preserves relocation information and permits the sections of the file to be relocated by the subsequent run.

If an ld input file does not have relocation or symbol table information (perhaps from the action of a strip(CP) command, or from being link edited without a -r option, or with a -s option), the link edit run continues using the nonrelocatable input file.

For such a link edit to be successful (that is, to correctly link all input files, relocate all symbols, resolve unresolved references, and so on), two conditions on the nonrelocatable input files must be met:

If these two conditions are not met for all nonrelocatable input files, no error messages are issued. Because of this fact, extreme care must be taken when supplying such input files to ld.

Next topic: Syntax diagram for input directives
Previous topic: Output file blocking

© 2003 Caldera International, Inc. All rights reserved.
SCO OpenServer Release 5.0.7 -- 11 February 2003