$!----------------------------------------------------------------------------- $! PHP_STARTUP.COM $! $! Copyright (C) 2002-2014 Mark G.Daniel. $! This package comes with ABSOLUTELY NO WARRANTY. $! This is free software and you are welcome to redistribute it under the $! conditions of GNU GENERAL PUBLIC LICENSE, version 3, or any later version. $! http://www.gnu.org/licenses/gpl.txt $! $! Define PHP_ROOT, PHPSHR and PHPWASDSHR in the WASD_TABLE logical name table. $! This allows the web server scripting environment to use the WASD PHP $! environment independently of any other on the system. For any process, $! including general user processes, that have the WASD_TABLE as part of their $! process logical name LNM$FILE_DEV, the following foreign verb will also $! allow the WASD PHP environment to be used at the command-line as well. $! $! $ PHP = "$PHP_ROOT:[000000]PHP.EXE" $! $! To use this image as a CGI PHP interpreter wrap it with a procedure similar $! to the following. $! $! $! WASD_ROOT:[CGI-BIN]PHP.COM $! $ PHP = "$PHP_ROOT:[000000]PHP.EXE" $! $ PHP "''P1'" !any command-line switches desired or required $! $! The WASD_CONFIG_GLOBAL [DclScriptRunTime] directive will need to be modified $! to use this wrapper procedure instead of the PHPWASD.EXE executable. $! Also the PHP.INI 'expose_php' will need to be modified to suppress the $! CGI response field that WASD will object to. $! $! 25-JAN-2014 MGD Mark Berryman PHP kits (exclusively, i.e. no more CSWS) $! 18-AUG-2005 MGD IA64 support $! 26-DEC-2002 MGD support only CSWS PHP 1.1 $! 19-JAN-2002 MGD initial $!----------------------------------------------------------------------------- $ say = "write sys$output" $ ss$_abort = 44 $ set noon $! $ arch_name = f$edit(f$getsyi("arch_name"),"upcase") $ if arch_name .eqs. "ALPHA" then arch_name = "AXP" $! $ if p1 .eqs. "REMOVE" $ then $ if f$trnlnm("PHP_ROOT","WASD_TABLE") .nes. "" - then deassign /table=WASD_TABLE /executive php_root $ if f$trnlnm("PHPSHR","WASD_TABLE") .nes. "" - then deassign /table=WASD_TABLE /executive phpshr $ if f$trnlnm("PHPWASDSHR","WASD_TABLE") .nes. "" - then deassign /table=WASD_TABLE /executive phpwasdshr $ exit $ endif $! $ if f$search("WASD_ROOT:[PHP]''arch_name'.DIR") .eqs. "" $ then $ say "%PHP_STARTUP-E-FAILED, could not find WASD_ROOT:[PHP.''arch_name']" $ exit ss$_abort $ endif $ php_root = f$trnlnm("WASD_ROOT") - "]" + "PHP." + arch_name + ".]" $ define /table=WASD_TABLE /executive /translation=concealed php_root 'php_root' $! $ if f$search("PHP_ROOT:[000000]PHPSHR.EXE") .eqs. "" $ then $ say "%PHP_STARTUP-E-FAILED, could not find PHP_ROOT:[000000]PHPSHR.EXE" $ exit ss$_abort $ endif $ define /table=WASD_TABLE /executive phpwasdshr php_root:[000000]phpshr.exe $ define /table=WASD_TABLE /executive phpshr php_root:[000000]phpshr.exe $! $!-----------------------------------------------------------------------------