Nld Command Examples; Example A-9. Linking An Executable User Library; Example A-10. Linking A Program File - HP nld Manual

Table of Contents

Advertisement

Sample nld and noft Session

nld Command Examples

Example A-9
is a multiline TACL command that runs nld with the options used to
make an executable user library called UTILLIB.

Example A-9. Linking an Executable User Library

nld
utilo &
&-l zcresrl -l zcrtlsrl &
&-o utillib -set inspect on -ul
The program UTILLIB is executable, but it does not have a main function. The SRL
libraries ZCRESRL and ZCRTLSRL allow nld to link functions to the correct
addresses in the SRLs. The flag -ul tells nld to use user library address range for the
functions.
Example A-10
the modules of the
with the name EXAMPLE1.

Example A-10. Linking a Program File

nld
module1o module2o maino $system.system.crtlmain &
&-l zcresrl -l zcrtlsrl &
&-o example1 -set inspect on -libname $D0117.CRGMAN.UTILLIB
The command in
main), which C programs need to give the program an executable main function. The
SRL libraries ZCRESRL and ZCRTLSRL allow nld to link function calls to the correct
addresses in the SRLs. The full name of the user library is also included to allow nld
to make the correct address link to the functions.
is a multiline TACL command that runs nld with the options used to link
Example Program
Example A-10
includes the module CRTLMAIN (C run-time library
nld and noft Manual—520384-003
on page A-1 and make the program executable
A- 7
nld Command Examples

Advertisement

Table of Contents
loading

This manual is also suitable for:

Noft

Table of Contents