This section describes the following libraries:
SYSLNK.CRTE library
This library contains:
Source programs for the generation of user-specific locales (type S)
USLOCA
Assembler source program
USLOCC
C source program
Individual modules of the C runtime system (object modules, type R and link-and-load modules, type L)
These modules can be statically linked using BINDER or dynamically linked using the DBL. The C runtime system can also be dynamically loaded (partial bind linkage method). In this case, one of the following libraries must be specified at link time in place of the library SYSLNK.CRTE.
SYSLNK.CRTE.PARTIAL-BIND (standard partial bind)
SYSLNK.CRTE.COMPL (complete partial bind)
Name adapter modules for new C library functions:
Object modules (OMs, type R)
Link-and-load modules (LLMs, type L)
The adapter modules are non-preloadable components of the C runtime system and must consequently be linked to the application program.
C runtime system as a dynamically loadable main module (object module, type R) and link-and-load module (LLM, type L)
This main module is dynamically loaded at runtime if the library
SYSLNK.CRTE.PARTIAL-BIND or SYSLNK.CRTE.COMPL is included instead of the library SYSLNK.CRTE and the dynamically loadable C runtime system has not been preloaded as a CRTEPART subsystem into class 4 memory.
SYSLNK.CRTE.SHARE library
This library contains the C runtime system as the shareable main module IC@RTSXS. The system administrator can load this main module into class 4 memory as a CRTEC subsystem.
SYSLNK.CRTE.POSIX library
This “link switch” library must always be included if the POSIX functions of the C runtime system are used. It contains the modules ICSS44Y@ and ICSTISP@ (object module, type R) which must, as a priority, be linked before the modules in the library SYSLNK.CRTE or SYSLNK.CRTE.PARTIAL-BIND or SYSLNK.CRTE.COMPL. When linking is performed with BINDER it is necessary to include the library by means of an INCLUDE-MODULES statement (without specifying a module name), because the link sequence must be observed when linking is performed by the Autolink mechanism (RESOLVEs) and the content of the libraries may also change. In the case of dynamic linking using the DBL, the link switch library must be assigned a lower link name BLSLIBnn than the CRTE libraries which are included after it. The POSIX link switch is automatically included when programs developed in the POSIX shell use the command cc, c89 or CC.
SYSLNK.CRTE.COMPV1 and SYSLNK.CRTE.COMPV2 libraries
Objects generated by the C compiler V1.0 are executable with CRTE if they are relinked with the library SYSLNK.CRTE or SYSLNK.CRTE.PARTIAL-BIND or SYSLNK.CRTE.COMPL and with the library SYSLNK.CRTE.COMPV1.
C modules or C programs for which the linkage module has been linked from CLIB V2.0 require the dynamically loadable C runtime system compatible with C V2.0 in order to run. After installation of CRTE V10.1A, this runtime system is contained in the $.CLIB library. This means that it is no longer necessary (cf. CRTE up to and including V1.0B) to assign the library SYSLNK.CRTE.COMPV2 with the link name IC@CLIB before calling a C V2.0 program. Procedures containing this assignment need not be changed.
SYSLNK.CRTE.TIMESHIFT library
This “link switch” library is supported fo compatibilty reasons only.
In previous versions it was used to shift the reference date (epoch) for the time functions ctime
, difftime
, ftime
, gmtime
, localtime
, mktime
and time
from 1/1/1950 to 1/1/1970 00:00:00.
In the current CRTE version the reference date by default is 1/1/1970 00:00:00. Therefor it using this link switch is not necessary anymore.
SYSLNK.CRTE.TIME50 library
This “link switch” library shifts the reference date (epoch) for the time functions ctime
, dif-ftime
, ftime
, gmtime
, localtime
, mktime
and time
to 1/1/1950 00:00:00. Thus the behaviour of the mentioned time funktions can be set to the default behavior of CRTE versions up to V2.9 and in V10.0A and V11.0A.
This link switch is necessary if time stamps are to be processed which have been created with 1/1/1950 as the reference date (epoch).
However, the time functions mentioned above don‘t supply correct result anymore for time stamps after 1/19/2038 03:14:07. Especially, a call of the functions time
and ftime
cause the termination of the program, as the current date is higher than 1/19/2018.
To use the bind option, enter the following statement when binding:
INCLUDE-MODULE LIB=<library>,ELEMENT=*ALL
SYSLIB.CRTE library
The source components of the C runtime system (standard include elements and source programs for user-defined locales) are supplied in the library SYSLIB.CRTE. This library also contains the ILCS macros.