Previous Topic: Required IBM PTFs

Next Topic: Architecture

PCML in Module

At V5R4, after the PTF's are installed, but before the module source is compiled by CA 2E, the following statements must exist in the module source. (The PGMINFO statement does not have to be manually added at V6R1 and beyond.)

RPG

H PGMINFO(*PCML:*MODULE)

COBOL

PROCESS OPTIONS PGMINFO(PCML MODULE)"

Note: 2E does not automatically generate these PGMINFO source lines.

An easy method to accomplish generation of PGMINFO into V5R4 source is to create an EXCUSRSRC member containing the PGMINFO statement and then include that statement in the AD of the module, as in the following examples:

  1. "PCML PGMINFO" is a function of type EXCUSRSRC.

    PCML in Module

  2. Source member for the EXCUSRSRC function contains "H PGMINFO(*PCML : *MODULE)".

    PCML in Module (2)

  3. AD of function EXCEXTFUN shows a call to the user source.

    PCML in Module (3)

    The generated source for the module shows the included PGMINFO line:

    PCML in Module (4)

    Note: At V6R1, it is not necessary to add the PGMINFO statement, but you must ensure that the Compiler Overrides for the Module have the PGMINFO parameter set to PGMINFO(*PCML *MODULE).

In addition to modifying CA 2E functions using EXCUSRSRC to include the keyword PGMINFO(*PCML : *MODULE), the YRP4HS2 model value can be used to alter H spec generation (for an RP4 module) on a model-wide basis.

YRP4HS2 (*MODULE) ships with a value of 'H DATFMT(*YMD) DATEDIT(*YMD) DEBUG(*YES)'.

Changing the value, as below, ensures any generated module is generated with contained PCML:

YCHGMDLVAL MDLVAL(YRP4HS2) VALUE('H DATFMT(*YMD) DATEDIT(*YMD) DEBUG(*YES)
PGMINFO(*PCML : *MODULE)')