DLL Programmer's Guide for TNS/R Systems
Advanced DLL Facility Controls
DLL Programmer’s Guide for TNS/R Systems—522203-002
5-12
Controlling the Loader’s Search Path at Load Time
The list of paths is the set of subvolumes specified by the define's attributes in the
order SUBVOL0, RELSUBVOL0, SUBVOL1, ..., RELSUBVOL20. Each attribute can
specify a single subvolume or a parenthesized, comma-separated list of subvolumes.
Any attributes unspecified are ignored.
For example the following TACL statements specify search list $A.B:$B.C:$C.D:$D.E:
SET CLASS SEARCH, SUBVOL0 $A.B, RELSUBVOL0 $B.C, &
SUBVOL1 ($C.D,$D.E)
ADD DEFINE = _RLD_FIRST_LIB_PATH
The same list can be specified more simply with a single statement and single
attribute:
ADD DEFINE =_RLD_LIB_PATH, CLASS SEARCH, &
SUBVOL0 ($A.B,$B.C,$C.D,$D.E)
No blank spaces are permitted within the parenthesized list.
In either case, the loader’s search path that was defined at link time is augmented as
follows, where the paths identified at link-time were steps 2, 3, 6, and 7, as described
in The Link-Time-Defined Search Path of the Loader on page 2-16.
1. The directory(s) or subvolume(s) specified at load time by
_RLD_FIRST_LIB_PATH.
2. The directory(s) or subvolume(s) specified in -RLD_first_L options at link
time
3. The public libraries (hybrid SRLs)
4. The directory or subvolume that stores the program being loaded
5. The directories or subvolumes specified by _RLD_LIB_PATH at load time.
6. The directories or subvolumes specified in -RLD_L options at link time
7. On OSS: /lib, /usr/lib, /usr/local/lib, /G/SYSTEM/ZDLL
On Guardian: $SYSTEM.ZDLL
In summary, the paths in the list are set up as follows:
•
Steps 3, 4, and 7 the loader follows automatically.
•
Steps 2 and 6 were set up at link time.
•
Steps 1 and 5 are load-time additions.
Steps 1 and 2 are provided for completeness, but are rarely required and are not
recommended for routine use. Because the public libraries can be searched in a
memory table, but all other searches require messages to name servers and/or disk
processes, it is more efficient to start at step 3. The public libraries have unique
names (Z*SRL) that shouldn't interfere with finding ordinary DLLs later.