$!----------------------------------------------------------------------------- $! BUILD_CGILIB_EXAMPLE.COM $! $! P1 == LINK or BUILD or empty (builds) $! P2 == Optional location of CGILIB object library (defaults to [.MISC]) $! $! 27-NOV-2004 MGD non-VAX link against CGILIBSHR32 sharable image $! 28-OCT-2000 MGD use CGILIB object library $!----------------------------------------------------------------------------- $! $ ON CONTROLY THEN EXIT 44 $! $ WRITE SYS$OUTPUT "" $ WRITE SYS$OUTPUT "Building ""CGILIB_EXAMPLE""" +- " for ""''F$GETSYI("ARCH_NAME")'"" architecture" $! $ ARCH_NAME = F$EDIT(F$GETSYI("ARCH_NAME"),"UPCASE") $ IF ARCH_NAME .EQS. "ALPHA" THEN ARCH_NAME = "AXP" $! $ DEFINES = " /DEFINE=(__VMS_VER=70000000,__CRTL_VER=70000000)" $ INCLUDES = " /INCLUDE=[SRC.MISC]" $ WARNINGS= " /WARNING=(DISABLE=(PREOPTW,IMPLICITFUNC," +- "NEEDCONSTEXT,ADDRCONSTEXT))" $! $ IF F$EDIT(F$GETSYI("ARCH_NAME"),"UPCASE") .EQS. "VAX" $ THEN $ CC_OPTIONS = "/DECC /OPTIMIZE /STAND=RELAXED_ANSI /PREFIX=ALL" +- INCLUDES + DEFINES + WARNINGS $ ELSE $ CC_OPTIONS = "/DECC /OPTIMIZE /STAND=RELAXED_ANSI /PREFIX=ALL" +- INCLUDES + DEFINES + WARNINGS $ ENDIF $! $ IF F$SEARCH("OBJ_''ARCH_NAME'.DIR") .EQS. "" - THEN CREATE /DIR [.OBJ_'ARCH_NAME'] $ OBJECT_DIR = "[.OBJ_''ARCH_NAME']" $! $ IF P1 .EQS. "" .OR. P1 .EQS. "BUILD" .OR. P1 .EQS. "COMPILE" $ THEN $ SET NOON $ SET VERIFY $ CC 'CC_OPTIONS' /OBJECT='OBJECT_DIR' CGILIB_EXAMPLE $! 'F$VERIFY(0) $ SET ON $ ENDIF $! $ IF P1 .EQS. "" .OR. P1 .EQS. "BUILD" .OR. P1 .EQS. "LINK" $ THEN $ CGILIBSHR32 = "WASD_EXE:CGILIBSHR32.EXE" $ DEFINE /USER WASD_CGILIBSHR32 'CGILIBSHR32' $ SET NOON $ SET VERIFY $ IF F$EDIT(F$GETSYI("ARCH_NAME"),"UPCASE") .EQS. "VAX" $ THEN $ CGILIB_OLB = "[SRC.MISC.OBJ_''ARCH_NAME']CGILIB.OLB" $ SET VERIFY $ LINK /EXECUTABLE=WASD_EXE:CGILIB_EXAMPLE.EXE - 'OBJECT_DIR'CGILIB_EXAMPLE,'CGILIB_OLB'/LIBRARY $! 'F$VERIFY(0) $ ELSE $ SET VERIFY $ LINK /EXECUTABLE=WASD_EXE:CGILIB_EXAMPLE.EXE - 'OBJECT_DIR'CGILIB_EXAMPLE,SYS$INPUT/OPTIONS WASD_CGILIBSHR32/SHARE $! 'F$VERIFY(0) $ ENDIF $ SET ON $ ENDIF $ PURGE /NOLOG 'OBJECT_DIR' $! $!-----------------------------------------------------------------------------