]> git.proxmox.com Git - mirror_edk2.git/commitdiff
CryptoPkg: Upgrade OpenSSL to 1.1.1d
authorShenglei Zhang <shenglei.zhang@intel.com>
Mon, 21 Oct 2019 07:53:42 +0000 (15:53 +0800)
committerJian J Wang <jian.j.wang@intel.com>
Tue, 5 Nov 2019 02:42:07 +0000 (10:42 +0800)
Upgrade openssl from 1.1.1b to 1.1.1d.
Something needs to be noticed is that, there is a bug existing in the
released 1_1_1d version(894da2fb7ed5d314ee5c2fc9fd2d9b8b74111596),
which causes build failure. So we switch the code base to a usable
version, which is 2 commits later than the stable tag.
Now we use the version c3656cc594daac8167721dde7220f0e59ae146fc.
This log is to fix the build failure.
https://bugzilla.tianocore.org/show_bug.cgi?id=2226

Besides, the absense of "DSO_NONE" in dso_conf.h causes build failure
in OvmfPkg. So update process_files.pl to generate information from
"crypto/include/internal/dso_conf.h.in".

shm.h and utsname.h are added to avoid GCC build failure.

Cc: Jian J Wang <jian.j.wang@intel.com>
Cc: Xiaoyu Lu <xiaoyux.lu@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Signed-off-by: Shenglei Zhang <shenglei.zhang@intel.com>
Reviewed-by: Jian J Wang <jian.j.wang@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
Tested-by: Laszlo Ersek <lersek@redhat.com>
CryptoPkg/Library/Include/internal/dso_conf.h
CryptoPkg/Library/Include/sys/shm.h [new file with mode: 0644]
CryptoPkg/Library/Include/sys/utsname.h [new file with mode: 0644]
CryptoPkg/Library/OpensslLib/openssl
CryptoPkg/Library/OpensslLib/process_files.pl

index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..43c891588bc2990438622d69148a353fea31589d 100644 (file)
@@ -0,0 +1,16 @@
+/* WARNING: do not edit! */
+/* Generated from crypto/include/internal/dso_conf.h.in */
+/*
+ * Copyright 2016-2019 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
+ * in the file LICENSE in the source distribution or at
+ * https://www.openssl.org/source/license.html
+ */
+
+#ifndef HEADER_DSO_CONF_H
+# define HEADER_DSO_CONF_H
+# define DSO_NONE
+# define DSO_EXTENSION ".so"
+#endif
diff --git a/CryptoPkg/Library/Include/sys/shm.h b/CryptoPkg/Library/Include/sys/shm.h
new file mode 100644 (file)
index 0000000..dc0b8e8
--- /dev/null
@@ -0,0 +1,9 @@
+/** @file\r
+  Include file to support building the third-party cryptographic library.\r
+\r
+Copyright (c) 2019, Intel Corporation. All rights reserved.<BR>\r
+SPDX-License-Identifier: BSD-2-Clause-Patent\r
+\r
+**/\r
+\r
+#include <CrtLibSupport.h>\r
diff --git a/CryptoPkg/Library/Include/sys/utsname.h b/CryptoPkg/Library/Include/sys/utsname.h
new file mode 100644 (file)
index 0000000..dc0b8e8
--- /dev/null
@@ -0,0 +1,9 @@
+/** @file\r
+  Include file to support building the third-party cryptographic library.\r
+\r
+Copyright (c) 2019, Intel Corporation. All rights reserved.<BR>\r
+SPDX-License-Identifier: BSD-2-Clause-Patent\r
+\r
+**/\r
+\r
+#include <CrtLibSupport.h>\r
index 50eaac9f3337667259de725451f201e784599687..c3656cc594daac8167721dde7220f0e59ae146fc 160000 (submodule)
@@ -1 +1 @@
-Subproject commit 50eaac9f3337667259de725451f201e784599687
+Subproject commit c3656cc594daac8167721dde7220f0e59ae146fc
index 4fe54cd808a5e1987d11ee1743840c8f6b41c312..bbcfa0d0e705b794fcdc3799d501bc4cb317b5b4 100755 (executable)
@@ -2,7 +2,7 @@
 #\r
 # This script runs the OpenSSL Configure script, then processes the\r
 # resulting file list into our local OpensslLib[Crypto].inf and also\r
 #\r
 # This script runs the OpenSSL Configure script, then processes the\r
 # resulting file list into our local OpensslLib[Crypto].inf and also\r
-# takes a copy of opensslconf.h.\r
+# takes copies of opensslconf.h and dso_conf.h.\r
 #\r
 # This only needs to be done once by a developer when updating to a\r
 # new version of OpenSSL (or changing options, etc.). Normal users\r
 #\r
 # This only needs to be done once by a developer when updating to a\r
 # new version of OpenSSL (or changing options, etc.). Normal users\r
@@ -106,6 +106,14 @@ BEGIN {
                 ) == 0 ||\r
                     die "Failed to generate opensslconf.h!\n";\r
 \r
                 ) == 0 ||\r
                     die "Failed to generate opensslconf.h!\n";\r
 \r
+            # Generate dso_conf.h per config data\r
+            system(\r
+                "perl -I. -Mconfigdata util/dofile.pl " .\r
+                "crypto/include/internal/dso_conf.h.in " .\r
+                "> include/internal/dso_conf.h"\r
+                ) == 0 ||\r
+                    die "Failed to generate dso_conf.h!\n";\r
+\r
             chdir($basedir) ||\r
                 die "Cannot change to base directory \"" . $basedir . "\"";\r
 \r
             chdir($basedir) ||\r
                 die "Cannot change to base directory \"" . $basedir . "\"";\r
 \r
@@ -249,12 +257,17 @@ rename( $new_inf_file, $inf_file ) ||
 print "Done!";\r
 \r
 #\r
 print "Done!";\r
 \r
 #\r
-# Copy opensslconf.h generated from OpenSSL Configuration\r
+# Copy opensslconf.h and dso_conf.h generated from OpenSSL Configuration\r
 #\r
 print "\n--> Duplicating opensslconf.h into Include/openssl ... ";\r
 copy($OPENSSL_PATH . "/include/openssl/opensslconf.h",\r
      $OPENSSL_PATH . "/../../Include/openssl/") ||\r
    die "Cannot copy opensslconf.h!";\r
 #\r
 print "\n--> Duplicating opensslconf.h into Include/openssl ... ";\r
 copy($OPENSSL_PATH . "/include/openssl/opensslconf.h",\r
      $OPENSSL_PATH . "/../../Include/openssl/") ||\r
    die "Cannot copy opensslconf.h!";\r
+print "Done!";\r
+print "\n--> Duplicating dso_conf.h into Include/internal ... ";\r
+copy($OPENSSL_PATH . "/include/internal/dso_conf.h",\r
+     $OPENSSL_PATH . "/../../Include/internal/") ||\r
+   die "Cannot copy dso_conf.h!";\r
 print "Done!\n";\r
 \r
 print "\nProcessing Files Done!\n";\r
 print "Done!\n";\r
 \r
 print "\nProcessing Files Done!\n";\r