config.com 2.0 KB
Newer Older
1 2 3 4
$	! OpenSSL config: determine the architecture and run Configure
$	!
$	! Very simple for the moment, it will take the following arguments:
$	!
5 6 7 8 9
$	! -32 or 32	sets /POINTER_SIZE=32
$	! -64 or 64	sets /POINTER_SIZE=64
$	! -d		sets debugging
$	! -h		prints a usage and exits
$	! -t		test mode, doesn't run Configure
10 11 12
$
$	arch == f$edit( f$getsyi( "arch_name"), "lowercase")
$	pointer_size = ""
13
$	test = 0
14 15 16 17 18 19 20
$	here = F$PARSE("A.;",F$ENVIRONMENT("PROCEDURE"),,,"SYNTAX_ONLY") - "A.;"
$
$	collected_args = ""
$	P_index = 0
$	LOOP1:
$	    P_index = P_index + 1
$	    IF P_index .GT. 8 THEN GOTO ENDLOOP1
21
$	    P = F$EDIT(P1,"TRIM,LOWERCASE")
22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46
$	    IF P .EQS. "-h"
$           THEN
$               TEST = 1
$               P = ""
$               TYPE SYS$INPUT
$               DECK
Usage: @config [options]

  -32 or 32	Build with 32-bit pointer size.
  -64 or 64	Build with 64-bit pointer size.
  -d		Build with debugging.
  -t            Test mode, do not run the Configure perl script.
  -h		This help.

Any other text will be passed to the Configure perl script.
See INSTALL for instructions.

$               EOD
$           ENDIF
$	    IF P .EQS. "-t"
$	    THEN
$		test = 1
$		P = ""
$	    ENDIF
$	    IF P .EQS. "-32" .OR. P .EQS. "32"
47 48
$	    THEN
$		pointer_size = "-P32"
49
$		P = ""
50
$	    ENDIF
51
$	    IF P .EQS. "-64" .OR. P .EQS. "64"
52 53
$	    THEN
$		pointer_size = "-P64"
54
$		P = ""
55
$	    ENDIF
56
$	    IF P .EQS. "-d"
57
$	    THEN
58
$               collected_args = collected_args + " --debug"
59
$		P = ""
60
$	    ENDIF
61
$	    IF P .NES. "" THEN -
62 63 64 65 66 67 68 69 70 71 72 73 74
	       collected_args = collected_args + " " + P1
$	    P1 = P2
$	    P2 = P3
$	    P3 = P4
$	    P4 = P5
$	    P5 = P6
$	    P6 = P7
$	    P7 = P8
$	    P8 = ""
$	    GOTO LOOP1
$	ENDLOOP1:
$
$	target = "vms-''arch'''pointer_size'"
75 76 77 78 79 80 81
$       IF test
$       THEN
$           WRITE SYS$OUTPUT "PERL ''here'Configure ""''target'""''collected_args'"
$       ELSE
$           PERL 'here'Configure "''target'" 'debug' 'collected_args'
$       ENDIF
$       EXIT $STATUS
82 83
$
$ USAGE: