Output Object Files - HP eld Manual

Table of Contents

Advertisement

eld Input and Output

Output Object Files

The linker can create a new object file or update an existing one in certain ways. When
the linker is creating a new object file, by default it creates a loadfile, but the -r option
instead tells the linker to create a linkfile. The TNS/E linker can also create an import
library, as described in
When the linker creates a new linkfile with the -r option, and there was only one input
file, the output file may be considered a new version of the input file. There are two
reasons why you might do this:
To strip the file in place, with the -s or -x option.
To change the specified floating point type with the -set floattype option.
When the linker creates a new linkfile with the -r option, and there was only one input
file, the linker is required to create the new file so that it has the same fingerprint as the
original file.
The two types of ELF loadfiles produced by the linker are programs and DLLs.
These are both PIC (position independent code). The default is to create a PIC
program. The option named -call_shared means this, and so is the default for the
TNS/E linker. The option to create a DLL is -shared. The option -dll is accepted as
a synonym for -shared.
reports an error if you specify more than one of the -call_shared, -r, and -
eld
shared options.
When a DLL is created, its DLL name can be specified with the -soname option.
If the -soname option is used, the linker accepts whatever string is given for the DLL
name, exactly as-is, and without imposing any rules as to which strings are legal DLL
names.
If the -soname option is not specified then the DLL name is determined to be the file
identifier of the output file. The name of the output file is determined as described in
The Creation of Output Object Files
running on a host platform where the case of filenames is not significant (i.e.,
Guardian or the PC), the linker converts the DLL name to lower case. Note that, on
OSS, the default name for the output file is "a.out", so the default DLL name is similarly
"a.out", and that is true even if this is a Guardian subvolume.
The linker places the DLL name into the DT_SONAME entry of the .dynamic section
of the DLL.
The option named -dllname is accepted as a synonym for -soname.
error if you specify this option when not building a DLL.
A user library is a DLL that is found in a special way by programs, but otherwise is no
different from any other DLL. The -ul option is intended to be used when creating a
DLL that is used as a user library.
Creating Import Libraries
on page 2-5. And, in this case, when the linker is
eld Manual—527255-009
2-4
on page 3-11.
Output Object Files
reports an
eld

Advertisement

Table of Contents
loading

Table of Contents