3 $! Original Author: UNKNOWN
4 $! Rewritten By: Robert Byer
6 $! A-Com Computing, Inc.
7 $! byer@mail.all-net.net
9 $! Changes by Richard Levitte <richard@levitte.org>
10 $! Zoltan Arpadffy <zoli@polarhome.com>
12 $! This procedure creates the SSL libraries of "[.xxx.EXE.CRYPTO]LIBCRYPTO.OLB"
13 $! "[.xxx.EXE.SSL]LIBSSL.OLB"
14 $! The "xxx" denotes the machine architecture of ALPHA, IA64 or VAX.
16 $! This procedures accepts two command line options listed below.
18 $! P1 specifies one of the following build options:
20 $! ALL Just build "everything".
21 $! CONFIG Just build the "[.CRYPTO._xxx]OPENSSLCONF.H" file.
22 $! BUILDINF Just build the "[.CRYPTO._xxx]BUILDINF.H" file.
23 $! SOFTLINKS Just fix the Unix soft links.
24 $! BUILDALL Same as ALL, except CONFIG, BUILDINF and SOFTILNKS aren't done.
25 $! CRYPTO Just build the "[.xxx.EXE.CRYPTO]LIBCRYPTO.OLB" library.
26 $! CRYPTO/x Just build the x part of the
27 $! "[.xxx.EXE.CRYPTO]LIBCRYPTO.OLB" library.
28 $! SSL Just build the "[.xxx.EXE.SSL]LIBSSL.OLB" library.
29 $! SSL_TASK Just build the "[.xxx.EXE.SSL]SSL_TASK.EXE" program.
30 $! TEST Just build the "[.xxx.EXE.TEST]" test programs for OpenSSL.
31 $! APPS Just build the "[.xxx.EXE.APPS]" application programs for OpenSSL.
32 $! ENGINES Just build the "[.xxx.EXE.ENGINES]" application programs for OpenSSL.
34 $! P2, if defined, specifies the C pointer size. Ignored on VAX.
35 $! ("64=ARGV" gives more efficient code with HP C V7.3 or newer.)
36 $! Supported values are:
38 $! "" Compile with default (/NOPOINTER_SIZE).
39 $! 32 Compile with /POINTER_SIZE=32 (SHORT).
40 $! 64 Compile with /POINTER_SIZE=64[=ARGV] (LONG[=ARGV]).
41 $! (Automatically select ARGV if compiler supports it.)
42 $! 64= Compile with /POINTER_SIZE=64 (LONG).
43 $! 64=ARGV Compile with /POINTER_SIZE=64=ARGV (LONG=ARGV).
45 $! P3 specifies DEBUG or NODEBUG, to compile with or without debugging
48 $! P4 specifies which compiler to try to compile under.
53 $! LINK To only link the programs from existing object files.
54 $! (not yet implemented)
56 $! If you don't specify a compiler, it will try to determine which
57 $! "C" compiler to use.
59 $! P5, if defined, sets a TCP/IP library to use, through one of the following
62 $! UCX for UCX or UCX emulation
63 $! TCPIP for TCP/IP Services or TCP/IP Services emulation
64 $! (this is prefered over UCX)
65 $! SOCKETSHR for SOCKETSHR+NETLIB
66 $! NONE to avoid specifying which TCP/IP implementation to
67 $! use at build time (this works with DEC C). This is
70 $! P6, if defined, sets a compiler thread NOT needed on OpenVMS 7.1 (and up).
72 $! P7, if defined, specifies a directory where ZLIB files (zlib.h,
73 $! libz.olb) may be found. Optionally, a non-default object library
74 $! name may be included ("dev:[dir]libz_64.olb", for example).
79 $ proc = f$environment( "procedure")
80 $ write sys$output "@@@ "+ -
81 f$parse( proc, , , "name")+ f$parse( proc, , , "type")
83 $ DEF_ORIG = F$ENVIRONMENT( "DEFAULT")
84 $ ON ERROR THEN GOTO TIDY
85 $ ON CONTROL_C THEN GOTO TIDY
87 $! Check if we're in a batch job, and make sure we get to
88 $! the directory this script is in
90 $ IF F$MODE() .EQS. "BATCH"
92 $ COMNAME=F$ENVIRONMENT("PROCEDURE")
93 $ COMPATH=F$PARSE("A.;",COMNAME) - "A.;"
97 $! Check What Architecture We Are Using.
99 $ IF (F$GETSYI("CPU").LT.128)
102 $! The Architecture Is VAX.
110 $! The Architecture Is Alpha, IA64 or whatever comes in the future.
112 $ ARCH = F$EDIT( F$GETSYI( "ARCH_NAME"), "UPCASE")
113 $ IF (ARCH .EQS. "") THEN ARCH = "UNK"
115 $! End The Architecture Check.
125 $ VMS_VERSION = f$edit( f$getsyi( "VERSION"), "TRIM")
127 $! Check To Make Sure We Have Valid Command Line Parameters.
129 $ GOSUB CHECK_OPTIONS
131 $! Check To See What We Are To Do.
133 $ IF (BUILDCOMMAND.EQS."ALL")
136 $! Start with building the OpenSSL configuration file.
140 $! Create The "BUILDINF.H" Include File.
144 $! Fix The Unix Softlinks.
150 $ IF (BUILDCOMMAND.EQS."ALL".OR.BUILDCOMMAND.EQS."BUILDALL")
153 $! Build The [.xxx.EXE.CRYPTO]LIBCRYPTO.OLB Library.
157 $! Build The [.xxx.EXE.SSL]LIBSSL.OLB Library.
161 $! Build The [.xxx.EXE.SSL]SSL_TASK.EXE DECNet SSL Engine.
165 $! Build The [.xxx.EXE.TEST] OpenSSL Test Utilities.
169 $! Build The [.xxx.EXE.APPS] OpenSSL Application Utilities.
173 $! Build The [.xxx.EXE.ENGINES] OpenSSL Shareable Engines.
181 $! Build Just What The User Wants Us To Build.
183 $ GOSUB 'BUILDCOMMAND'
191 $! Rebuild The [.CRYPTO._xxx]OPENSSLCONF.H" file.
195 $! Tell The User We Are Creating The [.CRYPTO._xxx]OPENSSLCONF.H File.
197 $ WRITE SYS$OUTPUT "Creating [.CRYPTO.''ARCHD']OPENSSLCONF.H Include File."
199 $! First, make sure the directory exists.
201 $ IF F$PARSE("SYS$DISK:[.CRYPTO.''ARCHD']") .EQS. "" THEN -
202 CREATE/DIRECTORY SYS$DISK:[.CRYPTO.'ARCHD']
204 $! Different tar/UnZip versions/option may have named the file differently
205 $ IF F$SEARCH("[.crypto]opensslconf.h_in") .NES. ""
207 $ OPENSSLCONF_H_IN = "[.crypto]opensslconf.h_in"
209 $ IF F$SEARCH( "[.crypto]opensslconf_h.in") .NES. ""
211 $ OPENSSLCONF_H_IN = "[.crypto]opensslconf_h.in"
214 $ IF F$SEARCH( "[.crypto]opensslconf.h.in") .NES. ""
216 $ OPENSSLCONF_H_IN = "[.crypto]opensslconf.h.in"
218 $ WRITE SYS$ERROR "Couldn't find a [.crypto]opensslconf.h.in. Exiting!"
219 $ $STATUS = %X00018294 ! "%RMS-F-FNF, file not found".
225 $! Create The [.CRYPTO._xxx]OPENSSLCONF.H File.
226 $! Make sure it has the right format.
228 $ OSCH_NAME = "SYS$DISK:[.CRYPTO.''ARCHD']OPENSSLCONF.H"
229 $ CREATE /FDL=SYS$INPUT: 'OSCH_NAME'
232 $ OPEN /APPEND H_FILE 'OSCH_NAME'
234 $! Write The [.CRYPTO._xxx]OPENSSLCONF.H File.
236 $ WRITE H_FILE "/* This file was automatically built using makevms.com */"
237 $ WRITE H_FILE "/* and ''OPENSSLCONF_H_IN' */"
239 $! Write a few macros that indicate how this system was built.
242 $ WRITE H_FILE "#ifndef OPENSSL_SYS_VMS"
243 $ WRITE H_FILE "# define OPENSSL_SYS_VMS"
244 $ WRITE H_FILE "#endif"
246 $! One of the best way to figure out what the list should be is to do
247 $! the following on a Unix system:
248 $! grep OPENSSL_NO_ crypto/*/*.h ssl/*.h engines/*.h engines/*/*.h|grep ':# *if'|sed -e 's/^.*def //'|sort|uniq
249 $! For that reason, the list will also always end up in alphabetical order
250 $ CONFIG_LOGICALS := AES,-
269 EC_NISTP_64_GCC_128,-
312 $! Add a few that we know about
313 $ CONFIG_LOGICALS := 'CONFIG_LOGICALS',-
315 $! The following rules, which dictate how some algorithm choices affect
316 $! others, are picked from Configure.
318 $! list = item[ ; list]
319 $! item = algos / dependents
320 $! algos = algo [, algos]
321 $! dependents = dependent [, dependents]
322 $! When a list of algos is specified in one item, it means that they must
323 $! all be disabled for the rule to apply.
324 $! When a list of dependents is specified in one item, it means that they
325 $! will all be disabled if the rule applies.
326 $! Rules are checked sequentially. If a rule disables an algorithm, it will
327 $! affect all following rules that depend on that algorithm being disabled.
328 $! To force something to be enabled or disabled, have no algorithms in the
330 $ CONFIG_DISABLE_RULES := RIJNDAEL/AES;-
344 /EC_NISTP_64_GCC_128;-
350 $ CONFIG_ENABLE_RULES := ZLIB_DYNAMIC/ZLIB;-
353 $! Architecture specific rule addtions
354 $ IF ARCH .EQS. "VAX"
356 $ ! Disable algorithms that require 64-bit integers in C
357 $ CONFIG_DISABLE_RULES = CONFIG_DISABLE_RULES + -
364 $ CONFIG_LOG_E = F$EDIT(F$ELEMENT(CONFIG_LOG_I,",",CONFIG_LOGICALS),"TRIM")
365 $ CONFIG_LOG_I = CONFIG_LOG_I + 1
366 $ IF CONFIG_LOG_E .EQS. "" THEN GOTO CONFIG_LOG_LOOP1
367 $ IF CONFIG_LOG_E .EQS. "," THEN GOTO CONFIG_LOG_LOOP1_END
368 $ IF F$TRNLNM("OPENSSL_NO_"+CONFIG_LOG_E)
370 $ CONFIG_DISABLED_'CONFIG_LOG_E' := YES
371 $ CONFIG_ENABLED_'CONFIG_LOG_E' := NO
372 $ CONFIG_CHANGED_'CONFIG_LOG_E' := YES
374 $ CONFIG_DISABLED_'CONFIG_LOG_E' := NO
375 $ CONFIG_ENABLED_'CONFIG_LOG_E' := YES
376 $ ! Because all algorithms are assumed enabled by default
377 $ CONFIG_CHANGED_'CONFIG_LOG_E' := NO
379 $ GOTO CONFIG_LOG_LOOP1
380 $ CONFIG_LOG_LOOP1_END:
382 $! Apply cascading disable rules
383 $ CONFIG_DISABLE_I = 0
384 $ CONFIG_DISABLE_LOOP0:
385 $ CONFIG_DISABLE_E = F$EDIT(F$ELEMENT(CONFIG_DISABLE_I,";", -
386 CONFIG_DISABLE_RULES),"TRIM")
387 $ CONFIG_DISABLE_I = CONFIG_DISABLE_I + 1
388 $ IF CONFIG_DISABLE_E .EQS. "" THEN GOTO CONFIG_DISABLE_LOOP0
389 $ IF CONFIG_DISABLE_E .EQS. ";" THEN GOTO CONFIG_DISABLE_LOOP0_END
391 $ CONFIG_DISABLE_ALGOS = F$EDIT(F$ELEMENT(0,"/",CONFIG_DISABLE_E),"TRIM")
392 $ CONFIG_DISABLE_DEPENDENTS = F$EDIT(F$ELEMENT(1,"/",CONFIG_DISABLE_E),"TRIM")
395 $ CONFIG_DISABLE_LOOP1:
396 $ CONFIG_ALGO_E = F$EDIT(F$ELEMENT(CONFIG_ALGO_I,",", -
397 CONFIG_DISABLE_ALGOS),"TRIM")
398 $ CONFIG_ALGO_I = CONFIG_ALGO_I + 1
399 $ IF CONFIG_ALGO_E .EQS. "" THEN GOTO CONFIG_DISABLE_LOOP1
400 $ IF CONFIG_ALGO_E .EQS. "," THEN GOTO CONFIG_DISABLE_LOOP1_END
401 $ IF F$TYPE(CONFIG_DISABLED_'CONFIG_ALGO_E') .EQS. ""
405 $ IF .NOT. CONFIG_DISABLED_'CONFIG_ALGO_E' THEN TO_DISABLE := NO
407 $ GOTO CONFIG_DISABLE_LOOP1
408 $ CONFIG_DISABLE_LOOP1_END:
412 $ CONFIG_DEPENDENT_I = 0
413 $ CONFIG_DISABLE_LOOP2:
414 $ CONFIG_DEPENDENT_E = F$EDIT(F$ELEMENT(CONFIG_DEPENDENT_I,",", -
415 CONFIG_DISABLE_DEPENDENTS),"TRIM")
416 $ CONFIG_DEPENDENT_I = CONFIG_DEPENDENT_I + 1
417 $ IF CONFIG_DEPENDENT_E .EQS. "" THEN GOTO CONFIG_DISABLE_LOOP2
418 $ IF CONFIG_DEPENDENT_E .EQS. "," THEN GOTO CONFIG_DISABLE_LOOP2_END
419 $ CONFIG_DISABLED_'CONFIG_DEPENDENT_E' := YES
420 $ CONFIG_ENABLED_'CONFIG_DEPENDENT_E' := NO
421 $ ! Better not to assume defaults at this point...
422 $ CONFIG_CHANGED_'CONFIG_DEPENDENT_E' := YES
424 "''CONFIG_DEPENDENT_E' disabled by rule ''CONFIG_DISABLE_E'"
425 $ GOTO CONFIG_DISABLE_LOOP2
426 $ CONFIG_DISABLE_LOOP2_END:
428 $ GOTO CONFIG_DISABLE_LOOP0
429 $ CONFIG_DISABLE_LOOP0_END:
431 $! Apply cascading enable rules
432 $ CONFIG_ENABLE_I = 0
433 $ CONFIG_ENABLE_LOOP0:
434 $ CONFIG_ENABLE_E = F$EDIT(F$ELEMENT(CONFIG_ENABLE_I,";", -
435 CONFIG_ENABLE_RULES),"TRIM")
436 $ CONFIG_ENABLE_I = CONFIG_ENABLE_I + 1
437 $ IF CONFIG_ENABLE_E .EQS. "" THEN GOTO CONFIG_ENABLE_LOOP0
438 $ IF CONFIG_ENABLE_E .EQS. ";" THEN GOTO CONFIG_ENABLE_LOOP0_END
440 $ CONFIG_ENABLE_ALGOS = F$EDIT(F$ELEMENT(0,"/",CONFIG_ENABLE_E),"TRIM")
441 $ CONFIG_ENABLE_DEPENDENTS = F$EDIT(F$ELEMENT(1,"/",CONFIG_ENABLE_E),"TRIM")
444 $ CONFIG_ENABLE_LOOP1:
445 $ CONFIG_ALGO_E = F$EDIT(F$ELEMENT(CONFIG_ALGO_I,",", -
446 CONFIG_ENABLE_ALGOS),"TRIM")
447 $ CONFIG_ALGO_I = CONFIG_ALGO_I + 1
448 $ IF CONFIG_ALGO_E .EQS. "" THEN GOTO CONFIG_ENABLE_LOOP1
449 $ IF CONFIG_ALGO_E .EQS. "," THEN GOTO CONFIG_ENABLE_LOOP1_END
450 $ IF F$TYPE(CONFIG_ENABLED_'CONFIG_ALGO_E') .EQS. ""
454 $ IF .NOT. CONFIG_ENABLED_'CONFIG_ALGO_E' THEN TO_ENABLE := NO
456 $ GOTO CONFIG_ENABLE_LOOP1
457 $ CONFIG_ENABLE_LOOP1_END:
461 $ CONFIG_DEPENDENT_I = 0
462 $ CONFIG_ENABLE_LOOP2:
463 $ CONFIG_DEPENDENT_E = F$EDIT(F$ELEMENT(CONFIG_DEPENDENT_I,",", -
464 CONFIG_ENABLE_DEPENDENTS),"TRIM")
465 $ CONFIG_DEPENDENT_I = CONFIG_DEPENDENT_I + 1
466 $ IF CONFIG_DEPENDENT_E .EQS. "" THEN GOTO CONFIG_ENABLE_LOOP2
467 $ IF CONFIG_DEPENDENT_E .EQS. "," THEN GOTO CONFIG_ENABLE_LOOP2_END
468 $ CONFIG_DISABLED_'CONFIG_DEPENDENT_E' := NO
469 $ CONFIG_ENABLED_'CONFIG_DEPENDENT_E' := YES
470 $ ! Better not to assume defaults at this point...
471 $ CONFIG_CHANGED_'CONFIG_DEPENDENT_E' := YES
473 "''CONFIG_DEPENDENT_E' enabled by rule ''CONFIG_ENABLE_E'"
474 $ GOTO CONFIG_ENABLE_LOOP2
475 $ CONFIG_ENABLE_LOOP2_END:
477 $ GOTO CONFIG_ENABLE_LOOP0
478 $ CONFIG_ENABLE_LOOP0_END:
480 $! Write to the configuration
483 $ CONFIG_LOG_E = F$EDIT(F$ELEMENT(CONFIG_LOG_I,",",CONFIG_LOGICALS),"TRIM")
484 $ CONFIG_LOG_I = CONFIG_LOG_I + 1
485 $ IF CONFIG_LOG_E .EQS. "" THEN GOTO CONFIG_LOG_LOOP2
486 $ IF CONFIG_LOG_E .EQS. "," THEN GOTO CONFIG_LOG_LOOP2_END
487 $ IF CONFIG_CHANGED_'CONFIG_LOG_E'
489 $ IF CONFIG_DISABLED_'CONFIG_LOG_E'
491 $ WRITE H_FILE "#ifndef OPENSSL_NO_",CONFIG_LOG_E
492 $ WRITE H_FILE "# define OPENSSL_NO_",CONFIG_LOG_E
493 $ WRITE H_FILE "#endif"
495 $ WRITE H_FILE "#ifndef OPENSSL_",CONFIG_LOG_E
496 $ WRITE H_FILE "# define OPENSSL_",CONFIG_LOG_E
497 $ WRITE H_FILE "#endif"
500 $ GOTO CONFIG_LOG_LOOP2
501 $ CONFIG_LOG_LOOP2_END:
504 $ WRITE H_FILE "/* 2011-02-23 SMS."
505 $ WRITE H_FILE " * On VMS (V8.3), setvbuf() doesn't support a 64-bit"
506 $ WRITE H_FILE " * ""in"" pointer, and the help says:"
507 $ WRITE H_FILE " * Please note that the previously documented"
508 $ WRITE H_FILE " * value _IONBF is not supported."
509 $ WRITE H_FILE " * So, skip it on VMS."
511 $ WRITE H_FILE "#define OPENSSL_NO_SETVBUF_IONBF"
512 $ WRITE H_FILE "/* STCP support comes with TCPIP 5.7 ECO 2 "
513 $ WRITE H_FILE " * enable on newer systems / 2012-02-24 arpadffy */"
514 $ WRITE H_FILE "#define OPENSSL_NO_SCTP"
517 $! Add in the common "crypto/opensslconf.h.in".
519 $ TYPE 'OPENSSLCONF_H_IN' /OUTPUT=H_FILE:
521 $ IF ARCH .NES. "VAX"
524 $! Write the non-VAX specific data
526 $ WRITE H_FILE "#if defined(HEADER_RC4_H)"
527 $ WRITE H_FILE "#undef RC4_INT"
528 $ WRITE H_FILE "#define RC4_INT unsigned int"
529 $ WRITE H_FILE "#undef RC4_CHUNK"
530 $ WRITE H_FILE "#define RC4_CHUNK unsigned long long"
531 $ WRITE H_FILE "#endif"
533 $ WRITE H_FILE "#if defined(HEADER_DES_LOCL_H)"
534 $ WRITE H_FILE "#undef DES_LONG"
535 $ WRITE H_FILE "#define DES_LONG unsigned int"
536 $ WRITE H_FILE "#undef DES_PTR"
537 $ WRITE H_FILE "#define DES_PTR"
538 $ WRITE H_FILE "#undef DES_RISC1"
539 $ WRITE H_FILE "#undef DES_RISC2"
540 $ WRITE H_FILE "#define DES_RISC1"
541 $ WRITE H_FILE "#undef DES_UNROLL"
542 $ WRITE H_FILE "#define DES_UNROLL"
543 $ WRITE H_FILE "#endif"
545 $ WRITE H_FILE "#if defined(HEADER_BN_H)"
546 $ WRITE H_FILE "#undef BN_LLONG" ! Never define with SIXTY_FOUR_BIT
547 $ WRITE H_FILE "#undef SIXTY_FOUR_BIT_LONG"
548 $ WRITE H_FILE "#undef SIXTY_FOUR_BIT"
549 $ WRITE H_FILE "#define SIXTY_FOUR_BIT"
550 $ WRITE H_FILE "#undef THIRTY_TWO_BIT"
551 $ WRITE H_FILE "#undef SIXTEEN_BIT"
552 $ WRITE H_FILE "#undef EIGHT_BIT"
553 $ WRITE H_FILE "#endif"
555 $ WRITE H_FILE "#undef OPENSSL_EXPORT_VAR_AS_FUNCTION"
561 $! Write the VAX specific data
563 $ WRITE H_FILE "#if defined(HEADER_RC4_H)"
564 $ WRITE H_FILE "#undef RC4_INT"
565 $ WRITE H_FILE "#define RC4_INT unsigned char"
566 $ WRITE H_FILE "#undef RC4_CHUNK"
567 $ WRITE H_FILE "#define RC4_CHUNK unsigned long"
568 $ WRITE H_FILE "#endif"
570 $ WRITE H_FILE "#if defined(HEADER_DES_LOCL_H)"
571 $ WRITE H_FILE "#undef DES_LONG"
572 $ WRITE H_FILE "#define DES_LONG unsigned long"
573 $ WRITE H_FILE "#undef DES_PTR"
574 $ WRITE H_FILE "#define DES_PTR"
575 $ WRITE H_FILE "#undef DES_RISC1"
576 $ WRITE H_FILE "#undef DES_RISC2"
577 $ WRITE H_FILE "#undef DES_UNROLL"
578 $ WRITE H_FILE "#endif"
580 $ WRITE H_FILE "#if defined(HEADER_BN_H)"
581 $ WRITE H_FILE "#undef BN_LLONG" ! VAX C/DEC C doesn't have long long
582 $ WRITE H_FILE "#undef SIXTY_FOUR_BIT_LONG"
583 $ WRITE H_FILE "#undef SIXTY_FOUR_BIT"
584 $ WRITE H_FILE "#undef THIRTY_TWO_BIT"
585 $ WRITE H_FILE "#define THIRTY_TWO_BIT"
586 $ WRITE H_FILE "#undef SIXTEEN_BIT"
587 $ WRITE H_FILE "#undef EIGHT_BIT"
588 $ WRITE H_FILE "#endif"
590 $! Oddly enough, the following symbol is tested in crypto/sha/sha512.c
591 $! before sha.h gets included (and HEADER_SHA_H defined), so we will not
592 $! protect this one...
593 $ WRITE H_FILE "#undef OPENSSL_NO_SHA512"
594 $ WRITE H_FILE "#define OPENSSL_NO_SHA512"
596 $ WRITE H_FILE "#undef OPENSSL_EXPORT_VAR_AS_FUNCTION"
597 $ WRITE H_FILE "#define OPENSSL_EXPORT_VAR_AS_FUNCTION"
603 $! Close the [.CRYPTO._xxx]OPENSSLCONF.H file
607 $! Purge The [.CRYPTO._xxx]OPENSSLCONF.H file
609 $ PURGE SYS$DISK:[.CRYPTO.'ARCHD']OPENSSLCONF.H
611 $! That's All, Time To RETURN.
615 $! Rebuild The "[.CRYPTO._xxx]BUILDINF.H" file.
619 $! Tell The User We Are Creating The [.CRYPTO._xxx]BUILDINF.H File.
621 $ WRITE SYS$OUTPUT "Creating [.CRYPTO.''ARCHD']BUILDINF.H Include File."
623 $! Create The [.CRYPTO._xxx]BUILDINF.H File.
625 $ BIH_NAME = "SYS$DISK:[.CRYPTO.''ARCHD']BUILDINF.H"
626 $ CREATE /FDL=SYS$INPUT: 'BIH_NAME'
630 $ OPEN /APPEND H_FILE 'bih_name'
632 $! Get The Current Date & Time.
636 $! Write The [.CRYPTO._xxx]BUILDINF.H File.
639 $ if (POINTER_SIZE .nes. "")
641 $ CFLAGS = CFLAGS+ "/POINTER_SIZE=''POINTER_SIZE'"
645 $ if (CFLAGS .nes. "") then CFLAGS = CFLAGS+ " "
646 $ CFLAGS = CFLAGS+ "/DEFINE=ZLIB"
649 $ WRITE H_FILE "#define CFLAGS cflags"
650 $ WRITE H_FILE "static const char cflags[] = ""compiler: ''CFLAGS'"";"
651 $ WRITE H_FILE "#define PLATFORM ""platform: VMS ''ARCHD' ''VMS_VERSION'"""
652 $ WRITE H_FILE "#define DATE ""built on: ''TIME'"" "
654 $! Close The [.CRYPTO._xxx]BUILDINF.H File.
658 $! Purge The [.CRYPTO._xxx]BUILDINF.H File.
660 $ PURGE SYS$DISK:[.CRYPTO.'ARCHD']BUILDINF.H
662 $! Delete [.CRYPTO]BUILDINF.H File, as there might be some residue from Unix.
664 $ IF F$SEARCH("[.CRYPTO]BUILDINF.H") .NES. "" THEN -
665 DELETE SYS$DISK:[.CRYPTO]BUILDINF.H;*
667 $! That's All, Time To RETURN.
671 $! Copy a lot of files around.
675 $!!!! Tell The User We Are Partly Rebuilding The [.APPS] Directory.
677 $!!! WRITE SYS$OUTPUT "Rebuilding The '[.APPS]MD4.C' File."
679 $!!! DELETE SYS$DISK:[.APPS]MD4.C;*
681 $!!!! Copy MD4.C from [.CRYPTO.MD4] into [.APPS]
683 $!!! COPY SYS$DISK:[.CRYPTO.MD4]MD4.C SYS$DISK:[.APPS]
685 $! Ensure that the [.include.openssl] directory contains a full set of
686 $! real header files. The distribution kit may have left real or fake
687 $! symlinks there. Rather than think about what's there, simply delete
688 $! the destination files (fake or real symlinks) before copying the real
689 $! header files in. (Copying a real header file onto a real symlink
690 $! merely duplicates the real header file at its source.)
692 $! Tell The User We Are Rebuilding The [.include.openssl] Directory.
694 $ WRITE SYS$OUTPUT "Rebuilding The '[.include.openssl]' Directory."
696 $! First, make sure the directory exists. If it did exist, delete all
697 $! the existing header files (or fake or real symlinks).
699 $ if f$parse( "sys$disk:[.include.openssl]") .eqs. ""
701 $ create /directory sys$disk:[.include.openssl]
703 $ delete sys$disk:[.include.openssl]*.h;*
706 $! Copy All The ".H" Files From The Main Directory.
708 $ EXHEADER := e_os2.h
709 $ copy 'exheader' sys$disk:[.include.openssl]
711 $! Copy All The ".H" Files From The [.CRYPTO] Directory Tree.
716 MD4, MD5, SHA, MDC2, HMAC, RIPEMD, WHRLPOOL, -
717 DES, AES, RC2, RC4, IDEA, BF, CAST, CAMELLIA, SEED, MODES, -
718 BN, EC, RSA, DSA, ECDSA, DH, ECDH, DSO, ENGINE, -
719 BUFFER, BIO, STACK, LHASH, RAND, ERR, -
720 EVP, ASN1, PEM, X509, X509V3, CONF, TXT_DB, PKCS7, PKCS12, -
721 COMP, OCSP, UI, KRB5, -
722 CMS, PQUEUE, TS, JPAKE, SRP, STORE, CMAC
724 $ EXHEADER_ := crypto.h, opensslv.h, ebcdic.h, symhacks.h, ossl_typ.h
725 $ EXHEADER_'ARCHD' := opensslconf.h
726 $ EXHEADER_OBJECTS := objects.h, obj_mac.h
727 $ EXHEADER_MD2 := md2.h
728 $ EXHEADER_MD4 := md4.h
729 $ EXHEADER_MD5 := md5.h
730 $ EXHEADER_SHA := sha.h
731 $ EXHEADER_MDC2 := mdc2.h
732 $ EXHEADER_HMAC := hmac.h
733 $ EXHEADER_RIPEMD := ripemd.h
734 $ EXHEADER_WHRLPOOL := whrlpool.h
735 $ EXHEADER_DES := des.h, des_old.h
736 $ EXHEADER_AES := aes.h
737 $ EXHEADER_RC2 := rc2.h
738 $ EXHEADER_RC4 := rc4.h
739 $ EXHEADER_RC5 := rc5.h
740 $ EXHEADER_IDEA := idea.h
741 $ EXHEADER_BF := blowfish.h
742 $ EXHEADER_CAST := cast.h
743 $ EXHEADER_CAMELLIA := camellia.h
744 $ EXHEADER_SEED := seed.h
745 $ EXHEADER_MODES := modes.h
746 $ EXHEADER_BN := bn.h
747 $ EXHEADER_EC := ec.h
748 $ EXHEADER_RSA := rsa.h
749 $ EXHEADER_DSA := dsa.h
750 $ EXHEADER_ECDSA := ecdsa.h
751 $ EXHEADER_DH := dh.h
752 $ EXHEADER_ECDH := ecdh.h
753 $ EXHEADER_DSO := dso.h
754 $ EXHEADER_ENGINE := engine.h
755 $ EXHEADER_BUFFER := buffer.h
756 $ EXHEADER_BIO := bio.h
757 $ EXHEADER_STACK := stack.h, safestack.h
758 $ EXHEADER_LHASH := lhash.h
759 $ EXHEADER_RAND := rand.h
760 $ EXHEADER_ERR := err.h
761 $ EXHEADER_EVP := evp.h
762 $ EXHEADER_ASN1 := asn1.h, asn1_mac.h, asn1t.h
763 $ EXHEADER_PEM := pem.h, pem2.h
764 $ EXHEADER_X509 := x509.h, x509_vfy.h
765 $ EXHEADER_X509V3 := x509v3.h
766 $ EXHEADER_CONF := conf.h, conf_api.h
767 $ EXHEADER_TXT_DB := txt_db.h
768 $ EXHEADER_PKCS7 := pkcs7.h
769 $ EXHEADER_PKCS12 := pkcs12.h
770 $ EXHEADER_COMP := comp.h
771 $ EXHEADER_OCSP := ocsp.h
772 $ EXHEADER_UI := ui.h, ui_compat.h
773 $ EXHEADER_KRB5 := krb5_asn.h
774 $ EXHEADER_CMS := cms.h
775 $ EXHEADER_PQUEUE := pqueue.h
776 $ EXHEADER_TS := ts.h
777 $ EXHEADER_JPAKE := jpake.h
778 $ EXHEADER_SRP := srp.h
779 $!!! EXHEADER_STORE := store.h, str_compat.h
780 $ EXHEADER_STORE := store.h
781 $ EXHEADER_CMAC := cmac.h
785 $ sdir = f$edit( f$element( i, ",", sdirs), "trim")
787 $ if (sdir .eqs. ",") then goto loop_sdirs_end
788 $ hdr_list = exheader_'sdir'
789 $ if (sdir .nes. "") then sdir = "."+ sdir
790 $ copy [.crypto'sdir']'hdr_list' sys$disk:[.include.openssl]
794 $! Copy All The ".H" Files From The [.SSL] Directory.
796 $! (keep these in the same order as ssl/Makefile)
797 $ EXHEADER := ssl.h, ssl2.h, ssl3.h, ssl23.h, tls1.h, dtls1.h, kssl.h, srtp.h
798 $ copy sys$disk:[.ssl]'exheader' sys$disk:[.include.openssl]
800 $! Purge the [.include.openssl] header files.
802 $ purge sys$disk:[.include.openssl]*.h
804 $! That's All, Time To RETURN.
808 $! Build The "[.xxx.EXE.CRYPTO]SSL_LIBCRYPTO''LIB32'.OLB" Library.
812 $! Tell The User What We Are Doing.
814 $ WRITE SYS$OUTPUT ""
816 "Building The [.",ARCHD,".EXE.CRYPTO]SSL_LIBCRYPTO''LIB32'.OLB Library."
818 $! Go To The [.CRYPTO] Directory.
820 $ SET DEFAULT SYS$DISK:[.CRYPTO]
822 $! Build The [.xxx.EXE.CRYPTO]LIBCRYPTO.OLB Library.
824 $ @CRYPTO-LIB LIBRARY 'DEBUGGER' "''COMPILER'" "''TCPIP_TYPE'" -
825 "''ISSEVEN'" "''BUILDPART'" "''POINTER_SIZE'" "''ZLIB'"
827 $! Build The [.xxx.EXE.CRYPTO]*.EXE Test Applications.
829 $!!! DISABLED, as these test programs lack any support
830 $!!!$ @CRYPTO-LIB APPS 'DEBUGGER' "''COMPILER'" "''TCPIP_TYPE'" -
831 $!!! "''ISSEVEN'" "''BUILDPART'" "''POINTER_SIZE'" "''ZLIB'"
833 $! Go Back To The Main Directory.
841 $! Build The "[.xxx.EXE.SSL]SSL_LIBSSL''LIB32'.OLB" Library.
845 $! Tell The User What We Are Doing.
847 $ WRITE SYS$OUTPUT ""
849 "Building The [.",ARCHD,".EXE.SSL]SSL_LIBSSL''LIB32'.OLB Library."
851 $! Go To The [.SSL] Directory.
853 $ SET DEFAULT SYS$DISK:[.SSL]
855 $! Build The [.xxx.EXE.SSL]LIBSSL.OLB Library.
857 $ @SSL-LIB LIBRARY 'DEBUGGER' "''COMPILER'" "''TCPIP_TYPE'" -
858 "''ISSEVEN'" "''POINTER_SIZE'" "''ZLIB'"
860 $! Go Back To The Main Directory.
868 $! Build The "[.xxx.EXE.SSL]SSL_TASK.EXE" Program.
872 $! Tell The User What We Are Doing.
874 $ WRITE SYS$OUTPUT ""
876 "Building DECNet Based SSL Engine, [.",ARCHD,".EXE.SSL]SSL_TASK.EXE"
878 $! Go To The [.SSL] Directory.
880 $ SET DEFAULT SYS$DISK:[.SSL]
882 $! Build The [.xxx.EXE.SSL]SSL_TASK.EXE
884 $ @SSL-LIB SSL_TASK 'DEBUGGER' "''COMPILER'" "''TCPIP_TYPE'" -
885 "''ISSEVEN'" "''POINTER_SIZE'" "''ZLIB'"
887 $! Go Back To The Main Directory.
891 $! That's All, Time To RETURN.
895 $! Build The OpenSSL Test Programs.
899 $! Tell The User What We Are Doing.
901 $ WRITE SYS$OUTPUT ""
902 $ WRITE SYS$OUTPUT "Building The OpenSSL [.",ARCHD,".EXE.TEST] Test Utilities."
904 $! Go To The [.TEST] Directory.
906 $ SET DEFAULT SYS$DISK:[.TEST]
908 $! Build The Test Programs.
910 $ @MAKETESTS 'DEBUGGER' "''COMPILER'" "''TCPIP_TYPE'" "''ISSEVEN'" -
911 "''POINTER_SIZE'" "''ZLIB'"
913 $! Go Back To The Main Directory.
917 $! That's All, Time To RETURN.
921 $! Build The OpenSSL Application Programs.
925 $! Tell The User What We Are Doing.
927 $ WRITE SYS$OUTPUT ""
928 $ WRITE SYS$OUTPUT "Building OpenSSL [.",ARCHD,".EXE.APPS] Applications."
930 $! Go To The [.APPS] Directory.
932 $ SET DEFAULT SYS$DISK:[.APPS]
934 $! Build The Application Programs.
936 $ @MAKEAPPS 'DEBUGGER' "''COMPILER'" "''TCPIP_TYPE'" "''ISSEVEN'" -
937 "" "''POINTER_SIZE'" "''ZLIB'"
939 $! Go Back To The Main Directory.
943 $! That's All, Time To RETURN.
947 $! Build The OpenSSL Application Programs.
951 $! Tell The User What We Are Doing.
953 $ WRITE SYS$OUTPUT ""
954 $ WRITE SYS$OUTPUT "Building OpenSSL [.",ARCHD,".EXE.ENGINES] Engines."
956 $! Go To The [.ENGINES] Directory.
958 $ SET DEFAULT SYS$DISK:[.ENGINES]
960 $! Build The Application Programs.
962 $ @MAKEENGINES ENGINES 'DEBUGGER' "''COMPILER'" "''TCPIP_TYPE'" -
963 "''ISSEVEN'" "''BUILDPART'" "''POINTER_SIZE'" "''ZLIB'"
965 $! Go Back To The Main Directory.
969 $! That's All, Time To RETURN.
973 $! Check The User's Options.
977 $! Check if there's a "part", and separate it out
979 $ BUILDPART = F$ELEMENT(1,"/",P1)
980 $ IF BUILDPART .EQS. "/"
984 $ P1 = F$EXTRACT(0,F$LENGTH(P1) - F$LENGTH(BUILDPART) - 1, P1)
987 $! Check To See If P1 Is Blank.
992 $! P1 Is ALL, So Build Everything.
994 $ BUILDCOMMAND = "ALL"
1000 $! Else, Check To See If P1 Has A Valid Argument.
1002 $ IF (P1.EQS."CONFIG").OR.(P1.EQS."BUILDINF").OR.(P1.EQS."SOFTLINKS") -
1003 .OR.(P1.EQS."BUILDALL") -
1004 .OR.(P1.EQS."CRYPTO").OR.(P1.EQS."SSL") -
1005 .OR.(P1.EQS."SSL_TASK").OR.(P1.EQS."TEST").OR.(P1.EQS."APPS") -
1006 .OR.(P1.EQS."ENGINES")
1009 $! A Valid Argument.
1017 $! Tell The User We Don't Know What They Want.
1019 $ WRITE SYS$OUTPUT ""
1020 $ WRITE SYS$OUTPUT "USAGE: @MAKEVMS.COM [Target] [Pointer size] [Debug option] <Compiler>"
1021 $ WRITE SYS$OUTPUT ""
1022 $ WRITE SYS$OUTPUT "Example: @MAKEVMS.COM ALL """" NODEBUG "
1023 $ WRITE SYS$OUTPUT ""
1024 $ WRITE SYS$OUTPUT "The Target ",P1," Is Invalid. The Valid Target Options Are:"
1025 $ WRITE SYS$OUTPUT ""
1026 $ WRITE SYS$OUTPUT " ALL : Just Build Everything."
1027 $ WRITE SYS$OUTPUT " CONFIG : Just build the [.CRYPTO._xxx]OPENSSLCONF.H file."
1028 $ WRITE SYS$OUTPUT " BUILDINF : Just build the [.CRYPTO._xxx]BUILDINF.H file."
1029 $ WRITE SYS$OUTPUT " SOFTLINKS: Just Fix The Unix soft links."
1030 $ WRITE SYS$OUTPUT " BUILDALL : Same as ALL, except CONFIG, BUILDINF and SOFTILNKS aren't done."
1031 $ WRITE SYS$OUTPUT " CRYPTO : To Build Just The [.xxx.EXE.CRYPTO]LIBCRYPTO.OLB Library."
1032 $ WRITE SYS$OUTPUT " CRYPTO/x : To Build Just The x Part Of The"
1033 $ WRITE SYS$OUTPUT " [.xxx.EXE.CRYPTO]LIBCRYPTO.OLB Library."
1034 $ WRITE SYS$OUTPUT " SSL : To Build Just The [.xxx.EXE.SSL]LIBSSL.OLB Library."
1035 $ WRITE SYS$OUTPUT " SSL_TASK : To Build Just The [.xxx.EXE.SSL]SSL_TASK.EXE Program."
1036 $ WRITE SYS$OUTPUT " TEST : To Build Just The OpenSSL Test Programs."
1037 $ WRITE SYS$OUTPUT " APPS : To Build Just The OpenSSL Application Programs."
1038 $ WRITE SYS$OUTPUT " ENGINES : To Build Just The ENGINES"
1039 $ WRITE SYS$OUTPUT ""
1040 $ WRITE SYS$OUTPUT " Where 'xxx' Stands For:"
1041 $ WRITE SYS$OUTPUT ""
1042 $ WRITE SYS$OUTPUT " ALPHA[64]: Alpha Architecture."
1043 $ WRITE SYS$OUTPUT " IA64[64] : IA64 Architecture."
1044 $ WRITE SYS$OUTPUT " VAX : VAX Architecture."
1045 $ WRITE SYS$OUTPUT ""
1051 $! End The Valid Argument Check.
1055 $! End The P1 Check.
1059 $! Check P2 (POINTER_SIZE).
1061 $ IF (P2 .NES. "") .AND. (ARCH .NES. "VAX")
1064 $ IF (P2 .EQS. "32")
1066 $ POINTER_SIZE = "32"
1068 $ POINTER_SIZE = F$EDIT( P2, "COLLAPSE, UPCASE")
1069 $ IF ((POINTER_SIZE .EQS. "64") .OR. -
1070 (POINTER_SIZE .EQS. "64=") .OR. -
1071 (POINTER_SIZE .EQS. "64=ARGV"))
1073 $ ARCHD = ARCH+ "_64"
1077 $! Tell The User Entered An Invalid Option.
1079 $ WRITE SYS$OUTPUT ""
1080 $ WRITE SYS$OUTPUT "The Option ", P2, -
1081 " Is Invalid. The Valid Options Are:"
1082 $ WRITE SYS$OUTPUT ""
1083 $ WRITE SYS$OUTPUT -
1084 " """" : Compile with default (short) pointers."
1085 $ WRITE SYS$OUTPUT -
1086 " 32 : Compile with 32-bit (short) pointers."
1087 $ WRITE SYS$OUTPUT -
1088 " 64 : Compile with 64-bit (long) pointers (auto ARGV)."
1089 $ WRITE SYS$OUTPUT -
1090 " 64= : Compile with 64-bit (long) pointers (no ARGV)."
1091 $ WRITE SYS$OUTPUT -
1092 " 64=ARGV : Compile with 64-bit (long) pointers (ARGV)."
1093 $ WRITE SYS$OUTPUT ""
1103 $! End The P2 (POINTER_SIZE) Check.
1107 $! Check To See If P3 Is Blank.
1109 $ IF (P3.EQS."NODEBUG")
1112 $! P3 Is NODEBUG, So Compile Without Debugger Information.
1114 $ DEBUGGER = "NODEBUG"
1120 $! Check To See If We Are To Compile With Debugger Information.
1122 $ IF (P3.EQS."DEBUG")
1125 $! Compile With Debugger Information.
1127 $ DEBUGGER = "DEBUG"
1133 $! Tell The User Entered An Invalid Option.
1135 $ WRITE SYS$OUTPUT ""
1136 $ WRITE SYS$OUTPUT "The Option ",P3," Is Invalid. The Valid Options Are:"
1137 $ WRITE SYS$OUTPUT ""
1138 $ WRITE SYS$OUTPUT " DEBUG : Compile With The Debugger Information."
1139 $ WRITE SYS$OUTPUT " NODEBUG : Compile Without The Debugger Information."
1140 $ WRITE SYS$OUTPUT ""
1146 $! End The Valid Argument Check.
1150 $! End The P3 Check.
1154 $! Check To See If P4 Is Blank.
1159 $! O.K., The User Didn't Specify A Compiler, Let's Try To
1160 $! Find Out Which One To Use.
1162 $! Check To See If We Have GNU C.
1164 $ IF (F$TRNLNM("GNU_CC").NES."")
1167 $! Looks Like GNUC, Set To Use GNUC.
1171 $! Tell The User We Are Using GNUC.
1173 $ WRITE SYS$OUTPUT "Using GNU 'C' Compiler."
1175 $! End The GNU C Compiler Check.
1179 $! Check To See If We Have VAXC Or DECC.
1181 $ IF (F$GETSYI("CPU").GE.128).OR.(F$TRNLNM("DECC$CC_DEFAULT").EQS."/DECC")
1184 $! Looks Like DECC, Set To Use DECC.
1188 $! Tell The User We Are Using DECC.
1190 $ WRITE SYS$OUTPUT "Using DECC 'C' Compiler."
1196 $! Looks Like VAXC, Set To Use VAXC.
1200 $! Tell The User We Are Using VAX C.
1202 $ WRITE SYS$OUTPUT "Using VAXC 'C' Compiler."
1204 $! End The DECC & VAXC Compiler Check.
1212 $! Check To See If The User Entered A Valid Parameter.
1214 $ IF (P4.EQS."VAXC").OR.(P4.EQS."DECC").OR.(P4.EQS."GNUC")!.OR.(P4.EQS."LINK")
1217 $! Check To See If The User Wanted To Just LINK.
1219 $ IF (P4.EQS."LINK")
1222 $! Looks Like LINK-only
1226 $! Tell The User We Are Only Linking.
1228 $ WRITE SYS$OUTPUT "LINK Only. This actually NOT YET SUPPORTED!"
1234 $! Check To See If The User Wanted DECC.
1236 $ IF (P4.EQS."DECC")
1239 $! Looks Like DECC, Set To Use DECC.
1243 $! Tell The User We Are Using DECC.
1245 $ WRITE SYS$OUTPUT "Using DECC 'C' Compiler."
1251 $! Check To See If We Are To Use VAXC.
1253 $ IF (P4.EQS."VAXC")
1256 $! Looks Like VAXC, Set To Use VAXC.
1260 $! Tell The User We Are Using VAX C.
1262 $ WRITE SYS$OUTPUT "Using VAXC 'C' Compiler."
1268 $! Check To See If We Are To Use GNU C.
1270 $ IF (P4.EQS."GNUC")
1273 $! Looks Like GNUC, Set To Use GNUC.
1277 $! Tell The User We Are Using GNUC.
1279 $ WRITE SYS$OUTPUT "Using GNU 'C' Compiler."
1281 $! End The GNU C Check.
1285 $! Else The User Entered An Invalid Argument.
1289 $! Tell The User We Don't Know What They Want.
1291 $ WRITE SYS$OUTPUT ""
1292 $ WRITE SYS$OUTPUT "The Option ",P4," Is Invalid. The Valid Options Are:"
1293 $ WRITE SYS$OUTPUT ""
1294 $ WRITE SYS$OUTPUT " VAXC : To Compile With VAX C."
1295 $ WRITE SYS$OUTPUT " DECC : To Compile With DEC C."
1296 $ WRITE SYS$OUTPUT " GNUC : To Compile With GNU C."
1297 $ WRITE SYS$OUTPUT ""
1303 $! End The Valid Argument Check.
1307 $! End The P4 Check.
1311 $! Time to check the contents of P5, and to make sure we get the correct
1314 $ IF P5.EQS."SOCKETSHR" .OR. P5.EQS."MULTINET" .OR. P5.EQS."UCX" -
1315 .OR. P5.EQS."TCPIP" .OR. P5.EQS."NONE"
1318 $! Check to see if SOCKETSHR was chosen
1320 $ IF P5.EQS."SOCKETSHR"
1323 $! Set the library to use SOCKETSHR
1325 $ TCPIP_LIB = "SYS$DISK:[-.VMS]SOCKETSHR_SHR.OPT /OPTIONS"
1329 $ WRITE SYS$OUTPUT "Using SOCKETSHR for TCP/IP"
1331 $! Done with SOCKETSHR
1335 $! Check to see if MULTINET was chosen
1337 $ IF P5.EQS."MULTINET"
1340 $! Set the library to use UCX emulation.
1346 $ WRITE SYS$OUTPUT "Using MultiNet via UCX emulation for TCP/IP"
1348 $! Done with MULTINET
1352 $! Check to see if UCX was chosen
1357 $! Set the library to use UCX.
1359 $ TCPIP_LIB = "SYS$DISK:[-.VMS]UCX_SHR_DECC.OPT /OPTIONS"
1363 $ WRITE SYS$OUTPUT "Using UCX or an emulation thereof for TCP/IP"
1369 $! Check to see if TCPIP was chosen
1374 $! Set the library to use TCPIP (post UCX).
1376 $ TCPIP_LIB = "SYS$DISK:[-.VMS]TCPIP_SHR_DECC.OPT /OPTIONS"
1380 $ WRITE SYS$OUTPUT "Using TCPIP (post UCX) for TCP/IP"
1386 $! Check to see if NONE was chosen
1391 $! Do not use a TCPIP library.
1397 $ WRITE SYS$OUTPUT "A specific TCPIP library will not be used."
1403 $! Set the TCPIP_TYPE symbol
1409 $ WRITE SYS$OUTPUT "TCP/IP library spec: ", TCPIP_LIB
1411 $! Else The User Entered An Invalid Argument.
1417 $! Tell The User We Don't Know What They Want.
1419 $ WRITE SYS$OUTPUT ""
1420 $ WRITE SYS$OUTPUT "The Option ",P5," Is Invalid. The Valid Options Are:"
1421 $ WRITE SYS$OUTPUT ""
1422 $ WRITE SYS$OUTPUT " SOCKETSHR : To link with SOCKETSHR TCP/IP library."
1423 $ WRITE SYS$OUTPUT " UCX : To link with UCX TCP/IP library."
1424 $ WRITE SYS$OUTPUT " TCPIP : To link with TCPIP TCP/IP (post UCX) library."
1425 $ WRITE SYS$OUTPUT " NONE : To not link with a specific TCP/IP library."
1426 $ WRITE SYS$OUTPUT ""
1433 $! If TCPIP is not defined, then hardcode it to make
1434 $! it clear that no TCPIP is desired.
1439 $ TCPIP_TYPE = "NONE"
1442 $! Set the TCPIP_TYPE symbol
1448 $! Done with TCP/IP libraries
1452 $! Special Threads For OpenVMS v7.1 Or Later
1454 $! Written By: Richard Levitte
1455 $! richard@levitte.org
1458 $! Check To See If We Have A Option For P6.
1463 $! Get The Version Of VMS We Are Using.
1466 $ TMP = F$ELEMENT(0,"-",F$EXTRACT(1,4,VMS_VERSION))
1467 $ TMP = F$INTEGER(F$ELEMENT(0,".",TMP)+F$ELEMENT(1,".",TMP))
1469 $! Check To See If The VMS Version Is v7.1 Or Later.
1474 $! We Have OpenVMS v7.1 Or Later, So Use The Special Threads.
1476 $ ISSEVEN := ,PTHREAD_USE_D4
1478 $! End The VMS Version Check.
1482 $! End The P6 Check.
1487 $! Check To See If We Have A ZLIB Option.
1490 $ IF (ZLIB .NES. "")
1493 $! Check for expected ZLIB files.
1496 $ file1 = f$parse( "zlib.h", ZLIB, , , "SYNTAX_ONLY")
1497 $ if (f$search( file1) .eqs. "")
1499 $ WRITE SYS$OUTPUT ""
1500 $ WRITE SYS$OUTPUT "The Option ", ZLIB, " Is Invalid."
1501 $ WRITE SYS$OUTPUT " Can't find header: ''file1'"
1505 $ file2 = f$parse( ZLIB, "libz.olb", , , "SYNTAX_ONLY")
1506 $ if (f$search( file2) .eqs. "")
1510 $ WRITE SYS$OUTPUT ""
1511 $ WRITE SYS$OUTPUT "The Option ", ZLIB, " Is Invalid."
1513 $ WRITE SYS$OUTPUT " Can't find library: ''file2'"
1514 $ WRITE SYS$OUTPUT ""
1519 $ WRITE SYS$OUTPUT ""
1529 $ WRITE SYS$OUTPUT "ZLIB library spec: ", file2
1531 $! End The ZLIB Check.
1535 $! Time To RETURN...
1541 $! Close any open files.
1543 $ if (f$trnlnm( "h_file", "LNM$PROCESS", 0, "SUPERVISOR") .nes. "") then -
1546 $! Restore the original default device:[directory].
1548 $ SET DEFAULT 'DEF_ORIG'