3. Establish a private source statement library:
access 351 d
assgn sysslb d
dlbl ijsyssl d dsn ? (sysslb
test source. lib
4. Issue the SSERV command for a macro in the M sublibrary of TEST SOURCE.LIB: sserv II releas
5. create an ESERV file to copy from the E sublibrary:
edit contrl eserv NEW FILE
EDIT:
input punch contrl
file
6. Execute the ESERV command:
assgn sysin a
eserv contrl
7. create a CMS macro library named MYDOSMAC from the files just
created, which are named OPEN COPY, RELEAS COpy, and CONTRL MACRO: 8.
maclib gen mydosmac open releas contrl
To use these macros in an
indicate that this MACLIB is
file:
global maclib Ilydosaac assembler language program, you Blust accessible before assembling a source
THE MACLIB COMMAND The MACLIB command performs a variety of functions. You use it to: Create the MACLIB (GEN function) Add, delete, or replace members (ADD, DEL, and REP functions) Compress the MACLIB (COMP function) List the contents of the MAC LIB (MAP function)
Descriptions of these MACLIB command functions follow. The GEN (generate) function creates a CMS macro library
from input files specified on the command line. The input files must have filetypes of either MACRO or COPY. For example:
maclib gen mymac get pdump put regequ
creates a macro library with the file identifier MYMAC MACLIB A1 from
macros existing in the files with the file identifiers:
GET f MACRO},PDUMP {MACRO},PUT {MACRO},and REGEQU {MACRO} ), COpy COpy COpy COpy If a file named MYMAC MACLIB A1 already exists, it is erased.
166 IBM IM/370 CMS User's Guide
Assume that the files GET MACRO, PDUMP COPY, PUT MACRO, and REGEQU COpy exist and contain macros in the following form:
GET MACRO PDUMP COpy PUT MACRO REGEQU COPY --------- ---------- --------- -----------
GET *COPY PDUMP PUT XREG PDUMP WAIT *COPY WAIT YREG WAIT The resulting file, MYMAC MACLIB A1, contains the members:
GET WAIT PDUMP WAIT PUT REGEQU The WAIT macro, which
appears twice in the
duplicate macro names. from MYMAC MACLIB, the
used.
appears twice in the input to the command, also
output. The MACLIB command does not check for
If, at a later time, the WAIT macro is requested
first WAIT macro encountered in the directory is When COpy files are added to MACLIBs, the name of the library member
is taken from the name of the copy file, or from the *COPY statement, as
in the file PDUMP COpy, above. Note that although the file REGEQU COpy contained two macros, they were both included in the MACLIB with the name REGEQU. When the input file is a MACRO file, the member name is
taken from the macro prototype statement in the MACRO file. !YD£1ign: The ADD function appends new members to an existing macro
library. For example, assume that MYMAC MACLIB Ai exists as created in
the example in the explanation of the GEN function and the file DTFDI COPY exists as follows: *COPY DTFDI
DTFDI macro definition *COPY DIMOD DIMOD macro definition
If you issue the command: maclib add mymac dtfdi
the resulting MYMAC MACLIB A1 contains the members:
GET WAIT PDUMP WAIT PUT REGEQU DTFDI DIMOD !YD£1ign: The REP (replace) function deletes the directory entry for
the macro definition in the files specified. It then appends new macro
definitions to the macro library and creates new directory entries. For
example, assume that a macro library TESTMAC MACLIB contains the members
A, B, and C, and that the following command is entered:
maclib rep testmac a c
The files represented by file identifiers A MACRO and C MACRO each have
one macro definition. After execution of the command, TBSTMAC MACLIB contains members with the same names as before, but the contents of A and C are different.
Section 9. Developing DOS programs Under CMS 167
Previous Page Next Page