You can start the Enterprise COBOL compiler from within an assembler program by using the ATTACH or the LINK macro by dynamic invocation. You must identify the compiler options and the ddnames of the data sets to be used during processing.
For example:
symbol {LINK|ATTACH} EP=IGYCRCTL,PARAM=(optionlist[,ddnamelist]),VL=1
The first fullword in the address parameter list contains the address of the COBOL optionlist. The second fullword contains the address of the ddnamelist. The third and fourth fullwords contain the addresses of null parameters, or zero.
The optionlist must begin on a halfword boundary. The 2 high-order bytes contain a count of the number of bytes in the remainder of the list. If no options are specified, the count must be zero. The optionlist is freeform, with each field separated from the next by a comma. No blanks or zeros should appear. The compiler recognizes only the first 100 characters.
The ddnamelist must begin on a halfword boundary. The 2 high-order bytes contain a count of the number of bytes in the remainder of the list. Each name of less than 8 bytes must be left justified and padded with blanks. If an alternate ddname is omitted from the list, the standard name is assumed. If the name is omitted, the 8-byte entry must contain binary zeros. You can omit names from the end by shortening the list.
All SYSUTn data sets specified must be on direct-access storage devices and have physical sequential organization. They must not reside in the HFS.
The following table shows the sequence of the 8-byte entries in the ddnamelist.
| Alternative ddname 8-byte entry | Name for which alternative ddname is substituted |
|---|---|
| 1 | SYSLIN |
| 2 | Not applicable |
| 3 | Not applicable |
| 4 | SYSLIB |
| 5 | SYSIN |
| 6 | SYSPRINT |
| 7 | SYSPUNCH |
| 8 | SYSUT1 |
| 9 | SYSUT2 |
| 10 | SYSUT3 |
| 11 | SYSUT4 |
| 12 | SYSTERM |
| 13 | SYSUT5 |
| 14 | SYSUT6 |
| 15 | SYSUT7 |
| 16 | SYSADATA |
| 17 | SYSJAVA |
| 18 | SYSDEBUG |
| 19 | SYSMDECK |
| 20 | SYSOPTF |
| 21 | DBRMLIB |
When the compiler completes processing, it puts a return code in register 15.
related tasks
Defining compiler input and output