$ save_ver = 'f$verify(0)' $! $ PUBLIC_DOMAIN_NOTICE: $! $! Copyright (c) 1996 David P. Murphy for Datametrics Systems Corporation --- $! please send all comments and bug reports to murphy@connor.datametrics.com $! $! Permission is granted to any individual or institution to use, copy, or $! redistribute this software so long as all of the original files are included, $! that it is not sold for profit, and that this copyright notice is retained. $! Use at your own risk. Neither Murphy nor Datametrics assumes responsibility. $! Do not taunt Happy Fun Ball. $! $ where = f$environment("DEFAULT") $ fs = f$environment("PROCEDURE") $ path = f$parse(fs,,,"DEVICE") + f$parse(fs,,,"DIRECTORY") $ set default 'path' $! $ isvax = f$getsyi("CPU") .lt. 128 $ isaxp = f$getsyi("CPU") .ge. 128 $! $ if p2 .eqs. "DEBUG" $ then $ cc_opts := /debug /nolist /nooptimize $ mar_opts := /debug /nolist $ link_opts := /trace /debug /nomap $ else $ cc_opts := /nodebug /nolist /optimize $ mar_opts := /nodebug /nolist $ link_opts := /notrace /nodebug /map /full /cross $ endif $ if isaxp then cc_opts = cc_opts + "/PREFIX_LIBRARY_ENTRIES=ALL_ENTRIES" $! $ fx1 = "" $ fx2 = "" $ fx3 = "" $ fx4 = "" $ fx5 = "" $ if p1 .nes. "FORCE_COMPILE" $ then $ if isvax then prefix = "VAX" $ if isaxp then prefix = "AXP" $ if f$search("*.''prefix'_OBJ") .nes. "" then copy /nolog *.'prefix'_obj *.obj;0 $ fx1 = f$search("HER.OBJ") $ fx2 = f$search("HERTEST.OBJ") $ fx3 = f$search("SHOWDATA.OBJ") $ fx4 = f$search("BAREMETAL.OBJ") $ fx5 = f$search("PROBEMEM.OBJ") $ endif $ if fx1 .eqs. "" .or. fx2 .eqs. "" .or. fx3 .eqs. "" .or. fx4 .eqs. "" .or. fx5 .eqs. "" $ then $ write sys$output "compiling..." $ if fx1 .eqs. "" then cc 'cc_opts' her.c $ if fx2 .eqs. "" then cc 'cc_opts' hertest.c $ if fx3 .eqs. "" then cc 'cc_opts' showdata.c $ if fx4 .eqs. "" then macro 'mar_opts' baremetal.mar $ if fx5 .eqs. "" then macro 'mar_opts' probemem.mar $ endif $! $ write sys$output "linking HERTEST..." $ open /write optchan hertest.opt $ write optchan "name=""HERTEST""" $ write optchan "ident=""V1.0""" $ write optchan "hertest.obj" $ write optchan "her.obj" $ write optchan "showdata.obj" $ write optchan "probemem.obj" $ write optchan "baremetal.obj" $ if isvax then write optchan "sys$share:vaxcrtl/share" $ if isvax then write optchan "psect_attr=$CHAR_STRING_CONSTANTS,SHR,NOWRT" $ close optchan $ link 'link_opts' /exe=hertest.exe hertest.opt/opt $! $ write sys$output "all done." $! $ LEAVE: $ set default 'where' $ exit 1 + 0 * f$verify(save_ver) $! $ DELETE_FILE: $ subroutine $ if f$search(p1) .nes. "" then delete /nolog 'p1';* $ exit 1 $ endsubroutine