COBOL Manual for TNS and TNS/R Programs
Issues Related to Binding and Linking
HP COBOL Manual for TNS and TNS/R Programs—522555-006
24-5
Binding or Linking
BINSERV
BINSERV, which runs as a separate process during a compilation, performs these
tasks:
•
Builds lists of references that must be resolved
•
Tries to locate the required code blocks and reports its success or failure to do so
•
Gives the compiler information about the code blocks it finds. This information
enables the compiler to verify that:
°
The list of actual parameters that the calling program is passing to the called
program is appropriate
°
The language attribute of the code block matches the language specification in
the CALL or ENTER statement
•
Either creates an object file or reports its failure to do so
BIND
BIND, which is interactive, allows you to examine, modify, and combine object files.
Suppose you have an object file containing blocks from several programs and you
want to replace one version of program Q with another version. Using BIND, you can
copy all blocks but those of program Q into a new object file and then copy the new set
of blocks for the new version of Q into the new object file.
For more information on Binder, see the Binder Manual.
Linker
The NMCOBOL compiler validates and resolves internal and external references with
the help of the COBOLFE process and the linker. The linker accepts commands that
direct it to read, operate on, and produce object files.
The linker links one or more object files to produce either a loadfile or a linkfile.
The linker that the NMCOBOL compiler uses depends on the CALL-SHARED, NON-
SHARED, and SHARED directives:
Note. This topic applies only to the NMCOBOL compiler. The COBOL85 compiler does not
use the linker, it uses Binder.
Directive Linker Linker Documentation
NON-SHARED nld utility nld Manual
CALL-SHARED
SHARED
ld utility ld Manual