Trailing-Edge
-
PDP-10 Archives
-
tops20tools_v6_9-jan-86_dumper
-
tools/tvaxv2/tvcomp.com
There are 7 other files named tvcomp.com in the archive. Click here to see a list.
$ VERIFY = F$VERIFY(0)
$!
$! TVCOMP.COM
$! TVCOMP.COM is a COM-file, to compile a macro program (MAR-file),
$! and insert it in the TV-object-library, using the replace-command
$! of the Library-utility. If the TV-object-library is not present,
$! creation is done first.
$!
$! Author: Jan Postmus, Digital SWS, Utrecht, The Netherlands.
$!
$! Calling TVCOMP.COM
$! Normally TVCOMP.COM is called from TV.COM, the main procedure
$! to build TV. It can also be used individually, to compile
$! one of the TV macro programs.
$! When called, the module-name is expect to be specified
$! as the parameter, "@TVCOMP module".
$! Example: "@TVCOMP GTVR01"
$!
$! Error-handling
$! In case an error is detected during this step/procedure,
$! depending whether this procedure is run individual, or
$! called from the main-procedure, exit-code and error-code
$! are used to pass the proper information.
$!
$! Termination
$! The procedure can be terminated by typing CTRL-Y, this
$! is reported to main-procedure, if TVCOMP is called from
$! the build procedure.
$!
$ ON CONTROL_Y THEN GOTO TVCOMP_FATAL
$ SET NOON
$!
$ TVCOMP_10:
$!
$! Test whether this file runs individually or from TV.COM.
$!
$ IF "''LST_PAR'" .NES. "" THEN GOTO TVCOMP_20
$!
$! Running individually, set necessary parameters locally.
$!
$ TVCOMP_IND = "Y"
$ LST_PAR = "LIST/CROSS"
$ MAP_PAR = "MAP/CROSS"
$!
$! Parameters are set-up.
$!
$ TVCOMP_20:
$!
$ WRITE SYS$OUTPUT " "
$ WRITE SYS$OUTPUT " ** Compilation ''P1' started."
$!
$ MACRO /OBJECT 'P1'/'LST_PAR'+TV/LIBRARY
$!
$ IF $STATUS THEN GOTO TVCOMP_30
$!
$! Error during MACRO-compilation, save error-code.
$!
$ ERROR_CODE == $STATUS
$ GOTO TVCOMP_ERROR
$!
$ TVCOMP_30:
$!
$ WRITE SYS$OUTPUT " ** Compilation ''P1' finished."
$!
$! Is TV.OLB present?
$!
$ LIB_OLB = F$SEARCH("TV.OLB",1)
$!
$ IF "''LIB_OLB'" .NES. "" THEN GOTO EXIST
$!
$! Not present, create TV.OLB
$!
$ LIBRARY /CREATE /OBJECT TV
$!
$ IF $STATUS THEN GOTO EXIST
$!
$! Error during library-creation, save error-code.
$!
$ ERROR_CODE == $STATUS
$ GOTO TVCOMP_ERROR
$!
$ EXIST:
$!
$! Insert/replace compiled module into TV.OLB
$!
$ LIBRARY /OBJECT /REPLACE TV 'P1'.OBJ
$!
$ IF $STATUS THEN GOTO TVCOMP_40
$!
$! Error during module replacement, save error-code.
$!
$ ERROR_CODE == $STATUS
$ GOTO TVCOMP_ERROR
$!
$ TVCOMP_40:
$!
$ DELETE 'P1'.OBJ;*
$!
$ WRITE SYS$OUTPUT " ** ''P1' inserted in TV object library."
$!
$ TVCOMP_END:
$!
$! Normal (correct) end of procedure/step.
$!
$ EXIT_CODE = 1
$ GOTO TVCOMP_LAST
$!
$ TVCOMP_ERROR:
$!
$! Error detected during this procedure/step.
$! Set error-code to 101, except when procedure/step is run
$! individually, then exit-code = error-code.
$!
$ EXIT_CODE = 101
$ IF "''TVCOMP_IND'" .NES. "Y" THEN GOTO TVCOMP_LAST
$!
$! Procedure/step run individually, get error-code into $STATUS at exit.
$!
$ EXIT_CODE = ERROR_CODE
$ DELETE /SYMBOL /GLOBAL ERROR_CODE
$ GOTO TVCOMP_LAST
$!
$ TVCOMP_FATAL:
$!
$! Procedure/step terminated by ^Y.
$!
$ EXIT_CODE = 103
$ GOTO TVCOMP_LAST
$!
$ TVCOMP_LAST:
$!
$! Restore verify-mode
$!
$ IF VERIFY .EQ. 1 THEN SET VERIFY
$!
$ EXIT EXIT_CODE