2010-02-14 14:40:18 -05:00
|
|
|
$! BUILD_VMS.COM
|
2004-03-15 05:03:05 -05:00
|
|
|
$!
|
|
|
|
$! I've taken the original build_vms.com, supplied by Nico Baggus, if
|
|
|
|
$! memory serves me correctly, and made some modifications.
|
|
|
|
$!
|
2009-12-30 14:37:53 -05:00
|
|
|
$! SSL support is controlled by logical names. If SSL$INCLUDE is
|
|
|
|
$! defined, then it is assumed that HP's SSL product has been installed.
|
|
|
|
$! If OPENSSL is defined, but SSL$INCLUDE is not, then OpenSSL will be
|
|
|
|
$! used. If neither logical name is defined, then SSL support will not
|
|
|
|
$! be compiled/linked in. Command-line options NOHPSSL and NOSSL can be
|
|
|
|
$! specified to override the automatic SSL selection.
|
2004-03-15 05:03:05 -05:00
|
|
|
$!
|
2009-12-30 14:37:53 -05:00
|
|
|
$! Command-line Options:
|
2004-03-15 05:03:05 -05:00
|
|
|
$!
|
2009-12-30 14:37:53 -05:00
|
|
|
$! CLEAN Delete product files for this host architecture. (No
|
|
|
|
$! build done.)
|
|
|
|
$! CLEAN_ALL Delete product files for all host architectures. (No
|
|
|
|
$! build done.)
|
2004-03-15 05:03:05 -05:00
|
|
|
$!
|
2009-12-30 14:37:53 -05:00
|
|
|
$! 64 Compile with 64-bit pointers.
|
2013-07-14 11:37:49 -04:00
|
|
|
$! Note, you must match the pointer size that the OpenSSL
|
|
|
|
$! shared image expects.
|
|
|
|
$! Currently curl is not building properly with 64 bit pointers
|
|
|
|
$! on VMS because it is trying to cast pointers to 32 bit
|
|
|
|
$! integers and some OpenVMS library routines called by curl
|
|
|
|
$! do not yet support 64 bit pointers.
|
2009-12-30 14:37:53 -05:00
|
|
|
$! CCQUAL=x Add "x" to the C compiler qualifiers.
|
2013-07-14 11:37:49 -04:00
|
|
|
$! Default qualifiers are:
|
|
|
|
$! /standard=relaxed
|
|
|
|
$! /names=(as_is, shortened)
|
|
|
|
$! /repository=[.'arch']
|
|
|
|
$! /nested_include_directory=none
|
|
|
|
$! /define=(_LARGEFILE=1,_USE_STD_STAT=1) (non-vax)
|
|
|
|
$! /float=ieee/ieee_mode=denorm_results (non-vax)
|
2013-02-04 16:56:44 -05:00
|
|
|
$! DEBUG Compile debug and nooptimize
|
2013-07-14 11:37:49 -04:00
|
|
|
$! Alpha/IA64 always compiles /debug.
|
|
|
|
$! Always link a debug image.
|
2013-02-04 16:56:44 -05:00
|
|
|
$! NOIEEE Do not use IEEE floating point. (Alpha/I64)
|
2013-07-14 11:37:49 -04:00
|
|
|
$! VAX must always use DFLOAT
|
2013-02-04 16:56:44 -05:00
|
|
|
$! NOLARGE Disable large-file support if large file support available.
|
2013-07-14 11:37:49 -04:00
|
|
|
$! (Non-VAX, VMS >= V7.2.)
|
2013-02-04 16:56:44 -05:00
|
|
|
$! NOLDAP Disable LDAP support if LDAP is available.
|
|
|
|
$! NOKERBEROS Disable Kerberos support if Kerberos is available.
|
2009-12-30 14:37:53 -05:00
|
|
|
$! LIST Create C compiler listings and linker maps.
|
2013-07-14 11:37:49 -04:00
|
|
|
$! /list/show=(expan,includ)/machine
|
2013-02-04 16:56:44 -05:00
|
|
|
$! FULLLIST Full detailed listing.
|
2013-07-14 11:37:49 -04:00
|
|
|
$! /list/show=(all, nomessages)/machine
|
2009-12-30 14:37:53 -05:00
|
|
|
$! NOHPSSL Don't use HP SSL, even if available.
|
2013-07-14 11:37:49 -04:00
|
|
|
$! Note, you must match the pointer size that the OpenSSL
|
|
|
|
$! shared image expects. This procedure will select the
|
|
|
|
$! correct HP OpenSSL image.
|
2009-12-30 14:37:53 -05:00
|
|
|
$! NOSSL Don't use any SSL, even if available.
|
|
|
|
$! OSSLOLB Use OpenSSL object libraries (.OLB), even if shared
|
|
|
|
$! images (.EXE) are available.
|
2013-07-14 11:37:49 -04:00
|
|
|
$! NOZLIB Don't use GNV$ZLIB shared image even if available.
|
|
|
|
$! REALCLEAN Delete product files for all host architectures. (No
|
|
|
|
$! build done.) Alias for CLEAN_ALL
|
2004-03-15 05:03:05 -05:00
|
|
|
$!
|
2009-12-30 14:37:53 -05:00
|
|
|
$! DCL Symbols:
|
|
|
|
$!
|
|
|
|
$! CURL_CCDEFS="c_macro_1=value1 [, c_macro_2=value2 [...]]"
|
|
|
|
$! Compile with these additional C macros defined.
|
2004-03-15 05:03:05 -05:00
|
|
|
$!
|
|
|
|
$! Revisions:
|
|
|
|
$!
|
2005-12-29 19:07:25 -05:00
|
|
|
$! 2-DEC-2003, MSK, the "original" version.
|
2004-03-15 05:03:05 -05:00
|
|
|
$! It works for me. Your mileage may vary.
|
|
|
|
$! 13-JAN-2004, MSK, moved this procedure to the [.packages.vms] directory
|
2009-10-27 12:56:20 -04:00
|
|
|
$! and updated it to do hardware dependent builds.
|
2004-03-15 05:03:05 -05:00
|
|
|
$! 29-JAN-2004, MSK, moved logical defines into defines.com
|
|
|
|
$! 6-FEB-2004, MSK, put in various SSL support bits
|
|
|
|
$! 9-MAR-2004, MSK, the config-vms.h* files are now copied to the lib and
|
2009-07-14 09:25:14 -04:00
|
|
|
$! src directories as curl_config.h.
|
2010-02-14 14:40:18 -05:00
|
|
|
$! 15-MAR-2004, MSK, All of the curlmsg*.* files have also been moved to
|
|
|
|
$! this build directory. They will be copied to the src
|
|
|
|
$! directory before build. The .msg file will be compiled
|
|
|
|
$! to get the .obj for messages, but the .h and .sdl files
|
|
|
|
$! are not automatically created since they partly rely on
|
2004-03-21 17:38:01 -05:00
|
|
|
$! the freeware SDL tool.
|
2005-02-09 20:54:11 -05:00
|
|
|
$! 8-FEB-2005, MSK, merged the two config-vms.h* files into one that uses
|
|
|
|
$! USE_SSLEAY to define if the target has SSL support built
|
|
|
|
$! in. Changed the cc/define parameter accordingly.
|
2005-02-11 17:42:16 -05:00
|
|
|
$! 11-FEB-2005, MSK, If [--.LIB]AMIGAOS.C and NWLIB.C are there, rename them
|
2005-04-08 01:06:31 -04:00
|
|
|
$! 23-MAR-2005, MSK, relocated cc_qual define so that DEBUG option would work
|
2007-04-24 23:00:10 -04:00
|
|
|
$! 25-APR-2007, STL, allow compilation in 64-bit mode.
|
2009-12-30 14:37:53 -05:00
|
|
|
$! 13-DEC-2009. SMS, Changed to skip unwanted source files without
|
|
|
|
$! renaming the original files.
|
|
|
|
$! Eliminated needless, persistent logical names.
|
|
|
|
$! Added CURL_CCDEFS DCL symbol for user-specified C
|
|
|
|
$! macro definitions.
|
|
|
|
$! Added CLEAN and CLEAN_ALL options.
|
|
|
|
$! Added CCQUAL option for user-specified C compiler
|
|
|
|
$! qualifiers.
|
|
|
|
$! Added IEEE option for IEEE floating point (Alpha).
|
|
|
|
$! Added LARGE option for large-file support.
|
|
|
|
$! Added OSSLOLB option, and support for OpenSSL
|
|
|
|
$! shared images.
|
|
|
|
$! Changed to put listing and map files into lisdir:.
|
|
|
|
$! Changed to avoid case confusion on ODS5 disks.
|
|
|
|
$! Added more default dev:[dir] save+restore.
|
|
|
|
$! Moved remaining "defines.com" code (back) into
|
|
|
|
$! here, eliminating the hard-coded OpenSSL nonsense.
|
2013-02-04 16:56:44 -05:00
|
|
|
$! Changed to use F$GETSYI("ARCH_NAME") (or
|
2009-12-30 14:37:53 -05:00
|
|
|
$! equivalent) to name architecture-specific product
|
|
|
|
$! file destination directory, and to create the
|
|
|
|
$! directory if needed (obviating inclusion of these
|
|
|
|
$! directories and dummy files in the distribution
|
|
|
|
$! kit).
|
|
|
|
$! Changed the "compile" subroutine to break the CC
|
|
|
|
$! command across multiple lines to avoid DCL
|
|
|
|
$! line-too-long problems.
|
|
|
|
$! Changed "vo_c" messages to show the CC qualifiers
|
|
|
|
$! once, not with every compile command.
|
2013-07-14 11:37:49 -04:00
|
|
|
$! 01-Jan-2013 J. Malmberg
|
|
|
|
$! VMS build procedures need to be able to work with
|
|
|
|
$! the default set to a search list, with created or
|
|
|
|
$! modified files only in the first member of the search
|
|
|
|
$! list.
|
|
|
|
$! Whitespace change to be more compatible with current
|
|
|
|
$! practices.
|
|
|
|
$! One pass option parsing instead of loop.
|
|
|
|
$! GNV ZLIB shared image support.
|
|
|
|
$! KERBEROS support where available.
|
|
|
|
$! LDAP default to on where available
|
|
|
|
$! LARGEFILE default to on where available
|
|
|
|
$! IEEE float default to on where available.
|
|
|
|
$! Generate the curl_config.h file from system inspection.
|
|
|
|
$! Linker finds ldap with out option file.
|
2013-03-12 23:58:51 -04:00
|
|
|
$! 13-Mar-2013, Tom Grace
|
|
|
|
$! Added missing slash in cc_full_list.
|
|
|
|
$! Removed unwanted extra quotes inside symbol tool_main
|
|
|
|
$! for non-VAX architectures that triggered link failure.
|
|
|
|
$! Replaced curl_sys_inc with sys_inc.
|
2013-03-20 15:36:20 -04:00
|
|
|
$! 19-Mar-2013, John Malmberg
|
|
|
|
$! symbol tool_main needs to be quoted when parse style is
|
|
|
|
$! set to exended in versions of VMS greater than 7.3-1.
|
|
|
|
$! Remove curlbuild.h generation as it should be pre-built
|
|
|
|
$! in the curl release or daily tarball.
|
2013-07-14 11:37:49 -04:00
|
|
|
$! 12-Jul-2013, John Malmberg
|
|
|
|
$! Adjust to find and use ZLIB from the Jean-Francois
|
|
|
|
$! Pieronne shared image and newer GNV ZLIB kit that
|
|
|
|
$! is upward compatible with Jean-Francois's kit.
|
|
|
|
$! Remove tabs from file.
|
|
|
|
$! Fixed DCL formatting as follows:
|
|
|
|
$! * Labels have no space after leading $.
|
|
|
|
$! * 1 space after $ for first level.
|
|
|
|
$! * 3 spaces after $ for second level. Line start + 4.
|
|
|
|
$! * 7 spaces after $ for third level. Line start + 8.
|
|
|
|
$! * Each level after that indents 4 characters.
|
|
|
|
$! * then/else/endif same indentation as if statement.
|
2013-02-04 16:56:44 -05:00
|
|
|
$!
|
|
|
|
$!===========================================================================
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
2004-03-15 05:03:05 -05:00
|
|
|
$!
|
2009-12-30 14:37:53 -05:00
|
|
|
$! Save the original default dev:[dir], and arrange for its restoration
|
|
|
|
$! at exit.
|
2013-02-04 16:56:44 -05:00
|
|
|
$!------------------------------------------------------------------------
|
2009-12-30 14:37:53 -05:00
|
|
|
$ curl = ""
|
2013-02-04 16:56:44 -05:00
|
|
|
$ orig_def = f$environment("DEFAULT")
|
2009-12-30 14:37:53 -05:00
|
|
|
$ on error then goto Common_Exit
|
2004-03-15 05:03:05 -05:00
|
|
|
$ on control_y then goto Common_Exit
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
2010-02-14 14:40:18 -05:00
|
|
|
$ ctrl_y = 1556
|
2013-02-04 16:56:44 -05:00
|
|
|
$ proc = f$environment("PROCEDURE")
|
|
|
|
$ proc_fid = f$file_attributes(proc, "FID")
|
|
|
|
$ proc_dev = f$parse(proc, , , "DEVICE")
|
|
|
|
$ proc_dir = f$parse(proc, , , "DIRECTORY")
|
|
|
|
$ proc_name = f$parse(proc, , , "NAME")
|
|
|
|
$ proc_type = f$parse(proc, , , "TYPE")
|
|
|
|
$ proc_dev_dir = proc_dev + proc_dir
|
|
|
|
$!
|
|
|
|
$! Have to manually parse the device for a search list.
|
|
|
|
$! Can not use the f$parse() as it will return the first name
|
|
|
|
$! in the search list.
|
|
|
|
$!
|
|
|
|
$ orig_def_dev = f$element(0, ":", orig_def) + ":"
|
|
|
|
$ if orig_def_dev .eqs. "::" then orig_def_dev = "sys$disk:"
|
|
|
|
$ test_proc = orig_def_dev + proc_dir + proc_name + proc_type
|
|
|
|
$!
|
|
|
|
$! If we can find this file using the default directory
|
|
|
|
$! then we know that we should use the original device from the
|
|
|
|
$! default directory which could be a search list.
|
|
|
|
$!
|
|
|
|
$ test_proc_fid = f$file_attributes(test_proc, "FID")
|
|
|
|
$!
|
|
|
|
$ if (test_proc_fid .eq. proc_fid)
|
|
|
|
$ then
|
|
|
|
$ proc_dev_dir = orig_def_dev + proc_dir
|
|
|
|
$ endif
|
|
|
|
$!
|
2004-03-15 05:03:05 -05:00
|
|
|
$!
|
|
|
|
$! Verbose output message stuff. Define symbol to "write sys$output" or "!".
|
|
|
|
$! vo_c - verbose output for compile
|
|
|
|
$! vo_l - link
|
|
|
|
$! vo_o - object check
|
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$ vo_c := "write sys$output"
|
|
|
|
$ vo_l := "write sys$output"
|
|
|
|
$ vo_o := "!"
|
2004-03-15 05:03:05 -05:00
|
|
|
$!
|
2009-12-30 14:37:53 -05:00
|
|
|
$! Determine the main distribution directory ("[--]") in an
|
|
|
|
$! ODS5-tolerant (case-insensitive) way. (We do assume that the only
|
2013-02-04 16:56:44 -05:00
|
|
|
$! "]" or ">" is the one at the end.)
|
|
|
|
$!
|
|
|
|
$! Some non-US VMS installations report ">" for the directory delimiter
|
|
|
|
$! so do not assume that it is "]".
|
|
|
|
$!
|
|
|
|
$ orig_def_len = f$length(orig_def)
|
|
|
|
$ delim = f$extract(orig_def_len - 1, 1, orig_def)
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
|
|
|
$ set default 'proc_dev_dir'
|
|
|
|
$ set default [--]
|
2013-02-04 16:56:44 -05:00
|
|
|
$ base_dev_dir = f$environment("default")
|
|
|
|
$ top_dev_dir = base_dev_dir - delim
|
|
|
|
$!
|
|
|
|
$!
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
|
|
|
$! Define the architecture-specific product file destination directory
|
|
|
|
$! name(s).
|
|
|
|
$!
|
2013-03-20 15:36:20 -04:00
|
|
|
$ parse_style = "TRADITIONAL"
|
2013-02-04 16:56:44 -05:00
|
|
|
$ if (f$getsyi("HW_MODEL") .lt. 1024)
|
2009-12-30 14:37:53 -05:00
|
|
|
$ then
|
|
|
|
$ arch_name = "VAX"
|
|
|
|
$ else
|
|
|
|
$ arch_name = ""
|
2013-02-04 16:56:44 -05:00
|
|
|
$ arch_name = arch_name + f$edit(f$getsyi("ARCH_NAME"), "UPCASE")
|
2009-12-30 14:37:53 -05:00
|
|
|
$ if (arch_name .eqs. "") then arch_name = "UNK"
|
2013-03-20 15:36:20 -04:00
|
|
|
$!
|
|
|
|
$! Extended parsing option starts with VMS 7.3-1.
|
|
|
|
$! There is no 7.4, so that simplifies the parse a bit.
|
|
|
|
$!
|
|
|
|
$ node_swvers = f$getsyi("node_swvers")
|
|
|
|
$ version_patch = f$extract(1, f$length(node_swvers), node_swvers)
|
|
|
|
$ maj_ver = f$element(0, ".", version_patch)
|
|
|
|
$ min_ver_patch = f$element(1, ".", version_patch)
|
|
|
|
$ min_ver = f$element(0, "-", min_ver_patch)
|
|
|
|
$ patch = f$element(1, "-", min_ver_patch)
|
|
|
|
$ if patch .eqs. "-" then patch = ""
|
|
|
|
$ parse_x = 0
|
|
|
|
$ if maj_ver .ges. "8"
|
|
|
|
$ then
|
|
|
|
$ parse_x = 1
|
|
|
|
$ else
|
|
|
|
$ if maj_ver .eqs. "7" .and. min_ver .ges. "3" .and. patch .nes. ""
|
|
|
|
$ then
|
|
|
|
$ parse_x = 1
|
|
|
|
$ endif
|
|
|
|
$ endif
|
|
|
|
$ if parse_x
|
|
|
|
$ then
|
|
|
|
$ parse_style = f$getjpi("", "parse_style_perm")
|
|
|
|
$ endif
|
2004-03-15 05:03:05 -05:00
|
|
|
$ endif
|
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$ exedir = proc_dev_dir - delim + ".''arch_name'" + delim
|
2009-12-30 14:37:53 -05:00
|
|
|
$ lisdir = exedir
|
|
|
|
$ objdir = exedir
|
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$! When building on a search list, need to do a create to make sure that
|
|
|
|
$! the output directory exists, since the clean procedure tries to delete
|
|
|
|
$! it.
|
|
|
|
$ create/dir 'exedir'/prot=o:rwed
|
|
|
|
$!
|
2009-12-30 14:37:53 -05:00
|
|
|
$! Interpret command-line options.
|
|
|
|
$!
|
|
|
|
$ hpssl = 0
|
2013-02-04 16:56:44 -05:00
|
|
|
$ ldap = 1
|
2010-02-11 02:24:29 -05:00
|
|
|
$ list = 0
|
2013-02-04 16:56:44 -05:00
|
|
|
$ full_list = 0
|
2009-12-30 14:37:53 -05:00
|
|
|
$ nohpssl = 0
|
|
|
|
$ nossl = 0
|
2004-03-15 05:03:05 -05:00
|
|
|
$ openssl = 0
|
2009-12-30 14:37:53 -05:00
|
|
|
$ osslolb = 0
|
2013-02-04 16:56:44 -05:00
|
|
|
$ nozlib = 0
|
|
|
|
$ nokerberos = 0
|
|
|
|
$ cc_names = "/names=(shortened, as_is)/repository='exedir'
|
|
|
|
$ cc_defs = "HAVE_CONFIG_H=1"
|
|
|
|
$ cc_list = "/list='objdir'/show=(expan, includ)/machine
|
2013-03-12 23:58:51 -04:00
|
|
|
$ cc_full_list = "/list='objdir'/show=(all, nomessages)/machine
|
2013-02-04 16:56:44 -05:00
|
|
|
$ link_qual = ""
|
|
|
|
$ if arch_name .eqs. "VAX"
|
|
|
|
$ then
|
|
|
|
$ cc_debug = "/nodebug/optimize"
|
|
|
|
$ !cc_defs = cc_defs + ""
|
|
|
|
$ cc_float = ""
|
|
|
|
$ cc_large = ""
|
|
|
|
$ else
|
|
|
|
$ cc_debug = "/debug/optimize"
|
|
|
|
$ cc_defs = cc_defs + ",_USE_STD_STAT"
|
|
|
|
$ cc_float = "/float=ieee/ieee_mode=denorm_results"
|
|
|
|
$ cc_large = ",_LARGEFILE"
|
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$ cc_qual1 = ""
|
|
|
|
$ cc_qual2 = ""
|
2013-02-04 16:56:44 -05:00
|
|
|
$ if (f$type(CURL_CCDEFS) .nes. "")
|
2009-12-30 14:37:53 -05:00
|
|
|
$ then
|
2013-02-04 16:56:44 -05:00
|
|
|
$ CURL_CCDEFS = f$edit(CURL_CCDEFS, "TRIM")
|
|
|
|
$ cc_defs = cc_defs + ", " + CURL_CCDEFS
|
2009-12-30 14:37:53 -05:00
|
|
|
$ endif
|
2010-02-11 02:24:29 -05:00
|
|
|
$ msg_qual = "/object = ''objdir'"
|
2009-12-30 14:37:53 -05:00
|
|
|
$ ssl_opt = ""
|
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$! Allow arguments to be grouped together with comma or separated by spaces
|
|
|
|
$! Do no know if we will need more than 8.
|
|
|
|
$ args = "," + p1 + "," + p2 + "," + p3 + "," + p4 + ","
|
|
|
|
$ args = args + p5 + "," + p6 + "," + p7 + "," + p8 + ","
|
|
|
|
$!
|
|
|
|
$! Provide lower case version to simplify parsing.
|
|
|
|
$ args_lower = f$edit(args, "LOWERCASE,COLLAPSE")
|
|
|
|
$!
|
|
|
|
$ args_len = f$length(args)
|
|
|
|
$ args_lower_len = f$length(args_lower)
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
2013-07-14 11:37:49 -04:00
|
|
|
$ clean = 0
|
2013-02-04 16:56:44 -05:00
|
|
|
$ if f$locate(",clean,", args_lower) .lt. args_lower_len
|
2013-07-14 11:37:49 -04:00
|
|
|
$ then
|
|
|
|
$ clean = 1
|
|
|
|
$ endif
|
|
|
|
$ clean_all = 0
|
|
|
|
$ if f$locate(",clean_all,", args_lower) .lt. args_lower_len
|
|
|
|
$ then
|
|
|
|
$ clean = 1
|
|
|
|
$ clean_all = 1
|
|
|
|
$ endif
|
|
|
|
$ if f$locate(",realclean,", args_lower) .lt. args_lower_len
|
|
|
|
$ then
|
|
|
|
$ clean = 1
|
|
|
|
$ clean_all = 1
|
|
|
|
$ endif
|
|
|
|
$!
|
|
|
|
$ if clean .ne. 0
|
|
|
|
$ then
|
|
|
|
$ prods = "''exedir'*.*;*"
|
2013-02-04 16:56:44 -05:00
|
|
|
$ if (f$search(prods) .nes. "") then delete /log 'prods'
|
|
|
|
$ prods = proc_dev_dir + arch_name + ".DIR;1"
|
|
|
|
$ if (f$search(prods) .nes. "") then set prot=o:rwed 'prods'
|
|
|
|
$ if (f$search(prods) .nes. "") then delete /log 'prods'
|
|
|
|
$ file = "[]config_vms.h"
|
|
|
|
$ if f$search(file) .nes. "" then delete/log 'file';*
|
2013-07-14 11:37:49 -04:00
|
|
|
$ file = "[]config.h"
|
|
|
|
$ if f$search(file) .nes. "" then delete/log 'file';*
|
2013-08-08 07:11:29 -04:00
|
|
|
$ file = "[]curl-config."
|
|
|
|
$ if f$search(file) .nes. "" then delete/log 'file';*
|
|
|
|
$ file = "[]libcurl.pc"
|
|
|
|
$ if f$search(file) .nes. "" then delete/log 'file';*
|
2013-07-14 11:37:49 -04:00
|
|
|
$ file = "[.lib.cxx_repository]cxx$demangler_db."
|
|
|
|
$ if f$search(file) .nes. "" then delete/log 'file';*
|
|
|
|
$ file = "[.src.cxx_repository]cxx$demangler_db."
|
|
|
|
$ if f$search(file) .nes. "" then delete/log 'file';*
|
2013-02-04 16:56:44 -05:00
|
|
|
$ file = "[.lib]config_vms.h"
|
|
|
|
$ if f$search(file) .nes. "" then delete/log 'file';*
|
2013-08-08 07:11:29 -04:00
|
|
|
$ file = "[...]curl_crtl_init"
|
|
|
|
$ if f$search("''file'.lis") .nes. "" then delete/log 'file'.lis;*
|
|
|
|
$ if f$search("''file'.obj") .nes. "" then delete/log 'file'.obj;*
|
|
|
|
$ file = "[...]gnv$curlmsg"
|
|
|
|
$ if f$search("''file'.lis") .nes. "" then delete/log 'file'.lis;*
|
|
|
|
$ if f$search("''file'.obj") .nes. "" then delete/log 'file'.obj;*
|
|
|
|
$ if f$search("''file'.exe") .nes. "" then delete/log 'file'.exe;*
|
|
|
|
$ file = "[...]curlmsg"
|
|
|
|
$ if f$search("''file'.lis") .nes. "" then delete/log 'file'.lis;*
|
|
|
|
$ if f$search("''file'.obj") .nes. "" then delete/log 'file'.obj;*
|
|
|
|
$ if f$search("''file'.exe") .nes. "" then delete/log 'file'.exe;*
|
|
|
|
$ file = "[...]report_openssl_version"
|
|
|
|
$ if f$search("''file'.lis") .nes. "" then delete/log 'file'.lis;*
|
|
|
|
$ if f$search("''file'.obj") .nes. "" then delete/log 'file'.obj;*
|
|
|
|
$ if f$search("''file'.exe") .nes. "" then delete/log 'file'.exe;*
|
|
|
|
$ file = "[...]hp_ssl_release_info.txt"
|
|
|
|
$ if f$search(file) .nes. "" then delete/log 'file';*
|
|
|
|
$ file = "[...]gnv_libcurl_xfer.mar_exact"
|
|
|
|
$ if f$search(file) .nes. "" then delete/log 'file';*
|
|
|
|
$ file = "[...]gnv_libcurl_xfer"
|
|
|
|
$ if f$search("''file'.lis") .nes. "" then delete/log 'file'.lis;*
|
|
|
|
$ if f$search("''file'.obj") .nes. "" then delete/log 'file'.obj;*
|
|
|
|
$ if f$search("''file'.opt") .nes. "" then delete/log 'file'.opt;*
|
|
|
|
$ file = "[...]curl-*_original_src.bck"
|
|
|
|
$ if f$search(file) .nes. "" then delete/log 'file';*
|
|
|
|
$ file = "[...]curl-*_vms_src.bck"
|
|
|
|
$ if f$search(file) .nes. "" then delete/log 'file';*
|
|
|
|
$ file = "[...]curl-*.release_notes"
|
|
|
|
$ if f$search(file) .nes. "" then delete/log 'file';*
|
|
|
|
$ file = "[...]*curl*.pcsi$desc"
|
|
|
|
$ if f$search(file) .nes. "" then delete/log 'file';*
|
|
|
|
$ file = "[...]*curl*.pcsi$text"
|
|
|
|
$ if f$search(file) .nes. "" then delete/log 'file';*
|
|
|
|
$!
|
2013-07-14 11:37:49 -04:00
|
|
|
$ if clean_all .eq. 0 then goto Common_Exit
|
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
2013-07-14 11:37:49 -04:00
|
|
|
$!
|
|
|
|
$ if clean_all .ne. 0
|
|
|
|
$ then
|
2013-08-08 07:11:29 -04:00
|
|
|
$ file = "[...]gnv$libcurl"
|
|
|
|
$ if f$search("''file'.exe") .nes. "" then delete/log 'file'.exe;*
|
|
|
|
$ if f$search("''file'.map") .nes. "" then delete/log 'file'.map;*
|
|
|
|
$ if f$search("''file'.dsf") .nes. "" then delete/log 'file'.dsf;*
|
|
|
|
$ file = "[.src]curl"
|
|
|
|
$ if f$search("''file'.exe") .nes. "" then delete/log 'file'.exe;*
|
|
|
|
$ if f$search("''file'.map") .nes. "" then delete/log 'file'.map;*
|
|
|
|
$ if f$search("''file'.dsf") .nes. "" then delete/log 'file'.dsf;*
|
2013-02-04 16:56:44 -05:00
|
|
|
$ prods = proc_dev_dir - delim + ".ALPHA" + delim + "*.*;*"
|
|
|
|
$ if (f$search(prods) .nes. "") then delete /log 'prods'
|
|
|
|
$ prods = proc_dev_dir + "ALPHA" + ".DIR;1"
|
|
|
|
$ if (f$search(prods) .nes. "") then set prot=o:rwed 'prods'
|
|
|
|
$ if (f$search(prods) .nes. "") then delete /log 'prods'
|
|
|
|
$ prods = proc_dev_dir - delim + ".IA64" + delim + "*.*;*"
|
|
|
|
$ if (f$search(prods) .nes. "") then delete /log 'prods'
|
|
|
|
$ prods = proc_dev_dir + "IA64" + ".DIR;1"
|
|
|
|
$ if (f$search(prods) .nes. "") then set prot=o:rwed 'prods'
|
|
|
|
$ if (f$search(prods) .nes. "") then delete /log 'prods'
|
|
|
|
$ prods = proc_dev_dir - delim + ".VAX" + delim + "*.*;*"
|
|
|
|
$ if (f$search(prods) .nes. "") then delete /log 'prods'
|
|
|
|
$ prods = proc_dev_dir + "VAX"+ ".DIR;1"
|
|
|
|
$ if (f$search(prods) .nes. "") then set prot=o:rwed 'prods'
|
|
|
|
$ if (f$search(prods) .nes. "") then delete /log 'prods'
|
2013-08-08 07:11:29 -04:00
|
|
|
$ file = "[...]macro32_exactcase"
|
|
|
|
$ if f$search("''file'.exe") .nes. "" then delete/log 'file'.exe;*
|
|
|
|
$ if f$search("''file'.jnl") .nes. "" then delete/log 'file'.jnl;*
|
2013-07-14 11:37:49 -04:00
|
|
|
$ goto Common_Exit
|
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$ build_64 = 0
|
|
|
|
$ if f$locate(",64,", args_lower) .lt. args_lower_len
|
2013-07-14 11:37:49 -04:00
|
|
|
$ then
|
2013-02-04 16:56:44 -05:00
|
|
|
$ cc_qual1 = cc_qual1 + " /POINTER = 64"
|
|
|
|
$ build_64 = 1
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$ args_loc = f$locate(",ccqual=", args_lower)
|
|
|
|
$ if args_loc .lt. args_lower_len
|
2013-07-14 11:37:49 -04:00
|
|
|
$ then
|
2013-02-04 16:56:44 -05:00
|
|
|
$ arg = f$extract(args_loc + 1, args_lower_len, args_lower)
|
|
|
|
$ arg_val = f$element(0, ",", arg)
|
|
|
|
$ cc_qual2 = f$element(1, "=", arg_val);
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$! On Alpha/IA64 no size penalty for compiling /debug/optimize
|
|
|
|
$! by default.
|
|
|
|
$ if f$locate(",debug,", args_lower) .lt. args_lower_len
|
2013-07-14 11:37:49 -04:00
|
|
|
$ then
|
2013-02-04 16:56:44 -05:00
|
|
|
$ cc_debug = "/debug/nooptimize"
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$! We normally want IEEE float if it is available. Programs that are
|
|
|
|
$! calling libcurl will typically prefer IEEE behavior, unless on the
|
|
|
|
$! VAX where we have no choice.
|
|
|
|
$!
|
|
|
|
$ if f$locate(",noieee,", args_lower) .lt. args_lower_len
|
2013-07-14 11:37:49 -04:00
|
|
|
$ then
|
2013-02-04 16:56:44 -05:00
|
|
|
$ cc_float = ""
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$! Normally we want large file if it is available.
|
|
|
|
$ if f$locate(",nolarge,", args_lower) .lt. args_lower_len
|
2013-07-14 11:37:49 -04:00
|
|
|
$ then
|
2013-02-04 16:56:44 -05:00
|
|
|
$ write sys$output "Handling of large files disabled."
|
|
|
|
$ cc_large = ""
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
2013-02-04 16:56:44 -05:00
|
|
|
$ if cc_large .nes. ""
|
|
|
|
$ then
|
|
|
|
$ cc_defs = cc_defs + cc_large
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$ if f$locate(",noldap,", args_lower) .lt. args_lower_len
|
2013-07-14 11:37:49 -04:00
|
|
|
$ then
|
2013-02-04 16:56:44 -05:00
|
|
|
$ ldap = 0
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$ if f$locate(",list,", args_lower) .lt. args_lower_len
|
2013-07-14 11:37:49 -04:00
|
|
|
$ then
|
|
|
|
$ list = 1
|
2013-02-04 16:56:44 -05:00
|
|
|
$ endif
|
|
|
|
$ if f$locate(",fulllist,", args_lower) .lt. args_lower_len
|
|
|
|
$ then
|
|
|
|
$ list = 1
|
|
|
|
$ full_list = 1
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$ if f$locate(",nohpssl,", args_lower) .lt. args_lower_len
|
2013-07-14 11:37:49 -04:00
|
|
|
$ then
|
|
|
|
$ nohpssl = 1
|
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$ if f$locate(",nossl,", args_lower) .lt. args_lower_len
|
2013-07-14 11:37:49 -04:00
|
|
|
$ then
|
|
|
|
$ nossl = 1
|
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$ if f$locate(",osslolb,", args_lower) .lt. args_lower_len
|
2013-07-14 11:37:49 -04:00
|
|
|
$ then
|
|
|
|
$ osslolb = 1
|
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$ if f$locate(",nozlib,", args_lower) .lt. args_lower_len
|
|
|
|
$ then
|
|
|
|
$ nozlib = 1
|
|
|
|
$ endif
|
|
|
|
$!
|
|
|
|
$ if f$locate(",nokerberos,", args_lower) .lt. args_lower_len
|
|
|
|
$ then
|
|
|
|
$ nokerberos = 1
|
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
|
|
|
$!
|
2010-02-11 02:24:29 -05:00
|
|
|
$! CC /LIST, LINK /MAP, and MESSAGE /LIST are defaults in batch mode,
|
|
|
|
$! so be explicit when they're not desired.
|
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$
|
|
|
|
$ if list .eq. 0
|
|
|
|
$ then
|
|
|
|
$ cc_qual1 = cc_qual1 + "/nolist"
|
|
|
|
$ msg_qual = msg_qual + "/nolist"
|
|
|
|
$ else
|
|
|
|
$ msg_qual = msg_qual + "/list='objdir'"
|
|
|
|
$ if (full_list .ne. 0)
|
2013-07-14 11:37:49 -04:00
|
|
|
$ then
|
|
|
|
$ cc_qual1 = cc_qual1 + cc_full_list
|
2013-02-04 16:56:44 -05:00
|
|
|
$ else
|
2013-07-14 11:37:49 -04:00
|
|
|
$ cc_qual1 = cc_qual1 + cc_list
|
2013-02-04 16:56:44 -05:00
|
|
|
$ endif
|
2010-02-11 02:24:29 -05:00
|
|
|
$ endif
|
2013-02-04 16:56:44 -05:00
|
|
|
$ cc_qual1 = cc_qual1 + cc_names + cc_float + cc_debug
|
2010-02-11 02:24:29 -05:00
|
|
|
$!
|
2009-12-30 14:37:53 -05:00
|
|
|
$! Create product directory, if needed.
|
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$ if (f$search(proc_dev_dir + arch_name + ".DIR;1") .eqs. "")
|
2004-03-15 05:03:05 -05:00
|
|
|
$ then
|
2009-12-30 14:37:53 -05:00
|
|
|
$ create /directory 'exedir'
|
|
|
|
$ endif
|
|
|
|
$!
|
|
|
|
$! Detect available (but not prohibited) SSL software.
|
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$ libsslshr_line = ""
|
|
|
|
$ libcryptoshr_line = ""
|
2009-12-30 14:37:53 -05:00
|
|
|
$ if (.not. nossl)
|
|
|
|
$ then
|
2013-07-14 11:37:49 -04:00
|
|
|
$ if (f$trnlnm("OPENSSL") .nes. "")
|
|
|
|
$ then
|
|
|
|
$! cc_defs = cc_defs + ", USE_SSLEAY=1"
|
|
|
|
$ if ((f$trnlnm("SSL$INCLUDE") .nes. "") .and. (.not. nohpssl))
|
|
|
|
$ then
|
|
|
|
$! Use HP SSL.
|
|
|
|
$ hpssl = 1
|
2013-02-04 16:56:44 -05:00
|
|
|
$!
|
2013-07-14 11:37:49 -04:00
|
|
|
$! Older SSL only has lib*_shr32 images
|
2013-02-04 16:56:44 -05:00
|
|
|
$!-----------------------------------------------
|
2013-07-14 11:37:49 -04:00
|
|
|
$ libsslshr = "sys$share:ssl$libssl_shr"
|
|
|
|
$ if (f$search("''libsslshr'.exe") .eqs. "") .or. (.not. build_64)
|
|
|
|
$ then
|
|
|
|
$ libsslshr = libsslshr + "32"
|
|
|
|
$ endif
|
|
|
|
$ libcryptoshr = "sys$share:ssl$libcrypto_shr"
|
|
|
|
$ if (f$search("''libcryptoshr'.exe") .eqs. "") .or. (.not. build_64)
|
|
|
|
$ then
|
|
|
|
$ libcryptoshr = libcryptoshr + "32"
|
|
|
|
$ endif
|
|
|
|
$ libsslshr_line = "''libsslshr'.exe/share"
|
|
|
|
$ libcryptoshr_line = "''libcryptoshr'.exe/share"
|
2009-12-30 14:37:53 -05:00
|
|
|
$ else
|
2013-07-14 11:37:49 -04:00
|
|
|
$! Use OpenSSL. Assume object libraries, unless shared images
|
|
|
|
$! are found (and not prohibited).
|
|
|
|
$! TODO: We do not know how to automatically choose based on the
|
|
|
|
$! pointer size.
|
|
|
|
$!
|
|
|
|
$ openssl = 1
|
|
|
|
$ libsslshr_line = "ssllib:libssl.olb/lib"
|
|
|
|
$ libcryptoshr_line = "ssllib:libcrypto.olb/lib"
|
|
|
|
$ ssl_opt = ", ssllib:libssl.olb /library" + -
|
|
|
|
", ssllib:libcrypto.olb /library"
|
|
|
|
$ if (osslolb .eq. 0)
|
|
|
|
$ then
|
|
|
|
if ((f$search("ssllib:ssl_libcrypto.exe") .nes. "") .and. -
|
|
|
|
(f$search("ssllib:ssl_libssl.exe") .nes. ""))
|
2009-12-30 14:37:53 -05:00
|
|
|
$ then
|
2013-07-14 11:37:49 -04:00
|
|
|
$! OpenSSL shared images with "SSL_xxx.EXE names.
|
|
|
|
$ openssl = 2
|
|
|
|
$ libsslshr_line = "ssllib:ssl_libssl_shr.exe/share"
|
|
|
|
$ libcryptoshr_line = "ssllib:ssl_libcrypto_shr.exe/share"
|
|
|
|
$ else
|
|
|
|
$ if ((f$search("ssllib:libcrypto.exe") .nes. "") .and. -
|
|
|
|
(f$search("ssllib:libssl.exe") .nes. ""))
|
|
|
|
$ then
|
|
|
|
$! OpenSSL shared images with "xxx.EXE names.
|
|
|
|
$ openssl = 3
|
|
|
|
$ libsslshr_line = "ssllib:libssl_shr.exe/share"
|
|
|
|
$ libcryptoshr_line = "ssllib:libcrypto_shr.exe/share"
|
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$ endif
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
2004-03-15 05:03:05 -05:00
|
|
|
$ endif
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
2004-03-15 05:03:05 -05:00
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
|
|
|
$! LDAP.
|
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$ if f$search("SYS$SHARE:LDAP$SHR.EXE") .eqs. ""
|
|
|
|
$ then
|
|
|
|
$ ldap = 0
|
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$ if (ldap .eq. 0)
|
|
|
|
$ then
|
2013-02-04 16:56:44 -05:00
|
|
|
$! cc_defs = cc_defs + ", CURL_DISABLE_LDAP=1"
|
|
|
|
$ else
|
|
|
|
$ 'vo_c' "%CURL-I-BLDHPLDAP, building with HP LDAP support"
|
|
|
|
$ endif
|
|
|
|
$!
|
|
|
|
$! KERBEROS
|
|
|
|
$ gssrtlshr_line = ""
|
|
|
|
$ try_shr = "sys$share:gss$rtl"
|
|
|
|
$ if f$search("''try_shr'.exe") .eqs. ""
|
|
|
|
$ then
|
|
|
|
$ nokerberos = 1
|
|
|
|
$ endif
|
|
|
|
$ curl_sys_krbinc = ""
|
|
|
|
$ if nokerberos .eq. 0
|
|
|
|
$ then
|
|
|
|
$ 'vo_c' "%CURL-I-BLDHPKERBEROS, building with HP KERBEROS support"
|
|
|
|
$ curl_sys_krbinc = "sys$sysroot:[kerberos.include]"
|
|
|
|
$ gssrtlshr_line = "''try_shr'/share"
|
|
|
|
$ endif
|
|
|
|
$!
|
|
|
|
$!
|
|
|
|
$! LIBZ
|
|
|
|
$ libzshr_line = ""
|
|
|
|
$ try_shr = "gnv$libzshr"
|
2013-07-14 11:37:49 -04:00
|
|
|
$ if build_64
|
|
|
|
$ then
|
|
|
|
$! First look for 64 bit
|
|
|
|
$ if f$search("''try_shr'64") .eqs. ""
|
|
|
|
$ then
|
|
|
|
$! Second look for the J.F. Pieronne 64 bit shared image
|
|
|
|
$ try_shr = "LIBZ_SHR64"
|
|
|
|
$ if f$search(try_shr) .eqs. "" then nozlib = 1
|
|
|
|
$ endif
|
|
|
|
$ else
|
|
|
|
$! First look for 32 bit
|
|
|
|
$ if f$search("''try_shr'32") .eqs. ""
|
|
|
|
$ then
|
|
|
|
$! Second look for old 32 bit image
|
|
|
|
$ if f$search(try_shr) .eqs. ""
|
|
|
|
$ then
|
|
|
|
$! Third look for the J.F. Pieronne 32 bit shared image
|
|
|
|
$ try_shr = "LIBZ_SHR32"
|
|
|
|
$ if f$search(try_shr) .eqs. "" then nozlib = 1
|
|
|
|
$ endif
|
|
|
|
$ endif
|
|
|
|
$ endif
|
2013-02-04 16:56:44 -05:00
|
|
|
$ if f$search(try_shr) .eqs. ""
|
|
|
|
$ then
|
|
|
|
$ nozlib = 1
|
2005-04-08 01:06:31 -04:00
|
|
|
$ endif
|
2013-02-04 16:56:44 -05:00
|
|
|
$ curl_sys_zlibinc = ""
|
|
|
|
$ if nozlib .eq. 0
|
|
|
|
$ then
|
|
|
|
$ libzshr_line = "''try_shr'/share"
|
2013-07-14 11:37:49 -04:00
|
|
|
$ if f$locate("LIBZ", try_shr) .eq. 0
|
|
|
|
$ then
|
|
|
|
$ 'vo_c' "%CURL-I-BLDJFPLIBZ, building with JFP LIBZ support"
|
|
|
|
$ curl_sys_zlibinc = "LIBZ:"
|
|
|
|
$ else
|
|
|
|
$ 'vo_c' "%CURL-I-BLDGNVLIBZ, building with GNV LIBZ support"
|
|
|
|
$ curl_sys_zlibinc = "GNV$ZLIB_INCLUDE:"
|
|
|
|
$ endif
|
2013-02-04 16:56:44 -05:00
|
|
|
$ endif
|
|
|
|
$!
|
2009-12-30 14:37:53 -05:00
|
|
|
$! Form CC qualifiers.
|
|
|
|
$!
|
|
|
|
$ cc_defs = "/define = (''cc_defs')"
|
2013-02-04 16:56:44 -05:00
|
|
|
$ cc_qual2 = cc_qual2 + " /object = ''objdir'"
|
|
|
|
$ cc_qual2 = cc_qual2 + " /include = ([-.lib], [-.src],"
|
|
|
|
$ cc_qual2 = cc_qual2 + " [-.packages.vms], [-.packages.vms.''arch_name'])"
|
|
|
|
$ cc_qual2 = cc_qual2 + "/nested_include_directory=none"
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
|
|
|
$ 'vo_c' "CC opts:", -
|
|
|
|
" ''cc_defs'", -
|
|
|
|
" ''cc_qual1'", -
|
|
|
|
" ''cc_qual2'"
|
|
|
|
$!
|
|
|
|
$! Inform the victim of our plans.
|
|
|
|
$!
|
|
|
|
$ if (hpssl)
|
2004-03-15 05:03:05 -05:00
|
|
|
$ then
|
2009-12-30 14:37:53 -05:00
|
|
|
$ 'vo_c' "%CURL-I-BLDHPSSL, building with HP SSL support"
|
2004-03-15 05:03:05 -05:00
|
|
|
$ else
|
2009-12-30 14:37:53 -05:00
|
|
|
$ if (openssl .ne. 0)
|
|
|
|
$ then
|
|
|
|
$ if (openssl .eq. 1)
|
|
|
|
$ then
|
|
|
|
$ 'vo_c' -
|
|
|
|
"%CURL-I-BLDOSSL_OLB, building with OpenSSL (object library) support"
|
|
|
|
$ else
|
|
|
|
$ 'vo_c' -
|
|
|
|
"%CURL-I-BLDOSSL_EXE, building with OpenSSL (shared image) support"
|
|
|
|
$ endif
|
|
|
|
$ else
|
|
|
|
$ 'vo_c' "%CURL-I-BLDNOSSL, building with NO SSL support"
|
|
|
|
$ endif
|
2004-03-15 05:03:05 -05:00
|
|
|
$ endif
|
|
|
|
$!
|
2009-12-30 14:37:53 -05:00
|
|
|
$! Announce destination and SSL directories.
|
2004-03-15 05:03:05 -05:00
|
|
|
$!
|
2009-12-30 14:37:53 -05:00
|
|
|
$ 'vo_c' " OBJDIR = ''objdir'"
|
|
|
|
$ 'vo_c' " EXEDIR = ''exedir'"
|
2005-02-11 17:42:16 -05:00
|
|
|
$!
|
2009-12-30 14:37:53 -05:00
|
|
|
$ if (openssl .ne. 0)
|
2005-02-11 17:42:16 -05:00
|
|
|
$ then
|
2013-07-14 11:37:49 -04:00
|
|
|
$ ssllib = f$trnlnm("ssllib")
|
|
|
|
$ if (ssllib .eqs. "")
|
|
|
|
$ then
|
|
|
|
$ ssllib = "(undefined)"
|
|
|
|
$ endif
|
|
|
|
$ 'vo_c' " SSLLIB = ''ssllib'"
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$! TODO: Why are we translating the logical name?
|
|
|
|
$! The logical aname used to find the shared image should just be used
|
|
|
|
$! as translating it could result in the wrong location at run time.
|
2013-07-14 11:37:49 -04:00
|
|
|
$ if (openssl .eq. 1)
|
|
|
|
$ then
|
2013-02-04 16:56:44 -05:00
|
|
|
$ ossl_lib1 = f$trnlnm("ssllib")+ "LIBSSL.OLB"
|
|
|
|
$ ossl_lib2 = f$trnlnm("ssllib")+ "LIBCRYPTO.OLB"
|
2009-12-30 14:37:53 -05:00
|
|
|
$ msg = "object libraries"
|
2013-07-14 11:37:49 -04:00
|
|
|
$ else
|
2009-12-30 14:37:53 -05:00
|
|
|
$ if (openssl .eq. 2)
|
|
|
|
$ then
|
2013-07-14 11:37:49 -04:00
|
|
|
$ ossl_lib1 = f$trnlnm("ssllib")+ "SSL_LIBSSL.EXE"
|
|
|
|
$ ossl_lib2 = f$trnlnm("ssllib")+ "SSL_LIBCRYPTO.EXE"
|
2009-12-30 14:37:53 -05:00
|
|
|
$ else
|
2013-07-14 11:37:49 -04:00
|
|
|
$ ossl_lib1 = f$trnlnm("ssllib")+ "LIBSSL.EXE"
|
|
|
|
$ ossl_lib2 = f$trnlnm("ssllib")+ "LIBCRYPTO.EXE"
|
2009-12-30 14:37:53 -05:00
|
|
|
$ endif
|
|
|
|
$ msg = "shared images"
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
|
|
|
$ if ((f$search(ossl_lib1) .eqs. "") .or. -
|
|
|
|
(f$search(ossl_lib2) .eqs. ""))
|
|
|
|
$ then
|
2009-12-30 14:37:53 -05:00
|
|
|
$ write sys$output "Can't find OpenSSL ''msg':"
|
|
|
|
$ write sys$output " ''ossl_lib1'"
|
|
|
|
$ write sys$output " ''ossl_lib2'"
|
|
|
|
$ goto Common_Exit
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
2005-02-11 17:42:16 -05:00
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
|
|
|
$! Define the "curl" (process) logical name for "#include <curl/xxx.h>".
|
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$ curl = f$trnlnm("curl", "LNM$PROCESS")
|
2009-12-30 14:37:53 -05:00
|
|
|
$ if (curl .nes. "")
|
2005-02-11 17:42:16 -05:00
|
|
|
$ then
|
2013-07-14 11:37:49 -04:00
|
|
|
$ write sys$output ""
|
|
|
|
$ write sys$output -
|
2009-12-30 14:37:53 -05:00
|
|
|
"Process logical name ""curl"" is already defined, but this procedure"
|
2013-07-14 11:37:49 -04:00
|
|
|
$ write sys$output -
|
2009-12-30 14:37:53 -05:00
|
|
|
"would override that definition. Use a command like"
|
2013-07-14 11:37:49 -04:00
|
|
|
$ write sys$output -
|
2009-12-30 14:37:53 -05:00
|
|
|
" deassign /process curl"
|
2013-07-14 11:37:49 -04:00
|
|
|
$ write sys$output -
|
2009-12-30 14:37:53 -05:00
|
|
|
"to cancel that logical name definition, and then and re-run this procedure."
|
2013-07-14 11:37:49 -04:00
|
|
|
$ write sys$output ""
|
|
|
|
$ goto Common_Exit
|
2005-02-11 17:42:16 -05:00
|
|
|
$ endif
|
2013-02-04 16:56:44 -05:00
|
|
|
$ curl_logical = top_dev_dir + ".include.curl" + delim
|
|
|
|
$ curl_sys_inc2 = curl_logical
|
|
|
|
$ curl_sys_inc1 = top_dev_dir + ".include" + delim
|
|
|
|
$! define curl 'top_dev_dir'.include.curl'delim'
|
|
|
|
$!
|
|
|
|
$! Generate config file into the product directory.
|
|
|
|
$!
|
|
|
|
$! call MoveIfDiff [.lib]config-vms.h 'objdir'curl_config.h
|
|
|
|
$!
|
2013-07-14 11:37:49 -04:00
|
|
|
$ conf_params = ""
|
|
|
|
$ if nossl .ne. 0 then conf_params = conf_params + ",nossl"
|
|
|
|
$ if nohpssl .ne. 0 then conf_params = conf_params + ",nohpssl,"
|
|
|
|
$ if ldap .eq. 0 then conf_params = conf_params + ",noldap,"
|
|
|
|
$ if nozlib .ne. 0 then conf_params = conf_params + ",nozlib,"
|
|
|
|
$ if nokerberos .ne. 0 then conf_params = conf_params + ",nokerberos"
|
|
|
|
$ conf_params = conf_params - ","
|
2013-02-04 16:56:44 -05:00
|
|
|
$!
|
|
|
|
$!
|
2013-07-14 11:37:49 -04:00
|
|
|
$ new_conf = f$search("''objdir'curl_config.h")
|
|
|
|
$ if new_conf .eqs. ""
|
|
|
|
$ then
|
2013-02-04 16:56:44 -05:00
|
|
|
$! set ver
|
|
|
|
$ write sys$output "Generating curl custom config_vms.h"
|
|
|
|
$ @'proc_dev_dir'generate_config_vms_h_curl.com ''conf_params'
|
|
|
|
$!
|
|
|
|
$ write sys$output "Generating curl_config.h"
|
|
|
|
$ conf_in = f$search("[.lib]curl_config*.*in")
|
|
|
|
$ if conf_in .eqs. ""
|
|
|
|
$ then
|
2013-07-14 11:37:49 -04:00
|
|
|
$ write sys$output "Can not find [.lib]curl_config*.*in file!"
|
|
|
|
$ goto common_exit
|
2013-02-04 16:56:44 -05:00
|
|
|
$ endif
|
|
|
|
$ @'proc_dev_dir'config_h.com 'conf_in'
|
|
|
|
$ copy config.h 'objdir'curl_config.h
|
|
|
|
$ delete config.h;
|
|
|
|
$! set nover
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
2013-02-04 16:56:44 -05:00
|
|
|
$!
|
|
|
|
$!
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
2004-03-15 05:03:05 -05:00
|
|
|
$ on control_y then goto Common_Exit
|
|
|
|
$!
|
2009-12-30 14:37:53 -05:00
|
|
|
$ set default 'proc_dev_dir'
|
2013-02-04 16:56:44 -05:00
|
|
|
$ sys_inc = "''curl_sys_inc1', ''curl_sys_inc2', ''curl_logical'"
|
|
|
|
$ if curl_sys_krbinc .nes. ""
|
|
|
|
$ then
|
|
|
|
$ sys_inc = sys_inc + ",''curl_sys_krbinc'"
|
|
|
|
$ endif
|
|
|
|
$ if curl_sys_zlibinc .nes. ""
|
|
|
|
$ then
|
2013-03-12 23:58:51 -04:00
|
|
|
$ sys_inc = sys_inc + ",''curl_sys_zlibinc'"
|
2013-02-04 16:56:44 -05:00
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$ call build "[--.lib]" "*.c" "''objdir'CURLLIB.OLB" "amigaos, nwlib, nwos"
|
2004-03-21 17:38:01 -05:00
|
|
|
$ if ($status .eq. ctrl_y) then goto Common_Exit
|
2009-12-30 14:37:53 -05:00
|
|
|
$ call build "[--.src]" "*.c" "''objdir'CURLSRC.OLB"
|
2004-03-21 17:38:01 -05:00
|
|
|
$ if ($status .eq. ctrl_y) then goto Common_Exit
|
2009-12-30 14:37:53 -05:00
|
|
|
$ call build "[]" "*.msg" "''objdir'CURLSRC.OLB"
|
2004-03-21 17:38:01 -05:00
|
|
|
$ if ($status .eq. ctrl_y) then goto Common_Exit
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
|
|
|
$!
|
|
|
|
$ if (openssl .ne. 0)
|
2004-03-15 05:03:05 -05:00
|
|
|
$ then
|
2013-07-14 11:37:49 -04:00
|
|
|
$ if (openssl .eq. 1)
|
|
|
|
$ then
|
2009-12-30 14:37:53 -05:00
|
|
|
$ 'vo_l' "%CURL-I-LINK_OSSL, linking with OpenSSL (object library)"
|
2013-07-14 11:37:49 -04:00
|
|
|
$ else
|
2009-12-30 14:37:53 -05:00
|
|
|
$ 'vo_l' "%CURL-I-LINK_HPSSL, linking with OpenSSL (shared image)"
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$ else
|
2013-07-14 11:37:49 -04:00
|
|
|
$ if (hpssl)
|
|
|
|
$ then
|
2009-12-30 14:37:53 -05:00
|
|
|
$ 'vo_l' "%CURL-I-LINK_HPSSL, linking with HP SSL"
|
2013-07-14 11:37:49 -04:00
|
|
|
$ else
|
2009-12-30 14:37:53 -05:00
|
|
|
$ 'vo_l' "%CURL-I-LINK_NOSSL, linking with NO SSL support"
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
2004-03-15 05:03:05 -05:00
|
|
|
$ endif
|
|
|
|
$!
|
2013-02-04 16:56:44 -05:00
|
|
|
$!
|
|
|
|
$! GNV helper files for building the test curl binary.
|
|
|
|
$!-----------------------------------------------
|
2013-07-14 11:37:49 -04:00
|
|
|
$ create 'exedir'gnv$curl.opt
|
|
|
|
$ open/append opt 'exedir'gnv$curl.opt
|
|
|
|
$ if libzshr_line .nes. "" then write opt libzshr_line
|
|
|
|
$ if gssrtlshr_line .nes. "" then write opt gssrtlshr_line
|
|
|
|
$ if libcryptoshr_line .nes. "" then write opt libcryptoshr_line
|
|
|
|
$ if libsslshr_line .nes. "" then write opt libsslshr_line
|
|
|
|
$ close opt
|
2013-02-04 16:56:44 -05:00
|
|
|
$!
|
|
|
|
$!
|
|
|
|
$! Create the libcurl
|
|
|
|
$!------------------------------------------------------
|
2013-07-14 11:37:49 -04:00
|
|
|
$ create 'exedir'gnv_libcurl_linker.opt
|
|
|
|
$ open/append opt 'exedir'gnv_libcurl_linker.opt
|
|
|
|
$ if libzshr_line .nes. "" then write opt libzshr_line
|
|
|
|
$ if gssrtlshr_line .nes. "" then write opt gssrtlshr_line
|
|
|
|
$ if libcryptoshr_line .nes. "" then write opt libcryptoshr_line
|
|
|
|
$ if libsslshr_line .nes. "" then write opt libsslshr_line
|
|
|
|
$ close opt
|
2013-02-04 16:56:44 -05:00
|
|
|
$!
|
|
|
|
$!
|
|
|
|
$! If we are not on VAX, then we want the debug symbol table in
|
|
|
|
$! a separate file.
|
|
|
|
$! VAX needs the tool_main unquoted in uppercase,
|
2013-03-20 15:36:20 -04:00
|
|
|
$! Alpha and IA64 need tool_main quoted in exact case when parse style is
|
|
|
|
$! extended.
|
2013-02-04 16:56:44 -05:00
|
|
|
$ link_dsf1 = ""
|
|
|
|
$ link_dsf2 = ""
|
|
|
|
$ tool_main = "tool_main"
|
|
|
|
$ if arch_name .nes. "VAX"
|
|
|
|
$ then
|
2013-03-20 15:36:20 -04:00
|
|
|
$ if parse_style .eqs. "EXTENDED"
|
|
|
|
$ then
|
|
|
|
$ tool_main = """tool_main"""
|
|
|
|
$ endif
|
2013-02-04 16:56:44 -05:00
|
|
|
$ link_dsf1 = "/dsf=" + exedir + "CURL.DSF"
|
|
|
|
$ link_dsf2 = "/dsf=" + exedir + "CURL_DEBUG.DSF"
|
|
|
|
$ endif
|
|
|
|
$ if (list .eq. 0)
|
|
|
|
$ then
|
|
|
|
$ link_map1 = "/nomap"
|
|
|
|
$ link_map2 = "/nomap"
|
|
|
|
$ else
|
|
|
|
$ link_map1 = "/map=" + exedir + "CURL.MAP"
|
|
|
|
$ link_map2 = "/map=" + exedir + "CURL_DEBUG.MAP"
|
|
|
|
$ endif
|
|
|
|
$!
|
|
|
|
$!
|
|
|
|
$! Make a normal image.
|
|
|
|
$ set ver
|
|
|
|
$ link 'link_map1' 'link_dsf1' /executable = 'exedir'CURL.EXE -
|
|
|
|
'objdir'curlsrc.olb /library /include = ('tool_main', curlmsg), -
|
|
|
|
'objdir'curllib.olb /library, -
|
|
|
|
'exedir'gnv$curl.opt/opt
|
|
|
|
$!
|
|
|
|
$! Also make a debug copy.
|
|
|
|
$ link/debug 'link_map2' 'link_dsf2' /executable = 'exedir'CURL_DEBUG.EXE -
|
|
|
|
'objdir'curlsrc.olb /library /include = ('tool_main', curlmsg), -
|
|
|
|
'objdir'curllib.olb /library, -
|
|
|
|
'exedir'gnv$curl.opt/opt
|
2013-07-14 11:37:49 -04:00
|
|
|
$ set nover
|
2009-12-30 14:37:53 -05:00
|
|
|
$!
|
2004-03-15 05:03:05 -05:00
|
|
|
$ goto Common_Exit
|
|
|
|
$!
|
2010-02-14 14:40:18 -05:00
|
|
|
$! Subroutine to build everything with a filetype passed in via P2 in
|
|
|
|
$! the directory passed in via P1 and put it in the object library named
|
2009-12-30 14:37:53 -05:00
|
|
|
$! via P3. Exclude items in P4.
|
2004-03-15 05:03:05 -05:00
|
|
|
$!
|
|
|
|
$build: subroutine
|
2013-07-14 11:37:49 -04:00
|
|
|
$ build_def = f$environment("default")
|
|
|
|
$ on control_y then goto EndLoop ! SS$_CONTROLY
|
|
|
|
$ sts = 1 ! SS$_NORMAL.
|
|
|
|
$! set noon
|
|
|
|
$ set default 'p1'
|
|
|
|
$ search = p2
|
|
|
|
$ reset = f$search("reset")
|
|
|
|
$ if f$search( p3) .eqs. ""
|
|
|
|
$ then
|
2009-12-30 14:37:53 -05:00
|
|
|
$ librarian /create /object 'p3'
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
|
|
|
$ reject_list__ = "," + f$edit(p4, "COLLAPSE, UPCASE") + ","
|
|
|
|
$ reject_list___len = f$length(reject_list__)
|
|
|
|
$ reset = f$search( "reset", 1)
|
2004-03-15 05:03:05 -05:00
|
|
|
$Loop:
|
2013-07-14 11:37:49 -04:00
|
|
|
$ file = f$search( search, 1)
|
|
|
|
$ if file .eqs. "" then goto EndLoop
|
|
|
|
$! Skip a name if it's in the P4 exclusion list.
|
|
|
|
$ if (p4 .nes. "")
|
|
|
|
$ then
|
|
|
|
$ name__ = "," + -
|
2013-02-04 16:56:44 -05:00
|
|
|
f$edit(f$parse(file, , , "NAME", "SYNTAX_ONLY"), "UPCASE") + -
|
2009-12-30 14:37:53 -05:00
|
|
|
","
|
2013-07-14 11:37:49 -04:00
|
|
|
$ if (f$locate(name__, reject_list__) .lt. reject_list___len)
|
|
|
|
$ then
|
|
|
|
$ goto Loop
|
2009-12-30 14:37:53 -05:00
|
|
|
$ endif
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
|
|
|
$ objfile = f$parse("''objdir'.OBJ;", file)
|
|
|
|
$ obj = f$search(objfile, 2)
|
|
|
|
$ if (obj .nes. "")
|
|
|
|
$ then
|
|
|
|
$ if (f$cvtime(f$file(file,"rdt")) .gts. f$cvtime(f$file(obj,"rdt")))
|
2009-12-30 14:37:53 -05:00
|
|
|
$ then
|
2013-07-14 11:37:49 -04:00
|
|
|
$ call compile 'file'
|
|
|
|
$ sts = $status
|
|
|
|
$ if .not. sts
|
|
|
|
$ then
|
|
|
|
$ goto EndLoop
|
|
|
|
$ endif
|
|
|
|
$ librarian /object 'p3' 'objfile'
|
2009-12-30 14:37:53 -05:00
|
|
|
$ else
|
2013-07-14 11:37:49 -04:00
|
|
|
$ 'vo_o' "%CURL-I-OBJUTD, ", objfile, " is up to date"
|
2009-12-30 14:37:53 -05:00
|
|
|
$ endif
|
2013-07-14 11:37:49 -04:00
|
|
|
$ else
|
|
|
|
$ 'vo_o' "%CURL-I-OBJDNE, ", file, " does not exist"
|
|
|
|
$ call compile 'file'
|
|
|
|
$ sts = $status
|
|
|
|
$ if .not. sts
|
|
|
|
$ then
|
|
|
|
$ goto EndLoop
|
|
|
|
$ endif
|
|
|
|
$ librarian /object 'p3' 'objfile'
|
|
|
|
$ endif
|
|
|
|
$ goto Loop
|
2004-03-15 05:03:05 -05:00
|
|
|
$EndLoop:
|
2009-12-30 14:37:53 -05:00
|
|
|
$!!! purge
|
2013-07-14 11:37:49 -04:00
|
|
|
$ set default 'build_def'
|
|
|
|
$ exit 'sts'
|
2009-12-30 14:37:53 -05:00
|
|
|
$ endsubroutine ! Build
|
2004-03-15 05:03:05 -05:00
|
|
|
$!
|
2010-02-14 14:40:18 -05:00
|
|
|
$! Based on the file TYPE, do the right compile command.
|
2004-03-15 05:03:05 -05:00
|
|
|
$! Only C and MSG supported.
|
|
|
|
$!
|
|
|
|
$compile: subroutine
|
2013-07-14 11:37:49 -04:00
|
|
|
$ on control_y then return ctrl_y ! SS$_CONTROLY
|
|
|
|
$! set noon
|
|
|
|
$ file = p1
|
|
|
|
$ qual = p2+ p3+ p4+ p5+ p6+ p7+ p8
|
|
|
|
$ typ = f$edit(f$parse(file, , , "TYPE"), "UPCASE") - "."
|
|
|
|
$ if (typ .eqs. "C")
|
|
|
|
$ then
|
2009-12-30 14:37:53 -05:00
|
|
|
$ 'vo_c' "CC (opts) ", file
|
2013-07-14 11:37:49 -04:00
|
|
|
$ define/user curl 'curl_logical'
|
|
|
|
$ if curl_sys_krbinc .nes. "" then define/user gssapi 'curl_sys_krbinc'
|
|
|
|
$ define/user decc$system_include 'sys_inc'
|
2009-12-30 14:37:53 -05:00
|
|
|
$ CC 'cc_defs' -
|
|
|
|
'cc_qual1' -
|
|
|
|
'cc_qual2' -
|
|
|
|
'file'
|
2013-07-14 11:37:49 -04:00
|
|
|
$ else
|
2013-02-04 16:56:44 -05:00
|
|
|
$ cmd_msg = "MESSAGE " + msg_qual
|
2009-12-30 14:37:53 -05:00
|
|
|
$ x = cmd_'typ'
|
2013-02-04 16:56:44 -05:00
|
|
|
$ 'vo_c' x, " ", file
|
2009-12-30 14:37:53 -05:00
|
|
|
$ 'x' 'file'
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
2009-12-30 14:37:53 -05:00
|
|
|
$ ENDSUBROUTINE ! Compile
|
2004-03-15 05:03:05 -05:00
|
|
|
$!
|
2004-03-21 17:38:01 -05:00
|
|
|
$! Do a diff of the file specified in P1 with that in P2. If different
|
|
|
|
$! copy P1 to P2. This also covers if P2 doesn't exist, but not if P2
|
|
|
|
$! is an invalid filespec.
|
|
|
|
$!
|
|
|
|
$MoveIfDiff: subroutine
|
2013-07-14 11:37:49 -04:00
|
|
|
$ set NoOn
|
|
|
|
$ define /user_mode sys$error nl:
|
|
|
|
$ define /user_mode sys$output nl:
|
|
|
|
$ differences 'p1' 'p2'
|
|
|
|
$ status = $status
|
|
|
|
$ if (status .ne. %X006C8009) ! if status is not "no diff"
|
|
|
|
$ then
|
2009-12-30 14:37:53 -05:00
|
|
|
$ copy 'p1' 'p2'
|
|
|
|
$ purge /nolog 'p2'
|
2013-07-14 11:37:49 -04:00
|
|
|
$ endif
|
|
|
|
$ on control_y then return ctrl_y ! SS$_CONTROLY
|
2009-12-30 14:37:53 -05:00
|
|
|
$ ENDSUBROUTINE ! MoveIfDiff
|
2004-03-21 17:38:01 -05:00
|
|
|
$!
|
2004-03-15 05:03:05 -05:00
|
|
|
$Common_Exit:
|
2009-12-30 14:37:53 -05:00
|
|
|
$ set default 'orig_def'
|
|
|
|
$ exit
|