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>
11 $! This procedure creates the SSL libraries of "[.xxx.EXE.CRYPTO]LIBCRYPTO.OLB"
12 $! "[.xxx.EXE.SSL]LIBSSL.OLB" and if specified "[.xxx.EXE.RSAREF]LIBRSAGLUE.OLB".
13 $! The "xxx" denotes the machine architecture of AXP or VAX.
15 $! This procedures accepts two command line options listed below.
17 $! Specify one of the following build options for P1.
19 $! ALL Just build "everything".
20 $! CONFIG Just build the "[.CRYPTO]OPENSSLCONF.H" file.
21 $! BUILDINF Just build the "[.CRYPTO]BUILDINF.H" file.
22 $! SOFTLINKS Just fix the Unix soft links.
23 $! BUILDALL Same as ALL, except CONFIG, BUILDINF and SOFTILNKS aren't done.
24 $! RSAREF Just build the "[.xxx.EXE.RSAREF]LIBRSAGLUE.OLB" library.
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.
34 $! Specify RSAREF as P2 to compile using the RSAREF Library.
35 $! If you specify NORSAREF, it will compile without using RSAREF.
36 $! (If in the United States, You Must Compile Using RSAREF).
38 $! Note: The RSAREF libraries are NOT INCLUDED and you have to
39 $! download it from "ftp://ftp.rsa.com/rsaref". You have to
40 $! get the ".tar-Z" file as the ".zip" file dosen't have the
41 $! directory structure stored. You have to extract the file
42 $! into the [.RSAREF] directory as that is where the scripts
43 $! will look for the files.
45 $! Speficy DEBUG or NODEBUG as P3 to compile with or without debugging
48 $! Specify which compiler at P4 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 speficy 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 $! SOCKETSHR for SOCKETSHR+NETLIB
65 $! P6, if defined, sets a compiler thread NOT needed on OpenVMS 7.1 (and up)
68 $! Check if we're in a batch job, and make sure we get to
69 $! the directory this script is in
71 $ IF F$MODE() .EQS. "BATCH"
73 $ COMNAME=F$ENVIRONMENT("PROCEDURE")
74 $ COMPATH=F$PARSE("A.;",COMNAME) - "A.;"
78 $! Check Which Architecture We Are Using.
80 $ IF (F$GETSYI("CPU").GE.128)
83 $! The Architecture Is AXP.
91 $! The Architecture Is VAX.
95 $! End The Architecture Check.
99 $! Check To Make Sure We Have Valid Command Line Parameters.
101 $ GOSUB CHECK_OPTIONS
103 $! Check To See What We Are To Do.
105 $ IF (BUILDCOMMAND.EQS."ALL")
108 $! Start with building the OpenSSL configuration file.
112 $! Create The "BUILDINF.H" Include File.
116 $! Fix The Unix Softlinks.
122 $ IF (BUILDCOMMAND.EQS."ALL".OR.BUILDCOMMAND.EQS."BUILDALL")
125 $! Check To See If We Are Going To Be Building The
126 $! [.xxx.EXE.RSAREF]LIBRSAGLUE.OLB Library.
128 $ IF (RSAREF.EQS."RSAREF")
131 $! Build The [.xxx.EXE.RSAREF]LIBRSAGLUE.OLB Library.
135 $! End The RSAREF Check.
139 $! Build The [.xxx.EXE.CRYPTO]LIBCRYPTO.OLB Library.
143 $! Build The [.xxx.EXE.SSL]LIBSSL.OLB Library.
147 $! Build The [.xxx.EXE.SSL]SSL_TASK.EXE DECNet SSL Engine.
151 $! Build The [.xxx.EXE.TEST] OpenSSL Test Utilities.
155 $! Build The [.xxx.EXE.APPS] OpenSSL Application Utilities.
163 $! Build Just What The User Wants Us To Build.
165 $ GOSUB 'BUILDCOMMAND'
173 $! Rebuild The "[.CRYPTO]OPENSSLCONF.H" file.
177 $! Tell The User We Are Creating The [.CRYPTO]OPENSSLCONF.H File.
179 $ WRITE SYS$OUTPUT "Creating [.CRYPTO]OPENSSLCONF.H Include File."
181 $! Create The [.CRYPTO]OPENSSLCONF.H File.
183 $ OPEN/WRITE H_FILE SYS$DISK:[.CRYPTO]OPENSSLCONF.H
185 $! Write The [.CRYPTO]OPENSSLCONF.H File.
187 $ WRITE H_FILE "/* This file was automatically built using makevms.com */"
188 $ WRITE H_FILE "/* and [.CRYPTO]OPENSSLCONF.H_IN */"
190 $! Different tar version may have named the file differently
191 $ IF F$SEARCH("[.CRYPTO]OPENSSLCONF.H_IN") .NES. ""
193 $ TYPE [.CRYPTO]OPENSSLCONF.H_IN /OUTPUT=H_FILE:
195 $ IF F$SEARCH("[.CRYPTO]OPENSSLCONF_H.IN") .NES. ""
197 $ TYPE [.CRYPTO]OPENSSLCONF_H.IN /OUTPUT=H_FILE:
199 $ WRITE SYS$ERROR "Couldn't find a [.CRYPTO]OPENSSLCONF.H_IN. Exiting!"
204 $ IF ARCH .EQS. "AXP"
207 $! Write the Alpha specific data
209 $ WRITE H_FILE "#if defined(HEADER_RC4_H)"
210 $ WRITE H_FILE "#undef RC4_INT"
211 $ WRITE H_FILE "#define RC4_INT unsigned int"
212 $ WRITE H_FILE "#undef RC4_CHUNK"
213 $ WRITE H_FILE "#define RC4_CHUNK unsigned long long"
214 $ WRITE H_FILE "#endif"
216 $ WRITE H_FILE "#if defined(HEADER_DES_LOCL_H)"
217 $ WRITE H_FILE "#undef DES_LONG"
218 $ WRITE H_FILE "#define DES_LONG unsigned int"
219 $ WRITE H_FILE "#undef DES_PTR"
220 $ WRITE H_FILE "#define DES_PTR"
221 $ WRITE H_FILE "#undef DES_RISC1"
222 $ WRITE H_FILE "#undef DES_RISC2"
223 $ WRITE H_FILE "#define DES_RISC1"
224 $ WRITE H_FILE "#undef DES_UNROLL"
225 $ WRITE H_FILE "#define DES_UNROLL"
226 $ WRITE H_FILE "#endif"
228 $ WRITE H_FILE "#if defined(HEADER_BN_H)"
229 $ WRITE H_FILE "#undef SIXTY_FOUR_BIT_LONG"
230 $ WRITE H_FILE "#undef SIXTY_FOUR_BIT"
231 $ WRITE H_FILE "#define SIXTY_FOUR_BIT"
232 $ WRITE H_FILE "#undef THIRTY_TWO_BIT"
233 $ WRITE H_FILE "#undef SIXTEEN_BIT"
234 $ WRITE H_FILE "#undef EIGHT_BIT"
235 $ WRITE H_FILE "#endif"
241 $! Write the VAX specific data
243 $ WRITE H_FILE "#if defined(HEADER_RC4_H)"
244 $ WRITE H_FILE "#undef RC4_INT"
245 $ WRITE H_FILE "#define RC4_INT unsigned char"
246 $ WRITE H_FILE "#undef RC4_CHUNK"
247 $ WRITE H_FILE "#define RC4_CHUNK unsigned long"
248 $ WRITE H_FILE "#endif"
250 $ WRITE H_FILE "#if defined(HEADER_DES_LOCL_H)"
251 $ WRITE H_FILE "#undef DES_LONG"
252 $ WRITE H_FILE "#define DES_LONG unsigned long"
253 $ WRITE H_FILE "#undef DES_PTR"
254 $ WRITE H_FILE "#define DES_PTR"
255 $ WRITE H_FILE "#undef DES_RISC1"
256 $ WRITE H_FILE "#undef DES_RISC2"
257 $ WRITE H_FILE "#undef DES_UNROLL"
258 $ WRITE H_FILE "#endif"
260 $ WRITE H_FILE "#if defined(HEADER_BN_H)"
261 $ WRITE H_FILE "#undef SIXTY_FOUR_BIT_LONG"
262 $ WRITE H_FILE "#undef SIXTY_FOUR_BIT"
263 $ WRITE H_FILE "#undef THIRTY_TWO_BIT"
264 $ WRITE H_FILE "#define THIRTY_TWO_BIT"
265 $ WRITE H_FILE "#undef SIXTEEN_BIT"
266 $ WRITE H_FILE "#undef EIGHT_BIT"
267 $ WRITE H_FILE "#endif"
273 $! Close the [.CRYPTO]OPENSSLCONF.H file
277 $! That's All, Time To RETURN.
281 $! Rebuild The "[.CRYPTO]BUILDINF.H" file.
285 $! Tell The User We Are Creating The [.CRYPTO]BUILDINF.H File.
287 $ WRITE SYS$OUTPUT "Creating [.CRYPTO]BUILDINF.H Include File."
289 $! Create The [.CRYPTO]BUILDINF.H File.
291 $ OPEN/WRITE H_FILE SYS$DISK:[.CRYPTO]BUILDINF.H
293 $! Get The Current Date & Time.
297 $! Write The [.CRYPTO]BUILDINF.H File.
299 $ WRITE H_FILE "#define CFLAGS """" /* Not filled in for now */"
300 $ WRITE H_FILE "#define PLATFORM ""VMS"""
301 $ WRITE H_FILE "#define DATE ""''TIME'"" "
303 $! Close The [.CRYPTO]BUILDINF.H File.
307 $! That's All, Time To RETURN.
311 $! Copy a lot of files around.
315 $! Tell The User We Are Partly Rebuilding The [.TEST] Directory.
317 $ WRITE SYS$OUTPUT "Rebuilding The '[.APPS]MD5.C' And '[.APPS]RMD160.C' Files."
319 $ DELETE SYS$DISK:[.APPS]MD5.C;*,RMD160.C;*
321 $! Copy MD5.C from [.CRYPTO.MD5] into [.APPS]
323 $ COPY SYS$DISK:[.CRYPTO.MD5]MD5.C SYS$DISK:[.APPS]
325 $! Copy RMD160.C from [.CRYPTO.RIPEMD] into [.APPS]
327 $ COPY SYS$DISK:[.CRYPTO.RIPEMD]RMD160.C SYS$DISK:[.APPS]
329 $! Tell The User We Are Partly Rebuilding The [.TEST] Directory.
331 $ WRITE SYS$OUTPUT "Rebuilding The '[.TEST]*.C' Files."
333 $! First, We Have To "Rebuild" The "[.TEST]" Directory, So Delete
334 $! All The "C" Files That Are Currently There Now.
336 $ DELETE SYS$DISK:[.TEST]*.C;*
338 $! Copy all the *TEST.C files from [.CRYPTO...] into [.TEST]
340 $ COPY SYS$DISK:[.CRYPTO.*]%*TEST.C SYS$DISK:[.TEST]
342 $! Copy all the *TEST.C files from [.SSL...] into [.TEST]
344 $ COPY SYS$DISK:[.SSL]%*TEST.C SYS$DISK:[.TEST]
346 $! Tell The User We Are Rebuilding The [.INCLUDE.OPENSSL] Directory.
348 $ WRITE SYS$OUTPUT "Rebuilding The '[.INCLUDE.OPENSSL]' Directory."
350 $! First, make sure the directory exists
352 $ IF F$PARSE("SYS$DISK:[.INCLUDE.OPENSSL]") .EQS. "" THEN -
353 CREATE/DIRECTORY SYS$DISK:[.INCLUDE.OPENSSL]
355 $! Copy All The ".H" Files From The Main Directory.
357 $ EXHEADER := e_os.h,e_os2.h
358 $ COPY 'EXHEADER' SYS$DISK:[.INCLUDE.OPENSSL]
360 $! Copy All The ".H" Files From The [.CRYPTO] Directory Tree.
362 $ SDIRS := ,MD2,MD5,SHA,MDC2,HMAC,RIPEMD,-
363 DES,RC2,RC4,RC5,IDEA,BF,CAST,-
365 BUFFER,BIO,STACK,LHASH,RAND,ERR,OBJECTS,-
366 EVP,ASN1,PEM,X509,X509V3,-
367 CONF,TXT_DB,PKCS7,PKCS12,COMP
368 $ EXHEADER_ := crypto.h,tmdiff.h,opensslv.h,opensslconf.h,ebcdic.h
369 $ EXHEADER_MD2 := md2.h
370 $ EXHEADER_MD5 := md5.h
371 $ EXHEADER_SHA := sha.h
372 $ EXHEADER_MDC2 := mdc2.h
373 $ EXHEADER_HMAC := hmac.h
374 $ EXHEADER_RIPEMD := ripemd.h
375 $ EXHEADER_DES := des.h
376 $ EXHEADER_RC2 := rc2.h
377 $ EXHEADER_RC4 := rc4.h
378 $ EXHEADER_RC5 := rc5.h
379 $ EXHEADER_IDEA := idea.h
380 $ EXHEADER_BF := blowfish.h
381 $ EXHEADER_CAST := cast.h
382 $ EXHEADER_BN := bn.h
383 $ EXHEADER_RSA := rsa.h
384 $ EXHEADER_DSA := dsa.h
385 $ EXHEADER_DH := dh.h
386 $ EXHEADER_BUFFER := buffer.h
387 $ EXHEADER_BIO := bio.h
388 $ EXHEADER_STACK := stack.h,safestack.h
389 $ EXHEADER_LHASH := lhash.h
390 $ EXHEADER_RAND := rand.h
391 $ EXHEADER_ERR := err.h
392 $ EXHEADER_OBJECTS := objects.h
393 $ EXHEADER_EVP := evp.h
394 $ EXHEADER_ASN1 := asn1.h,asn1_mac.h
395 $ EXHEADER_PEM := pem.h,pem2.h
396 $ EXHEADER_X509 := x509.h,x509_vfy.h
397 $ EXHEADER_X509V3 := x509v3.h
398 $ EXHEADER_CONF := conf.h
399 $ EXHEADER_TXT_DB := txt_db.h
400 $ EXHEADER_PKCS7 := pkcs7.h
401 $ EXHEADER_PKCS12 := pkcs12.h
402 $ EXHEADER_COMP := comp.h
406 $ D = F$EDIT(F$ELEMENT(I, ",", SDIRS),"TRIM")
408 $ IF D .EQS. "," THEN GOTO LOOP_SDIRS_END
412 $ COPY [.CRYPTO]'tmp' SYS$DISK:[.INCLUDE.OPENSSL] !/LOG
414 $ COPY [.CRYPTO.'D']'tmp' SYS$DISK:[.INCLUDE.OPENSSL] !/LOG
419 $! Copy All The ".H" Files From The [.RSAREF] Directory.
421 $ EXHEADER := rsaref.h
422 $ COPY SYS$DISK:[.RSAREF]'EXHEADER' SYS$DISK:[.INCLUDE.OPENSSL]
424 $! Copy All The ".H" Files From The [.SSL] Directory.
426 $ EXHEADER := ssl.h,ssl2.h,ssl3.h,ssl23.h,tls1.h
427 $ COPY SYS$DISK:[.SSL]'EXHEADER' SYS$DISK:[.INCLUDE.OPENSSL]
429 $! Copy All The ".H" Files From The [.VMS] Directory.
431 $ EXHEADER := vms_idhacks.h
432 $ COPY SYS$DISK:[.VMS]'EXHEADER' SYS$DISK:[.INCLUDE.OPENSSL]
436 $ PURGE SYS$DISK:[.INCLUDE.OPENSSL]*.H
438 $! That's All, Time To RETURN.
442 $! Build The "[.xxx.EXE.CRYPTO]LIBCRYPTO.OLB" Library.
446 $! Tell The User What We Are Doing.
448 $ WRITE SYS$OUTPUT ""
449 $ WRITE SYS$OUTPUT "Building The [.",ARCH,".EXE.CRYPTO]LIBCRYPTO.OLB Library."
451 $! Go To The [.CRYPTO] Directory.
453 $ SET DEFAULT SYS$DISK:[.CRYPTO]
455 $! Build The [.xxx.EXE.CRYPTO]LIBCRYPTO.OLB Library.
457 $ @CRYPTO-LIB LIBRARY 'RSAREF' 'DEBUGGER' "''COMPILER'" "''TCPIP_TYPE'" "''ISSEVEN'" "''BUILDPART'"
459 $! Build The [.xxx.EXE.CRYPTO]*.EXE Test Applications.
461 $ @CRYPTO-LIB APPS 'RSAREF' 'DEBUGGER' "''COMPILER'" "''TCPIP_TYPE'" 'ISSEVEN'
463 $! Go Back To The Main Directory.
471 $! Build The [.xxx.EXE.RSAREF]LIBRSAGLUE Library.
475 $! Tell The User What We Are Doing.
477 $ WRITE SYS$OUTPUT ""
478 $ WRITE SYS$OUTPUT "Building The [.",ARCH,".EXE.RSAREF]LIBRSAGLUE.OLB Library."
480 $! Go To The [.RSAREF] Directory.
482 $ SET DEFAULT SYS$DISK:[.RSAREF]
484 $! Build The [.xxx.EXE.RSAREF]LIBRSAGLUE.OLB Library.
486 $ @RSAREF-LIB LIBRARY 'DEBUGGER' "''COMPILER'" 'ISSEVEN'
488 $! Go Back To The Main Directory.
496 $! Build The "[.xxx.EXE.SSL]LIBSSL.OLB" Library.
500 $! Tell The User What We Are Doing.
502 $ WRITE SYS$OUTPUT ""
503 $ WRITE SYS$OUTPUT "Building The [.",ARCH,".EXE.SSL]LIBSSL.OLB Library."
505 $! Go To The [.SSL] Directory.
507 $ SET DEFAULT SYS$DISK:[.SSL]
509 $! Build The [.xxx.EXE.SSL]LIBSSL.OLB Library.
511 $ @SSL-LIB LIBRARY 'RSAREF' 'DEBUGGER' "''COMPILER'" "''TCPIP_TYPE'" 'ISSEVEN'
513 $! Go Back To The Main Directory.
521 $! Build The "[.xxx.EXE.SSL]SSL_TASK.EXE" Program.
525 $! Tell The User What We Are Doing.
527 $ WRITE SYS$OUTPUT ""
528 $ WRITE SYS$OUTPUT "Building DECNet Based SSL Engine, [.",ARCH,".EXE.SSL]SSL_TASK.EXE"
530 $! Go To The [.SSL] Directory.
532 $ SET DEFAULT SYS$DISK:[.SSL]
534 $! Build The [.xxx.EXE.SSL]SSL_TASK.EXE
536 $ @SSL-LIB SSL_TASK 'RSAREF' 'DEBUGGER' "''COMPILER'" "''TCPIP_TYPE'" 'ISSEVEN'
538 $! Go Back To The Main Directory.
542 $! That's All, Time To RETURN.
546 $! Build The OpenSSL Test Programs.
550 $! Tell The User What We Are Doing.
552 $ WRITE SYS$OUTPUT ""
553 $ WRITE SYS$OUTPUT "Building The OpenSSL [.",ARCH,".EXE.TEST] Test Utilities."
555 $! Go To The [.TEST] Directory.
557 $ SET DEFAULT SYS$DISK:[.TEST]
559 $! Build The Test Programs.
561 $ @MAKETESTS 'RSAREF' 'DEBUGGER' "''COMPILER'" "''TCPIP_TYPE'" 'ISSEVEN'
563 $! Go Back To The Main Directory.
567 $! That's All, Time To RETURN.
571 $! Build The OpenSSL Application Programs.
575 $! Tell The User What We Are Doing.
577 $ WRITE SYS$OUTPUT ""
578 $ WRITE SYS$OUTPUT "Building OpenSSL [.",ARCH,".EXE.APPS] Applications."
580 $! Go To The [.APPS] Directory.
582 $ SET DEFAULT SYS$DISK:[.APPS]
584 $! Build The Application Programs.
586 $ @MAKEAPPS 'RSAREF' 'DEBUGGER' "''COMPILER'" "''TCPIP_TYPE'" 'ISSEVEN'
588 $! Go Back To The Main Directory.
592 $! That's All, Time To RETURN.
596 $! Check The User's Options.
600 $! Check if there's a "part", and separate it out
602 $ BUILDPART = F$ELEMENT(1,"/",P1)
603 $ IF BUILDPART .EQS. "/"
607 $ P1 = F$EXTRACT(0,F$LENGTH(P1) - F$LENGTH(BUILDPART) - 1, P1)
610 $! Check To See If P1 Is Blank.
615 $! P1 Is ALL, So Build Everything.
617 $ BUILDCOMMAND = "ALL"
623 $! Else, Check To See If P1 Has A Valid Arguement.
625 $ IF (P1.EQS."CONFIG").OR.(P1.EQS."BUILDINF").OR.(P1.EQS."SOFTLINKS") -
626 .OR.(P1.EQS."BUILDALL") -
627 .OR.(P1.EQS."CRYPTO").OR.(P1.EQS."SSL").OR.(P1.EQS."RSAREF") -
628 .OR.(P1.EQS."SSL_TASK").OR.(P1.EQS."TEST").OR.(P1.EQS."APPS")
631 $! A Valid Arguement.
639 $! Tell The User We Don't Know What They Want.
641 $ WRITE SYS$OUTPUT ""
642 $ WRITE SYS$OUTPUT "The Option ",P1," Is Invalid. The Valid Options Are:"
643 $ WRITE SYS$OUTPUT ""
644 $ WRITE SYS$OUTPUT " ALL : Just Build Everything."
645 $ WRITE SYS$OUTPUT " CONFIG : Just build the [.CRYPTO]OPENSSLCONF.H file."
646 $ WRITE SYS$OUTPUT " BUILDINF : Just build the [.CRYPTO]BUILDINF.H file."
647 $ WRITE SYS$OUTPUT " SOFTLINKS: Just Fix The Unix soft links."
648 $ WRITE SYS$OUTPUT " BUILDALL : Same as ALL, except CONFIG, BUILDINF and SOFTILNKS aren't done."
649 $ WRITE SYS$OUTPUT " RSAREF : To Build Just The [.xxx.EXE.RSAREF]LIBRSAGLUE.OLB Library."
650 $ WRITE SYS$OUTPUT " CRYPTO : To Build Just The [.xxx.EXE.CRYPTO]LIBCRYPTO.OLB Library."
651 $ WRITE SYS$OUTPUT " CRYPTO/x : To Build Just The x Part Of The"
652 $ WRITE SYS$OUTPUT " [.xxx.EXE.CRYPTO]LIBCRYPTO.OLB Library."
653 $ WRITE SYS$OUTPUT " SSL : To Build Just The [.xxx.EXE.SSL]LIBSSL.OLB Library."
654 $ WRITE SYS$OUTPUT " SSL_TASK : To Build Just The [.xxx.EXE.SSL]SSL_TASK.EXE Program."
655 $ WRITE SYS$OUTPUT " TEST : To Build Just The OpenSSL Test Programs."
656 $ WRITE SYS$OUTPUT " APPS : To Build Just The OpenSSL Application Programs."
657 $ WRITE SYS$OUTPUT ""
658 $ WRITE SYS$OUTPUT " Where 'xxx' Stands For:"
659 $ WRITE SYS$OUTPUT ""
660 $ WRITE SYS$OUTPUT " AXP : Alpha Architecture."
661 $ WRITE SYS$OUTPUT " VAX : VAX Architecture."
662 $ WRITE SYS$OUTPUT ""
668 $! End The Valid Argument Check.
676 $! Check To See If P2 Is Blank.
678 $ IF (P2.EQS."NORSAREF")
681 $! P2 Is NORSAREF, So Compile Without RSAREF.
683 $ RSAREF = "NORSAREF"
689 $! Check To See If We Are To Compile Using The RSAREF Library.
691 $ IF (P2.EQS."RSAREF")
694 $! Compile With RSAREF Library.
702 $! Tell The User Entered An Invalid Option..
704 $ WRITE SYS$OUTPUT ""
705 $ WRITE SYS$OUTPUT "The Option ",P2," Is Invalid. The Valid Options Are:"
706 $ WRITE SYS$OUTPUT ""
707 $ WRITE SYS$OUTPUT " RSAREF : To Compile With The RSAREF Library."
708 $ WRITE SYS$OUTPUT " NORSAREF : To Compile With The Regular RSA Library."
709 $ WRITE SYS$OUTPUT ""
715 $! End The Valid Arguemnt Check.
723 $! Check To See If P3 Is Blank.
725 $ IF (P3.EQS."NODEBUG")
728 $! P3 Is NODEBUG, So Compile Without Debugger Information.
730 $ DEBUGGER = "NODEBUG"
736 $! Check To See If We Are To Compile With Debugger Information.
738 $ IF (P3.EQS."DEBUG")
741 $! Compile With Debugger Information.
749 $! Tell The User Entered An Invalid Option..
751 $ WRITE SYS$OUTPUT ""
752 $ WRITE SYS$OUTPUT "The Option ",P3," Is Invalid. The Valid Options Are:"
753 $ WRITE SYS$OUTPUT ""
754 $ WRITE SYS$OUTPUT " DEBUG : Compile With The Debugger Information."
755 $ WRITE SYS$OUTPUT " NODEBUG : Compile Without The Debugger Information."
756 $ WRITE SYS$OUTPUT ""
762 $! End The Valid Arguement Check.
770 $! Check To See If P4 Is Blank.
775 $! O.K., The User Didn't Specify A Compiler, Let's Try To
776 $! Find Out Which One To Use.
778 $! Check To See If We Have GNU C.
780 $ IF (F$TRNLNM("GNU_CC").NES."")
783 $! Looks Like GNUC, Set To Use GNUC.
787 $! Tell The User We Are Using GNUC.
789 $ WRITE SYS$OUTPUT "Using GNU 'C' Compiler."
791 $! End The GNU C Compiler Check.
795 $! Check To See If We Have VAXC Or DECC.
797 $ IF (F$GETSYI("CPU").GE.128).OR.(F$TRNLNM("DECC$CC_DEFAULT").EQS."/DECC")
800 $! Looks Like DECC, Set To Use DECC.
804 $! Tell The User We Are Using DECC.
806 $ WRITE SYS$OUTPUT "Using DECC 'C' Compiler."
812 $! Looks Like VAXC, Set To Use VAXC.
816 $! Tell The User We Are Using VAX C.
818 $ WRITE SYS$OUTPUT "Using VAXC 'C' Compiler."
820 $! End The DECC & VAXC Compiler Check.
828 $! Check To See If The User Entered A Valid Paramter.
830 $ IF (P4.EQS."VAXC").OR.(P4.EQS."DECC").OR.(P4.EQS."GNUC")!.OR.(P4.EQS."LINK")
833 $! Check To See If The User Wanted To Just LINK.
838 $! Looks Like LINK-only
842 $! Tell The User We Are Only Linking.
844 $ WRITE SYS$OUTPUT "LINK Only. This actually NOT YET SUPPORTED!"
850 $! Check To See If The User Wanted DECC.
855 $! Looks Like DECC, Set To Use DECC.
859 $! Tell The User We Are Using DECC.
861 $ WRITE SYS$OUTPUT "Using DECC 'C' Compiler."
867 $! Check To See If We Are To Use VAXC.
872 $! Looks Like VAXC, Set To Use VAXC.
876 $! Tell The User We Are Using VAX C.
878 $ WRITE SYS$OUTPUT "Using VAXC 'C' Compiler."
884 $! Check To See If We Are To Use GNU C.
889 $! Looks Like GNUC, Set To Use GNUC.
893 $! Tell The User We Are Using GNUC.
895 $ WRITE SYS$OUTPUT "Using GNU 'C' Compiler."
897 $! End The GNU C Check.
901 $! Else The User Entered An Invalid Arguement.
905 $! Tell The User We Don't Know What They Want.
907 $ WRITE SYS$OUTPUT ""
908 $ WRITE SYS$OUTPUT "The Option ",P4," Is Invalid. The Valid Options Are:"
909 $ WRITE SYS$OUTPUT ""
910 $ WRITE SYS$OUTPUT " VAXC : To Compile With VAX C."
911 $ WRITE SYS$OUTPUT " DECC : To Compile With DEC C."
912 $ WRITE SYS$OUTPUT " GNUC : To Compile With GNU C."
913 $ WRITE SYS$OUTPUT ""
919 $! End The Valid Arguement Check.
927 $! Time to check the contents of P5, and to make sure we get the correct library.
929 $ IF P5.EQS."SOCKETSHR" .OR. P5.EQS."MULTINET" .OR. P5.EQS."UCX"
932 $! Check to see if SOCKETSHR was chosen
934 $ IF P5.EQS."SOCKETSHR"
937 $! Set the library to use SOCKETSHR
939 $ TCPIP_LIB = "[-.VMS]SOCKETSHR_SHR.OPT/OPT"
943 $ WRITE SYS$OUTPUT "Using SOCKETSHR for TCP/IP"
945 $! Done with SOCKETSHR
949 $! Check to see if MULTINET was chosen
951 $ IF P5.EQS."MULTINET"
954 $! Set the library to use UCX emulation.
960 $ WRITE SYS$OUTPUT "Using MultiNet via UCX emulation for TCP/IP"
962 $! Done with MULTINET
966 $! Check to see if UCX was chosen
971 $! Set the library to use UCX.
973 $ TCPIP_LIB = "[-.VMS]UCX_SHR_DECC.OPT/OPT"
977 $ WRITE SYS$OUTPUT "Using UCX or an emulation thereof for TCP/IP"
983 $! Set the TCPIP_TYPE symbol
989 $ WRITE SYS$OUTPUT "TCP/IP library spec: ", TCPIP_LIB
991 $! Else The User Entered An Invalid Arguement.
997 $! Tell The User We Don't Know What They Want.
999 $ WRITE SYS$OUTPUT ""
1000 $ WRITE SYS$OUTPUT "The Option ",P5," Is Invalid. The Valid Options Are:"
1001 $ WRITE SYS$OUTPUT ""
1002 $ WRITE SYS$OUTPUT " SOCKETSHR : To link with SOCKETSHR TCP/IP library."
1003 $ WRITE SYS$OUTPUT " UCX : To link with UCX TCP/IP library."
1004 $ WRITE SYS$OUTPUT ""
1011 $! Set the TCPIP_TYPE symbol
1016 $! Done with TCP/IP libraries
1020 $! Special Threads For OpenVMS v7.1 Or Later
1022 $! Written By: Richard Levitte
1023 $! richard@levitte.org
1026 $! Check To See If We Have A Option For P6.
1031 $! Get The Version Of VMS We Are Using.
1034 $ TMP = F$ELEMENT(0,"-",F$EXTRACT(1,4,F$GETSYI("VERSION")))
1035 $ TMP = F$INTEGER(F$ELEMENT(0,".",TMP)+F$ELEMENT(1,".",TMP))
1037 $! Check To See If The VMS Version Is v7.1 Or Later.
1042 $! We Have OpenVMS v7.1 Or Later, So Use The Special Threads.
1044 $ ISSEVEN := ,PTHREAD_USE_D4
1046 $! End The VMS Version Check.
1050 $! End The P6 Check.
1054 $! Time To RETURN...