Configure - Rename BASE to DEFAULTS and add a few inheritable BASEs
authorRichard Levitte <levitte@openssl.org>
Sat, 27 Feb 2016 10:25:33 +0000 (11:25 +0100)
committerRichard Levitte <levitte@openssl.org>
Wed, 2 Mar 2016 18:15:42 +0000 (19:15 +0100)
These BASE templates are intended to hold values that are common for
all configuration variants for whole families of configurations.

So far, three "families" are identified: Unix, Windows and VMS, mostly
characterised by the build system they currently use.

Reviewed-by: Andy Polyakov <appro@openssl.org>
Configurations/00-base-templates.conf
Configurations/10-main.conf
Configure

index 4251a6c..3424f12 100644 (file)
@@ -1,6 +1,6 @@
 # -*- Mode: perl -*-
 %targets=(
-    BASE => {
+    DEFAULTS => {
        template        => 1,
 
        cflags          => "",
        shared_ldflag   => "",
        shared_rcflag   => "",
        shared_extension        => "",
+
        build_scheme    => "unixmake",
-       build_file      => "Makefile",
+       build_file      => "Makefile",
+    },
+
+    BASE_common => {
+    },
+
+    BASE_unix => {
+        inherit_from    => [ "BASE_common" ],
+        template        => 1,
+
+        build_scheme    => "unixmake",
+        build_file      => "Makefile",
+    },
+
+    BASE_Windows => {
+        inherit_from    => [ "BASE_common" ],
+        template        => 1,
+
+        build_scheme    => [ "mk1mf" ],
+    },
+
+    BASE_VMS => {
+        inherit_from    => [ "BASE_common" ],
+        template        => 1,
+
+        build_file       => "descrip.mms",
+        build_scheme     => [ "unified", "VMS" ],
     },
 
     uplink_common => {
index ecfbc9a..61a9c6c 100644 (file)
@@ -20,6 +20,7 @@
 
 #### VOS Configurations
     "vos-gcc" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "gcc",
         cflags           => "-Wall -DOPENSSL_SYS_VOS -D_POSIX_C_SOURCE=200112L -D_BSD -D_VOS_EXTENDED_NAMES -DB_ENDIAN",
         debug_cflags     => "-O0 -g -DBN_DEBUG -DREF_DEBUG -DCONF_DEBUG",
@@ -33,6 +34,7 @@
 
 #### Solaris configurations
     "solaris-common" => {
+        inherit_from     => [ "BASE_unix" ],
         template         => 1,
         cflags           => "-DFILIO_H",
         ex_libs          => "-lresolv -lsocket -lnsl -ldl",
 #### IRIX 5.x configs
 # -mips2 flag is added by ./config when appropriate.
     "irix-gcc" => {
-        inherit_from     => [ asm("mips32_asm") ],
+        inherit_from     => [ "BASE_unix", asm("mips32_asm") ],
         cc               => "gcc",
         cflags           => "-DB_ENDIAN",
         debug_cflags     => "-g -O0",
         shared_extension => ".so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
     },
     "irix-cc" => {
-        inherit_from     => [ asm("mips32_asm") ],
+        inherit_from     => [ "BASE_unix", asm("mips32_asm") ],
         cc               => "cc",
         cflags           => "-use_readonly_const -DB_ENDIAN",
         debug_cflags     => "-g -O0",
 # Only N32 and N64 ABIs are supported. If you need O32 ABI build, invoke
 # './Configure irix-cc -o32' manually.
     "irix-mips3-gcc" => {
-        inherit_from     => [ asm("mips64_asm") ],
+        inherit_from     => [ "BASE_unix", asm("mips64_asm") ],
         cc               => "gcc",
         cflags           => "-mabi=n32 -DB_ENDIAN -DBN_DIV3W",
         debug_cflags     => "-g -O0",
         multilib         => "32",
     },
     "irix-mips3-cc" => {
-        inherit_from     => [ asm("mips64_asm") ],
+        inherit_from     => [ "BASE_unix", asm("mips64_asm") ],
         cc               => "cc",
         cflags           => "-n32 -mips3 -use_readonly_const -G0 -rdata_shared -DB_ENDIAN -DBN_DIV3W",
         debug_cflags     => "-g -O0",
     },
     # N64 ABI builds.
     "irix64-mips4-gcc" => {
-        inherit_from     => [ asm("mips64_asm") ],
+        inherit_from     => [ "BASE_unix", asm("mips64_asm") ],
         cc               => "gcc",
         cflags           => "-mabi=64 -mips4 -DB_ENDIAN -DBN_DIV3W",
         debug_cflags     => "-g -O0",
         multilib         => "64",
     },
     "irix64-mips4-cc" => {
-        inherit_from     => [ asm("mips64_asm") ],
+        inherit_from     => [ "BASE_unix", asm("mips64_asm") ],
         cc               => "cc",
         cflags           => "-64 -mips4 -use_readonly_const -G0 -rdata_shared -DB_ENDIAN -DBN_DIV3W",
         debug_cflags     => "-g -O0",
 #   provided. 
 #                                      <appro@fy.chalmers.se>
     "hpux-parisc-gcc" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "gcc",
         cflags           => "-DB_ENDIAN -DBN_DIV2W",
         debug_cflags     => "-O0 -g",
         multilib         => "/pa1.1",
     },
     "hpux64-parisc2-gcc" => {
-        inherit_from     => [ asm("parisc20_64_asm") ],
+        inherit_from     => [ "BASE_unix", asm("parisc20_64_asm") ],
         cc               => "gcc",
         cflags           => "-DB_ENDIAN",
         debug_cflags     => "-O0 -g",
     # Chris Ruemmler <ruemmler@cup.hp.com>
     # Kevin Steves <ks@hp.se>
     "hpux-parisc-cc" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "cc",
         cflags           => "+Optrs_strongly_typed -Ae +ESlit -DB_ENDIAN -DBN_DIV2W -DMD32_XARRAY",
         debug_cflags      => "+O0 +d -g",
         multilib         => "/pa1.1",
     },
     "hpux64-parisc2-cc" => {
-        inherit_from     => [ asm("parisc20_64_asm") ],
+        inherit_from     => [ "BASE_unix", asm("parisc20_64_asm") ],
         cc               => "cc",
         cflags           => "+DD64 +Optrs_strongly_typed -Ae +ESlit -DB_ENDIAN -DMD32_XARRAY",
         debug_cflags      => "+O0 +d -g",
 
     # HP/UX IA-64 targets
     "hpux-ia64-cc" => {
-        inherit_from     => [ asm("ia64_asm") ],
+        inherit_from     => [ "BASE_unix", asm("ia64_asm") ],
         cc               => "cc",
         cflags           => "-Ae +DD32 +Olit=all -z -DB_ENDIAN",
         debug_cflags     => "+O0 +d -g",
     # Frank Geurts <frank.geurts@nl.abnamro.com> has patiently assisted
     # with debugging of the following config.
     "hpux64-ia64-cc" => {
-        inherit_from     => [ asm("ia64_asm") ],
+        inherit_from     => [ "BASE_unix", asm("ia64_asm") ],
         cc               => "cc",
         cflags           => "-Ae +DD64 +Olit=all -z -DB_ENDIAN",
         debug_cflags     => "+O0 +d -g",
     },
     # GCC builds...
     "hpux-ia64-gcc" => {
-        inherit_from     => [ asm("ia64_asm") ],
+        inherit_from     => [ "BASE_unix", asm("ia64_asm") ],
         cc               => "gcc",
         cflags           => "-DB_ENDIAN",
         debug_cflags     => "-O0 -g",
         multilib         => "/hpux32",
     },
     "hpux64-ia64-gcc" => {
-        inherit_from     => [ asm("ia64_asm") ],
+        inherit_from     => [ "BASE_unix", asm("ia64_asm") ],
         cc               => "gcc",
         cflags           => "-mlp64 -DB_ENDIAN",
         debug_cflags     => "-O0 -g",
 
 #### HP MPE/iX http://jazz.external.hp.com/src/openssl/
     "MPE/iX-gcc" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "gcc",
         cflags           => "-D_ENDIAN -DBN_DIV2W -O3 -D_POSIX_SOURCE -D_SOCKET_SOURCE -I/SYSLOG/PUB",
         thread_cflag     => "(unknown)",
 
 #### DEC Alpha OSF/1/Tru64 targets.
     "osf1-alpha-gcc" => {
-        inherit_from     => [ asm("alpha_asm") ],
+        inherit_from     => [ "BASE_unix", asm("alpha_asm") ],
         cc               => "gcc",
         cflags           => "-O3",
         thread_cflag     => "(unknown)",
         shared_extension => ".so",
     },
     "osf1-alpha-cc" => {
-        inherit_from     => [ asm("alpha_asm") ],
+        inherit_from     => [ "BASE_unix", asm("alpha_asm") ],
         cc               => "cc",
         cflags           => "-std1 -tune host -O4 -readonly_strings",
         thread_cflag     => "(unknown)",
         shared_extension => ".so",
     },
     "tru64-alpha-cc" => {
-        inherit_from     => [ asm("alpha_asm") ],
+        inherit_from     => [ "BASE_unix", asm("alpha_asm") ],
         cc               => "cc",
         cflags           => "-std1 -tune host -fast -readonly_strings",
         thread_cflag     => "-pthread",
 # *-generic* is endian-neutral target, but ./config is free to
 # throw in -D[BL]_ENDIAN, whichever appropriate...
     "linux-generic32" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "gcc",
         cflags           => "-Wall",
         debug_cflags     => "-O0 -g -DBN_DEBUG -DREF_DEBUG -DCONF_DEBUG",
         bn_ops           => "BN_LLONG",
     },
     "linux-aout" => {
-        inherit_from     => [ asm("x86_asm") ],
+        inherit_from     => [ "BASE_unix", asm("x86_asm") ],
         cc               => "gcc",
         cflags           => "-DL_ENDIAN -Wall",
         debug_cflags     => "-O0 -g",
         bn_ops           => "SIXTY_FOUR_BIT_LONG",
     },
     "linux-c64xplus" => {
+        inherit_from     => [ "BASE_unix" ],
         # TI_CGT_C6000_7.3.x is a requirement
         cc               => "cl6x",
         cflags           => "--linux -ea=.s -eo=.o -mv6400+ -o2 -ox -ms -pden -DOPENSSL_SMALL_FOOTPRINT",
         # expands it as -lc_r, which has to be accompanied by explicit
         # -D_THREAD_SAFE and sometimes -D_REENTRANT. FreeBSD 5.x
         # expands it as -lc_r, which seems to be sufficient?
+        inherit_from     => [ "BASE_unix" ],
         cc               => "cc",
         cflags           => "-Wall",
         debug_cflags     => "-O0 -g",
     },
 
     "bsdi-elf-gcc" => {
-        inherit_from     => [ asm("x86_elf_asm") ],
+        inherit_from     => [ "BASE_unix", asm("x86_elf_asm") ],
         cc               => "gcc",
         cflags           => "-DPERL5 -DL_ENDIAN -fomit-frame-pointer -O3 -Wall",
         thread_cflag     => "(unknown)",
     },
 
     "nextstep" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "cc",
         cflags           => "-O -Wall",
         unistd           => "<libc.h>",
         bn_ops           => "BN_LLONG",
     },
     "nextstep3.3" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "cc",
         cflags           => "-O3 -Wall",
         unistd           => "<libc.h>",
 
 # QNX
     "qnx4" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "cc",
         cflags           => "-DL_ENDIAN -DTERMIO",
         thread_cflag     => "(unknown)",
     },
     "QNX6" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "gcc",
         ex_libs          => "-lsocket",
         dso_scheme       => "dlfcn",
         shared_extension => ".so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
     },
     "QNX6-i386" => {
-        inherit_from     => [ asm("x86_elf_asm") ],
+        inherit_from     => [ "BASE_unix", asm("x86_elf_asm") ],
         cc               => "gcc",
         cflags           => "-DL_ENDIAN -O2 -Wall",
         ex_libs          => "-lsocket",
 #
 # UnixWare 2.0x fails destest with -O.
     "unixware-2.0" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "cc",
         cflags           => "-DFILIO_H -DNO_STRINGS_H",
         thread_cflag     => "-Kthread",
         ex_libs          => "-lsocket -lnsl -lresolv -lx",
     },
     "unixware-2.1" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "cc",
         cflags           => "-O -DFILIO_H",
         thread_cflag     => "-Kthread",
         ex_libs          => "-lsocket -lnsl -lresolv -lx",
     },
     "unixware-7" => {
-        inherit_from     => [ asm("x86_elf_asm") ],
+        inherit_from     => [ "BASE_unix", asm("x86_elf_asm") ],
         cc               => "cc",
         cflags           => "-O -DFILIO_H -Kalloca",
         thread_cflag     => "-Kthread",
         shared_extension => ".so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
     },
     "unixware-7-gcc" => {
-        inherit_from     => [ asm("x86_elf_asm") ],
+        inherit_from     => [ "BASE_unix", asm("x86_elf_asm") ],
         cc               => "gcc",
         cflags           => "-DL_ENDIAN -DFILIO_H -O3 -fomit-frame-pointer -Wall",
         thread_cflag     => "-D_REENTRANT",
     },
 # SCO 5 - Ben Laurie <ben@algroup.co.uk> says the -O breaks the SCO cc.
     "sco5-cc" => {
-        inherit_from     => [ asm("x86_elf_asm") ],
+        inherit_from     => [ "BASE_unix", asm("x86_elf_asm") ],
         cc               => "cc",
         cflags           => "-belf",
         thread_cflag     => "(unknown)",
         shared_extension => ".so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
     },
     "sco5-gcc" => {
-        inherit_from     => [ asm("x86_elf_asm") ],
+        inherit_from     => [ "BASE_unix", asm("x86_elf_asm") ],
         cc               => "gcc",
         cflags           => "-O3 -fomit-frame-pointer",
         thread_cflag     => "(unknown)",
 
 #### IBM's AIX.
     "aix-gcc" => {
-        inherit_from     => [ asm("ppc32_asm") ],
+        inherit_from     => [ "BASE_unix", asm("ppc32_asm") ],
         cc               => "gcc",
         cflags           => "-DB_ENDIAN",
         debug_cflags     => "-O0 -g",
         arflags          => "-X32",
     },
     "aix64-gcc" => {
-        inherit_from     => [ asm("ppc64_asm") ],
+        inherit_from     => [ "BASE_unix", asm("ppc64_asm") ],
         cc               => "gcc",
         cflags           => "-maix64 -DB_ENDIAN",
         debug_cflags     => "-O0 -g",
     # $OBJECT_MODE at build time. $OBJECT_MODE is respected at
     # ./config stage!
     "aix-cc" => {
-        inherit_from     => [ asm("ppc32_asm") ],
+        inherit_from     => [ "BASE_unix", asm("ppc32_asm") ],
         cc               => "cc",
         cflags           => "-q32 -DB_ENDIAN -qmaxmem=16384 -qro -qroconst",
         debug_cflags     => "",
         arflags          => "-X 32",
     },
     "aix64-cc" => {
-        inherit_from     => [ asm("ppc64_asm") ],
+        inherit_from     => [ "BASE_unix", asm("ppc64_asm") ],
         cc               => "cc",
         cflags           => "-q64 -DB_ENDIAN -qmaxmem=16384 -qro -qroconst",
         debug_cflags     => "",
 
 # SIEMENS BS2000/OSD: an EBCDIC-based mainframe
     "BS2000-OSD" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "c89",
         cflags           => "-O -XLLML -XLLMK -XL -DB_ENDIAN -DCHARSET_EBCDIC",
         thread_cflag     => "(unknown)",
 # IBM compiler does not like the -L switch after any object modules.
 #
     "OS390-Unix" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "c89.sh",
         cflags           => "-O -DB_ENDIAN -DCHARSET_EBCDIC -DNO_SYS_PARAM_H  -D_ALL_SOURCE",
         thread_cflag     => "(unknown)",
 # legitimate and false cases, but as we compile on multiple platforms,
 # we rely on other compilers to catch legitimate cases.
     "VC-common" => {
+        inherit_from     => [ "BASE_Windows" ],
         template         => 1,
         cc               => "cl",
         cflags           => "-W3 -wd4090 -Gs0 -GF -Gy -nologo -DOPENSSL_SYS_WIN32 -DWIN32_LEAN_AND_MEAN -DL_ENDIAN -D_CRT_SECURE_NO_DEPRECATE",
         shared_target    => "win-shared", # meaningless except it gives Configure a hint
         dso_scheme       => "win32",
-       build_scheme     => "mk1mf",
     },
     "VC-WIN64I" => {
         inherit_from     => [ "VC-common", asm("ia64_asm") ],
         bn_obj           => sub { my $r=join(" ",@_); $r=~s/bn\-//; $r; },
         rc4_obj          => "",
         perlasm_scheme   => "ias",
-       build_scheme     => [ "mk1mf", "VC-W64" ],
+        build_scheme     => add("VC-W64", { separator => undef }),
     },
     "VC-WIN64A" => {
         inherit_from     => [ "VC-common", asm("x86_64_asm") ],
         bn_ops           => "SIXTY_FOUR_BIT EXPORT_VAR_AS_FN",
         bn_obj           => sub { my $r=join(" ",@_); $r=~s/x86_64\-gcc/bn_asm/; $r; },
         perlasm_scheme   => "auto",
-       build_scheme     => [ "mk1mf", "VC-W64" ],
+        build_scheme     => add("VC-W64", { separator => undef }),
     },
     "VC-WIN32" => {
         # x86 Win32 target defaults to ANSI API, if you want UNICODE,
         sys_id           => "WIN32",
         bn_ops           => "BN_LLONG EXPORT_VAR_AS_FN",
         perlasm_scheme   => "win32n",
-       build_scheme     => [ "mk1mf", "VC-W32" ],
+        build_scheme     => add("VC-W32", { separator => undef }),
     },
     "VC-CE" => {
+        inherit_from     => [ "BASE_Windows" ],
         cc               => "cl",
         sys_id           => "WINCE",
         bn_ops           => "BN_LLONG EXPORT_VAR_AS_FN",
         dso_scheme       => "win32",
-       build_scheme     => [ "mk1mf", "VC-WCE" ],
+        build_scheme     => add("VC-WCE", { separator => undef }),
     },
 
 #### Borland C++ 4.5
     "BC-32" => {
+        inherit_from     => [ "BASE_Windows" ],
         cc               => "bcc32",
         sys_id           => "WIN32",
         bn_ops           => "BN_LLONG EXPORT_VAR_AS_FN",
         dso_scheme       => "win32",
-       build_scheme     => [ "mk1mf", "BC" ],
+        build_scheme     => add("BC", { separator => undef }),
     },
 
 #### MinGW
     "mingw" => {
-        inherit_from     => [ asm("x86_asm"),
+        inherit_from     => [ "BASE_unix", asm("x86_asm"),
                               sub { $disabled{shared} ? () : "x86_uplink" } ],
         cc               => "gcc",
         cflags           => "-DL_ENDIAN -DWIN32_LEAN_AND_MEAN -DUNICODE -D_UNICODE -m32 -Wall",
         # consider its binaries for using with non-mingw64 run-time
         # environment. And as mingw64 is always consistent with itself,
         # Applink is never engaged and can as well be omitted.
-        inherit_from     => [ asm("x86_64_asm") ],
+        inherit_from     => [ "BASE_unix", asm("x86_64_asm") ],
         cc               => "gcc",
         cflags           => "-DL_ENDIAN -DWIN32_LEAN_AND_MEAN -DUNICODE -D_UNICODE -m64 -Wall",
         debug_cflags     => "-g -O0",
 
 #### UEFI
     "UEFI" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "cc",
         cflags           => "-DL_ENDIAN -O",
         sys_id           => "UEFI",
 
 #### UWIN
     "UWIN" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "cc",
         cflags           => "-DTERMIOS -DL_ENDIAN -O -Wall",
         sys_id           => "UWIN",
 
 #### Cygwin
     "Cygwin-x86" => {
-        inherit_from     => [ asm("x86_asm") ],
+        inherit_from     => [ "BASE_unix", asm("x86_asm") ],
         cc               => "gcc",
         cflags           => "-DTERMIOS -DL_ENDIAN -Wall",
         debug_cflags     => "-g -O0",
         shared_extension => ".dll",
     },
     "Cygwin-x86_64" => {
-        inherit_from     => [ asm("x86_64_asm") ],
+        inherit_from     => [ "BASE_unix", asm("x86_64_asm") ],
         cc               => "gcc",
         cflags           => "-DTERMIOS -DL_ENDIAN -Wall",
         debug_cflags     => "-g -O0",
 # the builds can be configured to use BSD sockets instead.
 # netware-clib => legacy CLib c-runtime support
     "netware-clib" => {
+        inherit_from     => [ "BASE_Windows" ],
         cc               => "mwccnlm",
-       build_scheme     => [ "mk1mf", "netware" ],
+        build_scheme     => add("netware", { separator => undef }),
     },
     "netware-clib-bsdsock" => {
+        inherit_from     => [ "BASE_Windows" ],
         cc               => "mwccnlm",
-       build_scheme     => [ "mk1mf", "netware" ],
+        build_scheme     => add("netware", { separator => undef }),
     },
     "netware-clib-gcc" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "i586-netware-gcc",
         cflags           => "-nostdinc -I/ndk/nwsdk/include/nlm -I/ndk/ws295sdk/include -DL_ENDIAN -DNETWARE_CLIB -DOPENSSL_SYS_NETWARE -O2 -Wall",
     },
     "netware-clib-bsdsock-gcc" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "i586-netware-gcc",
         cflags           => "-nostdinc -I/ndk/nwsdk/include/nlm -DNETWARE_BSDSOCK -DNETDB_USE_INTERNET -DL_ENDIAN -DNETWARE_CLIB -DOPENSSL_SYS_NETWARE -O2 -Wall",
     },
     # netware-libc => LibC/NKS support
     "netware-libc" => {
+        inherit_from     => [ "BASE_Windows" ],
         cc               => "mwccnlm",
         bn_ops           => "BN_LLONG",
-       build_scheme     => [ "mk1mf", "netware" ],
+        build_scheme     => add("netware", { separator => undef }),
     },
     "netware-libc-bsdsock" => {
+        inherit_from     => [ "BASE_Windows" ],
         cc               => "mwccnlm",
         bn_ops           => "BN_LLONG",
-       build_scheme     => [ "mk1mf", "netware" ],
+        build_scheme     => add("netware", { separator => undef }),
     },
     "netware-libc-gcc" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "i586-netware-gcc",
         cflags           => "-nostdinc -I/ndk/libc/include -I/ndk/libc/include/winsock -DL_ENDIAN -DNETWARE_LIBC -DOPENSSL_SYS_NETWARE -DTERMIO -O2 -Wall",
         bn_ops           => "BN_LLONG",
     },
     "netware-libc-bsdsock-gcc" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "i586-netware-gcc",
         cflags           => "-nostdinc -I/ndk/libc/include -DNETWARE_BSDSOCK -DL_ENDIAN -DNETWARE_LIBC -DOPENSSL_SYS_NETWARE -DTERMIO -O2 -Wall",
         bn_ops           => "BN_LLONG",
 
 #### Ultrix from Bernhard Simon <simon@zid.tuwien.ac.at>
     "ultrix-cc" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "cc",
         cflags           => "-std1 -O -Olimit 2500 -DL_ENDIAN",
         thread_cflag     => "(unknown)",
     },
     "ultrix-gcc" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "gcc",
         cflags           => "-O3 -DL_ENDIAN",
         thread_cflag     => "(unknown)",
 
 ##### MacOS X (a.k.a. Darwin) setup
     "darwin-common" => {
+        inherit_from     => [ "BASE_unix" ],
         template         => 1,
         cc               => "cc",
         cflags           => "",
 
 ##### GNU Hurd
     "hurd-x86" => {
+        inherit_from     => [ "BASE_unix" ],
         inherit_from     => [ asm("x86_elf_asm") ],
         cc               => "gcc",
         cflags           => "-DL_ENDIAN -O3 -fomit-frame-pointer -Wall",
 
 ##### OS/2 EMX
     "OS2-EMX" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "gcc",
     },
 
 ##### VxWorks for various targets
     "vxworks-ppc60x" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "ccppc",
         cflags           => "-D_REENTRANT -mrtp -mhard-float -mstrict-align -fno-implicit-fp -DPPC32_fp60x -O2 -fstrength-reduce -fno-builtin -fno-strict-aliasing -Wall -DCPU=PPC32 -DTOOL_FAMILY=gnu -DTOOL=gnu -I\$(WIND_BASE)/target/usr/h -I\$(WIND_BASE)/target/usr/h/wrn/coreip",
         sys_id           => "VXWORKS",
         ex_libs          => "-Wl,--defsym,__wrs_rtp_base=0xe0000000 -L \$(WIND_BASE)/target/usr/lib/ppc/PPC32/common",
     },
     "vxworks-ppcgen" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "ccppc",
         cflags           => "-D_REENTRANT -mrtp -msoft-float -mstrict-align -O1 -fno-builtin -fno-strict-aliasing -Wall -DCPU=PPC32 -DTOOL_FAMILY=gnu -DTOOL=gnu -I\$(WIND_BASE)/target/usr/h -I\$(WIND_BASE)/target/usr/h/wrn/coreip",
         sys_id           => "VXWORKS",
         ex_libs          => "-Wl,--defsym,__wrs_rtp_base=0xe0000000 -L \$(WIND_BASE)/target/usr/lib/ppc/PPC32/sfcommon",
     },
     "vxworks-ppc405" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "ccppc",
         cflags           => "-g -msoft-float -mlongcall -DCPU=PPC405 -I\$(WIND_BASE)/target/h",
         sys_id           => "VXWORKS",
         lflags           => "-r",
     },
     "vxworks-ppc750" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "ccppc",
         cflags           => "-ansi -nostdinc -DPPC750 -D_REENTRANT -fvolatile -fno-builtin -fno-for-scope -fsigned-char -Wall -msoft-float -mlongcall -DCPU=PPC604 -I\$(WIND_BASE)/target/h \$(DEBUG_FLAG)",
         sys_id           => "VXWORKS",
         lflags           => "-r",
     },
     "vxworks-ppc750-debug" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "ccppc",
         cflags           => "-ansi -nostdinc -DPPC750 -D_REENTRANT -fvolatile -fno-builtin -fno-for-scope -fsigned-char -Wall -msoft-float -mlongcall -DCPU=PPC604 -I\$(WIND_BASE)/target/h -DBN_DEBUG -DREF_DEBUG -DCONF_DEBUG -DBN_CTX_DEBUG -DPEDANTIC -DDEBUG_SAFESTACK -DDEBUG -g",
         sys_id           => "VXWORKS",
         lflags           => "-r",
     },
     "vxworks-ppc860" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "ccppc",
         cflags           => "-nostdinc -msoft-float -DCPU=PPC860 -DNO_STRINGS_H -I\$(WIND_BASE)/target/h",
         sys_id           => "VXWORKS",
         lflags           => "-r",
     },
     "vxworks-simlinux" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "ccpentium",
         cflags           => "-B\$(WIND_BASE)/host/\$(WIND_HOST_TYPE)/lib/gcc-lib/ -D_VSB_CONFIG_FILE=\"\$(WIND_BASE)/target/lib/h/config/vsbConfig.h\" -DL_ENDIAN -DCPU=SIMLINUX -DTOOL_FAMILY=gnu -DTOOL=gnu -fno-builtin -fno-defer-pop -DNO_STRINGS_H -I\$(WIND_BASE)/target/h -I\$(WIND_BASE)/target/h/wrn/coreip -DOPENSSL_NO_HW_PADLOCK",
         sys_id           => "VXWORKS",
         ranlib           => "ranlibpentium",
     },
     "vxworks-mips" => {
-        inherit_from     => [ asm("mips32_asm") ],
+        inherit_from     => [ "BASE_unix", asm("mips32_asm") ],
         cc               => "ccmips",
         cflags           => "-mrtp -mips2 -O -G 0 -B\$(WIND_BASE)/host/\$(WIND_HOST_TYPE)/lib/gcc-lib/ -D_VSB_CONFIG_FILE=\"\$(WIND_BASE)/target/lib/h/config/vsbConfig.h\" -DCPU=MIPS32 -msoft-float -mno-branch-likely -DTOOL_FAMILY=gnu -DTOOL=gnu -fno-builtin -fno-defer-pop -DNO_STRINGS_H -I\$(WIND_BASE)/target/usr/h -I\$(WIND_BASE)/target/h/wrn/coreip",
         thread_cflag     => "-D_REENTRANT",
 
 #### uClinux
     "uClinux-dist" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "$ENV{'CC'}",
         cflags           => "\$(CFLAGS)",
         thread_cflag     => "-D_REENTRANT",
         ranlib           => "$ENV{'RANLIB'}",
     },
     "uClinux-dist64" => {
+        inherit_from     => [ "BASE_unix" ],
         cc               => "$ENV{'CC'}",
         cflags           => "\$(CFLAGS)",
         thread_cflag     => "-D_REENTRANT",
 
     ##### VMS
     "vms-generic" => {
+        inherit_from     => [ "BASE_VMS" ],
         template         => 1,
         cc               => "CC/DECC",
         cflags           => "/STANDARD=RELAXED/NOLIST/PREFIX=ALL/NAMES=(AS_IS,SHORTENED)",
         shared_target    => "vms-shared",
 
         apps_aux_src     => "vms_decc_init.c",
-        build_file       => "descrip.mms",
-        build_scheme     => [ "unified", "VMS" ],
     },
 
     # VMS on VAX is *unsupported*
index ce8fac7..9226b90 100755 (executable)
--- a/Configure
+++ b/Configure
@@ -136,7 +136,6 @@ my $apitable = {
     "0.9.8" => "0x00908000L",
 };
 
-my $base_target = "BASE";   # The template that all other inherit from
 our %table = ();
 our %config = ();
 
@@ -835,13 +834,11 @@ if ($d) {
     }
 }
 $config{target} = $target;
-delete $table{$base_target}->{template}; # or the next test will fail.
 my %target = resolve_config($target);
 
 &usage if (!%target || $target{template});
 
-# Set up defaults
-my %target = ( %{$table{$base_target}}, %target );
+%target = ( %{$table{DEFAULTS}}, %target );
 
 $target{exe_extension}="";
 $target{exe_extension}=".exe" if ($config{target} eq "DJGPP"
@@ -1047,7 +1044,7 @@ if ($target{sys_id} ne "")
        }
 
 unless ($disabled{asm}) {
-    $target{cpuid_asm_src}=$table{BASE}->{cpuid_asm_src} if ($config{processor} eq "386");
+    $target{cpuid_asm_src}=$table{DEFAULTS}->{cpuid_asm_src} if ($config{processor} eq "386");
     $target{bn_asm_src} =~ s/\w+-gf2m.c// if (defined($disabled{ec2m}));
 
     # bn-586 is the only one implementing bn_*_part_words
@@ -1070,7 +1067,7 @@ unless ($disabled{asm}) {
     if ($target{md5_asm_src}) {
        push @{$config{defines}}, "MD5_ASM";
     }
-    $target{cast_asm_src}=$table{BASE}->{cast_asm_src} unless $disabled{pic}; # CAST assembler is not PIC
+    $target{cast_asm_src}=$table{DEFAULTS}->{cast_asm_src} unless $disabled{pic}; # CAST assembler is not PIC
     if ($target{rmd160_asm_src}) {
        push @{$config{defines}}, "RMD160_ASM";
     }
@@ -1087,7 +1084,7 @@ unless ($disabled{asm}) {
     }
     if ($target{wp_asm_src} =~ /mmx/) {
         if ($config{processor} eq "386") {
-           $target{wp_asm_src}=$table{BASE}->{wp_asm_src};
+           $target{wp_asm_src}=$table{DEFAULTS}->{wp_asm_src};
        } elsif (!$disabled{"whirlpool"}) {
            $config{cflags}.=" -DWHIRLPOOL_ASM";
        }