Make the OPENSSL_CPUID_OBJ define internal.
authorPauli <paul.dale@oracle.com>
Mon, 5 Feb 2018 21:15:53 +0000 (07:15 +1000)
committerPauli <paul.dale@oracle.com>
Wed, 7 Feb 2018 00:08:15 +0000 (10:08 +1000)
Patch by @levitte.

Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com>
(Merged from https://github.com/openssl/openssl/pull/5231)

Configure
include/openssl/opensslconf.h.in

index 22d42fb9d96f421e55a4e8f77565145d45bac60a..a6f5a319694762d4352442719288c0abc3996dd7 100755 (executable)
--- a/Configure
+++ b/Configure
@@ -1292,6 +1292,8 @@ if ($target{sys_id} ne "")
 
 unless ($disabled{asm}) {
     $target{cpuid_asm_src}=$table{DEFAULTS}->{cpuid_asm_src} if ($config{processor} eq "386");
+    push @{$config{defines}}, "OPENSSL_CPUID_OBJ" if ($target{cpuid_asm_src} ne "mem_clr.o");
+
     $target{bn_asm_src} =~ s/\w+-gf2m.c// if (defined($disabled{ec2m}));
 
     # bn-586 is the only one implementing bn_*_part_words
index 2603247df2c9ce491683794cd1644622a8f592c1..16aa82e63184849fe471e8142f04c188d11686b2 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * {- join("\n * ", @autowarntext) -}
  *
- * Copyright 2016 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2016-2018 The OpenSSL Project Authors. All Rights Reserved.
  *
  * Licensed under the OpenSSL license (the "License").  You may not use
  * this file except in compliance with the License.  You can obtain a copy
@@ -119,8 +119,6 @@ extern "C" {
 # define DEPRECATEDIN_0_9_8(f)
 #endif
 
-{- $target{cpuid_obj} ne "mem_clr.o" ? "#define OPENSSL_CPUID_OBJ" : "" -}
-
 /* Generate 80386 code? */
 {- $config{processor} eq "386" ? "#define" : "#undef" -} I386_ONLY