nld Manual

nld Utility
nld Manual528272-001
2-14
Linking SRLs
A program file can have at most one TNS/R native user library associated with it. This
table shows how to associate a TNS/R native user library with a program file.
If you use programs or user libraries that contain C++ code, use the noft option
LISTATTRIBUTE or LA (see the noft Manual) to verify that the program and the user
library have compatible C++ dialects. (For information about C++ dialects, see C++
Programs on page 2-9.)
User libraries specified at run time override those specified at link time.
Linking SRLs
An SRL contains code present in virtual memory at run time, to be shared by other
processes, rather than being copied into object files. An SRL can also contain global
data, and each process using the SRL automatically gets its own run-time copy of the
data, called instance data. A process can use several SRLs.
Some of the code configured in the system library for TNS processes is packaged in
SRLs for native processes. For example:
C run-time library
NonStop TCP/IP sockets library
Tools.h++ class library
Much of the OSS API
HP supplies public SRLs; you cannot create your own. You can create your own user
library. See Linking User Libraries on page 2-12 for details.
When How
Link time* nld utility -libname library option
nld utility -set libname library option
nld utility -change libname library options
Native c89 utility -Wnld= "nld-options" option
Native nmcobol utility -Wnld= "nld-options" option
Run time TACL command interpreter RUN command LIB option
OSS run command -lib option
OSS runv command -lib option
OSS run gtacl command -lib option
* library must be a Guardian file name. For details, see -libname on page 3-9.
Note. nld supports TNS/R native SRLs. It does not support the TNS SRL available to TNS
and accelerated programs in the OSS environment. See the Binder Manual for details.