Move bf_asm_src file information to build.info files
authorRichard Levitte <levitte@openssl.org>
Sun, 16 Jun 2019 19:20:43 +0000 (21:20 +0200)
committerRichard Levitte <levitte@openssl.org>
Mon, 17 Jun 2019 14:08:52 +0000 (16:08 +0200)
Reviewed-by: Matt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/9166)

Configurations/00-base-templates.conf
Configurations/README
Configure
crypto/bf/build.info

index 0c7334ee4d3eeb9936d9f58dff8e95c7dfafe062..b4eb7e9419e1eee79556060468d4df53680affd0 100644 (file)
@@ -14,7 +14,6 @@ my %targets=(
        thread_scheme   => "(unknown)", # Assume we don't know
        thread_defines  => [],
 
-       bf_asm_src      => "bf_enc.c",
        md5_asm_src     => "",
        cast_asm_src    => "c_enc.c",
        rc4_asm_src     => "rc4_enc.c rc4_skey.c",
@@ -163,7 +162,6 @@ my %targets=(
 
     x86_asm => {
        template        => 1,
-       bf_asm_src      => "bf-586.s",
        md5_asm_src     => "md5-586.s",
        cast_asm_src    => "cast-586.s",
        sha1_asm_src    => "sha1-586.s sha256-586.s sha512-586.s",
index 36e71eeddaaa707b3c0b1f2aea9e6656b7455044..e8be7ffd7fb759f9ee42507077d41686cfd42f3a 100644 (file)
@@ -240,9 +240,6 @@ In each table entry, the following keys are significant:
                                                 export vars as
                                                 accessor functions.
 
-        bf_asm_src      => Assembler implementation of core BlowFish
-                           functions.
-                           Defaults to 'bf_enc.c'
         md5_asm_src     => Assembler implementation of core MD5
                            functions.
         sha1_asm_src    => Assembler implementation of core SHA1,
index cbd8ef1dbabae3609640045e2f4cee093faa4e26..68f642ff6241d300209cdb4a3b5c6a6d7128ae5c 100755 (executable)
--- a/Configure
+++ b/Configure
@@ -3366,7 +3366,6 @@ sub print_table_entry
         "loutflag",
         "ex_libs",
         "bn_ops",
-        "bf_asm_src",
         "md5_asm_src",
         "cast_asm_src",
         "sha1_asm_src",
index 29adc8ce5072142f6661394fe2920523be1f75b1..cc06212dfcd9b0a5264f15d0bbb1ae648cc83b4f 100644 (file)
@@ -1,6 +1,17 @@
 LIBS=../../libcrypto
-SOURCE[../../libcrypto]=bf_skey.c bf_ecb.c bf_cfb64.c bf_ofb64.c \
-        {- $target{bf_asm_src} -}
+
+$BFASM=bf_enc.c
+IF[{- !$disabled{asm} -}]
+  $BFASM_x86=bf-586.s
+
+  # Now that we have defined all the arch specific variables, use the
+  # appropriate one
+  IF[$BFASM_{- $target{asm_arch} -}]
+    $BFASM=$BFASM_{- $target{asm_arch} -}
+  ENDIF
+ENDIF
+
+SOURCE[../../libcrypto]=bf_skey.c bf_ecb.c bf_cfb64.c bf_ofb64.c $BFASM
 
 GENERATE[bf-586.s]=asm/bf-586.pl \
         $(PERLASM_SCHEME) $(LIB_CFLAGS) $(LIB_CPPFLAGS) $(PROCESSOR)