++MACUPD MCS

The ++MACUPD MCS describes a single macro update within a PTF, an APAR fix, or a USERMOD. It must immediately precede the macro update statements within the SYSMOD.

Syntax

Read syntax diagramSkip visual syntax diagram
++MACUPD MCS

>>-++MACUPD--(--name--)----------------------------------------->

>--+------------------------------------------------------------+-->
   |           .-,------.                                       |   
   |           V        |                                       |   
   '-ASSEM--(----module-+--)--+-------------------------------+-'   
                              | .---------------------------. |     
                              | V                           | |     
                              '---+-DISTMOD--(--ddname--)-+-+-'     
                                  '-DISTSRC--(--ddname--)-'         

>--+-----------------------+--+-------------------------+------->
   '-DISTLIB--(--ddname--)-'  |            .-,-----.    |   
                              |            V       |    |   
                              '-MALIAS--(----alias-+--)-'   

>--+--------------------------+--+----------------------+--•---><
   |            .-,------.    |  '-SYSLIB--(--ddname--)-'      
   |            V        |    |                                
   '-PREFIX--(----prefix-+--)-'                                

Operands

ASSEM
specifies the names of modules to be assembled in addition to those named as GENASM subentries in the MAC entry. The source for the assemblies is the ASSEM entry, SRC entry, or DISTSRC member whose name matches the specified ASSEM value. SMP/E looks for a match—first with an ASSEM entry, then with a SRC entry, and finally with an entry in the DISTSRC data set—and uses the first match it finds. The source must either be known to SMP/E at the time the ASSEM operand is encountered on the ++MACUPD statement, or be included in the same SYSMOD.
Note:
  1. APPLY and ACCEPT processing place the specified names into the SYSMOD entry created on the target zone and distribution zone.
  2. If the object deck for the element specified on the ASSEM operand is also provided by the SYSMOD, the assembly may not occur. For more information, see the sub-topic on assemblies in the APPLY command topic in SMP/E for z/OS Commands.
DISTLIB
specifies the ddname of the distribution library for the specified macro.
Note:
  1. DISTLIB must be specified if the macro has not been previously recorded on the target zone or distribution zone. If a MAC entry already exists in the target zone or distribution zone, and the value currently in that entry does not match that specified in the DISTLIB operand, the SYSMOD is not applied or accepted.
  2. You cannot use SYSPUNCH as the DISTLIB. It is used by SMP/E and other products to process assembled modules.
DISTMOD
specifies the ddname of the link-edit distribution library for the modules specified in the ASSEM operand. During ACCEPT processing, the object code from the assembler is link-edited to the library specified.
DISTSRC
specifies the ddname of the library containing the additional assembly or source to be assembled. The additional assembly or source must be specified in the ASSEM operand.
MALIAS
specifies the alias names for the macro in both the target system and distribution libraries.

You can use MALIAS when two or more macros that must be defined in the same zone must have the same name for programming access. For example, you can use MALIAS if several products have a help macro whose name must match the name of the command processing module it describes. You can specify HELP on MALIAS and a unique element name as the macro name.

name
specifies the name of the macro member in the distribution library and, optionally, in the target system library. The name can contain any alphanumeric characters and $, #, @, or hex C0.
PREFIX
specifies the first characters (prefix) of the names of modules to be assembled in addition to those modules named as GENASM subentries in the target zone MAC entry. The prefix values must be 7 characters or less.

The full module names are determined by comparing the prefix with the target zone or distribution zone MOD entry names.

The source for the assembly is the ASSEM entry, SRC entry, or DISTSRC member whose name matches a MOD entry name beginning with one of the specified prefixes. SMP/E looks for a match—first with an ASSEM entry, then with a SRC entry, and finally with an entry in the DISTSRC data set—and uses the first match it finds. The source must be either known to SMP/E at the time the PREFIX operand is encountered on the ++MACUPD statement, or be included in the same SYSMOD.

Note: If the object deck for the element specified on the PREFIX operand is also provided by the SYSMOD, the assembly may not occur. For more information, see the sub-topic on assemblies in the APPLY command topic in SMP/E for z/OS Commands.
SYSLIB
specifies the ddname of the target library, if the macro exists in one. APPLY and RESTORE processing update this library.

Usage notes

Examples

Assume you want to update macro IFBMAC02, which resides in distribution library IFBMACS. Because of this change, module IFBSRC01 must be reassembled. Module IFBSRC01 exists as a source in distribution library SYS1.IFBSRC, and as an object module in distribution library SYS1.AOS23. The macro and the modules are part of JXY1040, a user-written function. Here is an example of a SYSMOD containing a ++MACUPD statement to make the necessary changes:
++PTF(USR0001)              /* Preventive service       */.
++VER(Z038) FMID(JXY1040)   /* for user product.        */.
++MACUPD(IFBMAC02)          /* Update this macro        */
            DISTLIB(IFBMACS)/* in this DLIB.            */
            ASSEM(IFBSRC01) /* Assemble this source.    */
            DISTSRC(IFBSRC) /* Source is here.          */
            DISTMOD(AOS23)  /* Assembled SRC goes here. */.
./ CHANGE name=IFBMAC02
... IEBUPDTE control cards and data
...
In this example, DD statements are required when the SYSMOD is applied to define the target libraries for the macro and the load module to be updated as a result of the assembly. For example, if the modules in SYS1.AOS23 (the assembled module's distribution library) were copied to SYS1.LINKLIB and the source in SYS1.IFBSRC (the source element's distribution library) were copied to SYS1.CHGLIB, the following DD statements are needed:
//LINKLIB  DD  DSN=SYS1.LINKLIB…
//CHGLIB   DD  DSN=SYS1.CHGLIB…
In this example, the following DD statements are needed when the SYSMOD is being accepted to define the distribution libraries:
//IFBMACS  DD  DSN=SYS1.IFBMACS…  (macro DLIB)
//IFBSRC   DD  DSN=SYS1.IFBSRC…   (source DLIB for assembly)
//AOS23    DD  DSN=SYS1.AOS23…    (DLIB for module assembled)