$ verify = 'f$verify("NO")' $ if "''ifmod_verify'" then set verify $!----------------------------------------------------------------------------- $! IFMOD.BLD - The function of this command procedure is to build an $! executable image of the program IFMOD. It will test for modules $! which have changed and re-compile (assemble) and Link the modules. $! $! P1 - if specified, then P1 contains qualifiers for the LINK command $! to override the default qualifiers. The first qualifier $! is not to contain a / since it will be added by the proc. $! This is done because invoking the command procedure with $! a P1 value that begins with a / confuses DCL and it thinks $! the / qualifier is for the command procedure invocation. $!----------------------------------------------------------------------------- $! 22-Jan-1984 R. A. Harris Initial Coding. $!----------------------------------------------------------------------------- $ on error then goto abort $ on control_y then goto abort $! $ if "''f$mode()'" .eqs. "BATCH" then assign nla0: sys$print ! don't print log $ if "''f$mode()'" .eqs. "BATCH" then set default [.ifmod] $! $! Create a foreign symbol for IFMOD (boot strapping itself). "SYS$COM:" $! is a logical name which is assigned to the disk and directory $! where an executable copy of IFMOD is stored. $! $ ifmod := $sys$com:ifmod/error=(.true.)/echo $! $! Define default qualifiers for compiles and assembles. This is done $! in such a way that simple changes to the command procedure can $! change the defaults to ones desirable for debugging enhancements $! to the program. $! $ macro := macro/nolist $ !!!! macro := macro/nolist/debug $ !!!! macro := macro/list/debug $! $ message := message/nolist $ !!!! message := message/list $! $ link := link/notrace/nodebug/nomap $ !!!! link := link/notrace/debug/nomap $ !!!! link := link/trace/debug/nomap $ if p1 .nes. "" then link := 'link'/'p1' $! $! Set up to compile and assemble the progarm. If errors are detected $! then and error flag is set to yes. $! $ error := no $ on error then error := yes $! $ ifmod ifmod.mar .gt. ifmod.obj then $ 'macro' ifmod $ ifmod ifmodrms.mar .gt. ifmodrms.obj then $ 'macro' ifmodrms $ ifmod ifmodlib.mar .gt. ifmodlib.obj then $ 'macro' ifmodlib $ ifmod ifmodmsg.msg .gt. ifmodmsg.obj then $ 'message' ifmodmsg $! $ if error then goto abort ! if errors, abort $ on error then goto abort ! set up new on error action $! $! Link the program. $! $ ifmod/error=(.false.)/noecho - (ifmod.obj,ifmodrms,ifmodlib,ifmodmsg) - .lt. ifmod.exe then goto endif_link $ set verify $ 'link' sys$input:/options ifmod,- ifmodrms,- ifmodlib,- ifmodmsg $ endif_link: !'f$verify("NO")' $! $ if error then goto abort ! check for link errors. $ goto exit $! $! Abort. $! $ abort: !'f$verify("NO")' $ if verify then set verify !'f$verify("NO")' $ exit 4 $! $! Exit. $! $ exit: $ if verify then set verify !'f$verify("NO")'