maintaining VMSDEF modules

(PYVMS LOGO) Python on OpenVMS

(go to: table of contents, index, list of VMSDEF modules, next: vms_dcdef)

VMSDEF modules consist of several files:

VMSDEF_$fac.DAT
The source file that can contain item codes, bitmasks and constants. It is converted by the procedure 'VMSDEF2MAR.COM' to the file 'VMSDEF_$fac.MAR' by using the following command:
    $ @DMACRO_VMS VMSDEF_DIRECTORY.MAR

Due to a deficy in VMSDEF2MAR.COM at least one item code, even if it is a dummy one, MUST be present.

VMSDEF_$fac.MAR
This is a file that is run through the macro assembler by using the following command:
    $ @DMACRO_VMS VMSDEF_$fac.MAR
The resulting object file (VMSDEF_$DCDEF.OBJ) is put into the object library in [.VMS.O_architecture]VMS_MACRO.OLB. ('architecture' is either 'ALPHA' or 'VAX').

VMSDEF_DIRECTORY.MAR
After a new VMSDEF module has been created, the list of modules must be updated. The file VMSDEF_DIRECTORY.MAR is created by running the procedure 'VMSDEF_BLDDIR2MAR.COM'

This file is then run through the macro assembler by using the following command:

    $ @DMACRO_VMS VMSDEF_DIRECTORY.MAR
The resulting object file is, too, put in VMS_MACRO.OLB.

VMS_facDEF.C
It is often usefull that the programmer has access to the bitmasks and constants of a VMSDEF module (the interface routines take care of the item codes). This files (VMS_*DEF.C) create Python modules (e. g. 'vms_jpidef') that can be imported:
    >>> import vms_jpidef
    >>> print vms_jpidef.JPI_K_BATCH
    2
    >>> print vms_jpidef.JPI_M_PASSWORD_EXPIRED
    4
    >>>
While one can directly use numbers, a reference through the symbolic name in the module makes the programs much more readable.


(go to: table of contents, index, list of VMSDEF modules, next: vms_dcdef)

02-MAR-1999 ZE.