1$ ! OpenSSL startup script 2$ ! 3$ ! This script defines the logical names used by the installation 4$ ! of OpenSSL. It can provide those logical names at any level, 5$ ! defined by P1. 6$ ! 7$ ! The logical names created are: 8$ ! 9$ ! OSSL$INSTROOT Installation root 10$ ! OSSL$DATAROOT Data root (common directory 11$ ! for certs etc) 12$ ! OSSL$INCLUDE Include directory root 13$ ! OSSL$LIB Where the static library files 14$ ! are located 15$ ! OSSL$SHARE Where the shareable image files 16$ ! are located 17$ ! OSSL$EXE Where the executables are located 18$ ! OSSL$ENGINESnnn Where the shareable images are located 19$ ! OSSL$LIBCRYPTO The static crypto library 20$ ! OSSL$LIBSSL The static ssl library 21$ ! OSSL$LIBCRYPTOnnn_SHR The shareable crypto image 22$ ! OSSL$LIBSSLnnn_SHR The shareable ssl image 23$ ! OPENSSL is OSSL$INCLUDE:[OPENSSL] 24$ ! 25$ ! In all these, nnn is the OpenSSL version number. This allows 26$ ! several OpenSSL versions to be installed simultaneously, which 27$ ! matters for applications that are linked to the shareable images 28$ ! or that depend on engines. 29$ ! 30$ ! In addition, unless P2 is "NOALIASES", these logical names are 31$ ! created: 32$ ! 33$ ! OSSL$ENGINES Alias for OSSL$ENGINESnnn 34$ ! OSSL$LIBCRYPTO_SHR Alias for OSSL$LIBCRYPTOnnn_SHR 35$ ! OSSL$LIBSSL_SHR Alias for OSSL$LIBSSLnnn_SHR 36$ ! 37$ ! P1 Qualifier(s) for DEFINE. "/SYSTEM" would be typical when 38$ ! calling this script from SYS$STARTUP:SYSTARTUP_VMS.COM, 39$ ! while "/PROCESS" would be typical for a personal install. 40$ ! Default: /PROCESS 41$ ! 42$ ! P2 If the value is "NOALIASES", no alias logical names are 43$ ! created. 44$ 45$ status = %x10000001 ! Generic success 46$ 47$ ! In case there's a problem 48$ ON CONTROL_Y THEN GOTO bailout 49$ ON ERROR THEN GOTO bailout 50$ 51$ ! Find the architecture 52$ IF F$GETSYI("CPU") .LT. 128 53$ THEN 54$ arch := VAX 55$ ELSE 56$ arch = F$EDIT(F$GETSYI("ARCH_NAME"),"UPCASE") 57$ IF arch .EQS. "" THEN GOTO unknown_arch 58$ ENDIF 59$ 60$ ! Generated information 61$ INSTALLTOP := {- $config{INSTALLTOP} -} 62$ OPENSSLDIR := {- $config{OPENSSLDIR} -} 63$ 64$ ! Make sure that INSTALLTOP and OPENSSLDIR become something one 65$ ! can build concealed logical names on 66$ INSTALLTOP_ = F$PARSE("A.;",INSTALLTOP,,,"NO_CONCEAL") - 67 - ".][000000" - "[000000." - "][" - "]A.;" + "." 68$ OPENSSLDIR_ = F$PARSE("A.;",OPENSSLDIR,,,"NO_CONCEAL") - 69 - ".][000000" - "[000000." - "][" - "]A.;" + "." 70$ 71$ DEFINE /TRANSLATION=CONCEALED /NOLOG WRK_INSTALLTOP 'INSTALLTOP_'] 72$ DEFINE /TRANSLATION=CONCEALED /NOLOG WRK_OPENSSLDIR 'OPENSSLDIR_'] 73$ 74$ ! Check that things are in place, and specifically, the stuff 75$ ! belonging to this architecture 76$ IF F$SEARCH("WRK_INSTALLTOP:[000000]INCLUDE.DIR;1") .EQS. "" - 77 .OR. F$SEARCH("WRK_INSTALLTOP:[000000]LIB.DIR;1") .EQS. "" - 78 .OR. F$SEARCH("WRK_INSTALLTOP:[000000]EXE.DIR;1") .EQS. "" - 79 .OR. F$SEARCH("WRK_INSTALLTOP:[LIB]''arch'.DIR;1") .EQS. "" - 80 .OR. F$SEARCH("WRK_INSTALLTOP:[EXE]''arch'.DIR;1") .EQS. "" - 81 .OR. F$SEARCH("WRK_OPENSSLDIR:[000000]openssl.cnf") .EQS. "" 82$ THEN 83$ WRITE SYS$ERROR "''INSTALLTOP' doesn't look like an OpenSSL installation for ''arch'" 84$ status = %x00018292 ! RMS$_FNF, file not found 85$ GOTO bailout 86$ ENDIF 87$ 88$ ! Abbrevs 89$ DEFT := DEFINE /TRANSLATION=CONCEALED /NOLOG 'P1' 90$ DEF := DEFINE /NOLOG 'P1' 91$ sv := {- sprintf "%02d%02d", split m|\.|, $config{shlib_version_number} -} 92$ pz := {- $config{pointer_size} -} 93$ 94$ DEFT OSSL$DATAROOT 'OPENSSLDIR_'] 95$ DEFT OSSL$INSTROOT 'INSTALLTOP_'] 96$ DEFT OSSL$INCLUDE 'INSTALLTOP_'INCLUDE.] 97$ DEF OSSL$LIB OSSL$INSTROOT:[LIB.'arch'] 98$ DEF OSSL$SHARE OSSL$INSTROOT:[LIB.'arch'] 99$ DEF OSSL$ENGINES'sv''pz' OSSL$INSTROOT:[ENGINES'sv''pz'.'arch'] 100$ DEF OSSL$EXE OSSL$INSTROOT:[EXE.'arch'],- 101 OSSL$INSTROOT:[EXE] 102$ DEF OSSL$LIBCRYPTO'pz' OSSL$LIB:OSSL$LIBCRYPTO'pz'.OLB 103$ DEF OSSL$LIBSSL'pz' OSSL$LIB:OSSL$LIBSSL'pz'.OLB 104${- output_off() if $config{no_shared}; "" -} 105$ DEF OSSL$LIBCRYPTO'sv'_SHR'pz' OSSL$SHARE:OSSL$LIBCRYPTO'sv'_SHR'pz'.EXE 106$ DEF OSSL$LIBSSL'sv'_SHR'pz' OSSL$SHARE:OSSL$LIBSSL'sv'_SHR'pz'.EXE 107${- output_on() if $config{no_shared}; "" -} 108$ DEF OPENSSL OSSL$INCLUDE:[OPENSSL] 109$ 110$ IF P2 .NES. "NOALIASES" 111$ THEN 112$ DEF OSSL$ENGINES'pz' OSSL$ENGINES'sv''pz' 113${- output_off() if $config{no_shared}; "" -} 114$ DEF OSSL$LIBCRYPTO_SHR'pz' OSSL$LIBCRYPTO'sv'_SHR'pz' 115$ DEF OSSL$LIBSSL_SHR'pz' OSSL$LIBSSL'sv'_SHR'pz' 116${- output_on() if $config{no_shared}; "" -} 117$ ENDIF 118$ 119$ bailout: 120$ DEASSIGN WRK_INSTALLTOP 121$ DEASSIGN WRK_OPENSSLDIR 122$ 123$ EXIT 'status' 124