[Git][NTPsec/ntpsec][master] Address GitLab issue #237: Build fails with OpenSSL 1.1

Eric S. Raymond gitlab at mg.gitlab.com
Tue Jan 31 12:46:08 UTC 2017


Eric S. Raymond pushed to branch master at NTPsec / ntpsec


Commits:
d815d6ee by Eric S. Raymond at 2017-01-31T07:45:04-05:00
Address GitLab issue #237: Build fails with OpenSSL 1.1

- - - - -


1 changed file:

- wafhelpers/check_openssl.py


Changes:

=====================================
wafhelpers/check_openssl.py
=====================================
--- a/wafhelpers/check_openssl.py
+++ b/wafhelpers/check_openssl.py
@@ -13,29 +13,29 @@ int main(void) {
 
 def configure_openssl(ctx):
 
-    OPENSSL_HEADERS = True
-    OPENSSL_LIB = True
-
+    # Some of these headers may not be needed.  Check the build on Debian sid
+    # and other older systems before removing any, though; incautious removals
+    # have caused build breakage.
     headers = (
+        "openssl/asn1_mac.h",
+        "openssl/bn.h",
+        "openssl/err.h",
         "openssl/evp.h",
+        "openssl/pem.h",
         "openssl/rand.h",
         "openssl/objects.h",
+        "openssl/x509v3.h",
+        "openssl/ssl.h",
     )
 
-    for hdr in headers:
-        if not ctx.check_cc(header_name=hdr, comment="<%s> header" % hdr):
-            OPENSSL_HEADERS = False
-
-    if not ctx.check_cc(lib="crypto"):
-        OPENSSL_LIB = False
-
-    if OPENSSL_HEADERS and OPENSSL_LIB:
-        ctx.check_cc(
-            fragment=OPENSSL_FRAG % "\n".join(["#include <%s>" % x
-                                               for x in headers]),
-            execute=True,
-            use="CRYPTO",
-            msg="Checking if OpenSSL works",
-            comment="OpenSSL support"
-        )
+    ctx.check_cc(lib="crypto", mandatory=True)
+    ctx.check_cc(
+        fragment=OPENSSL_FRAG % "\n".join(["#include <%s>" % x
+                                           for x in headers]),
+        execute=True,
+        use="CRYPTO",
+        msg="Checking if OpenSSL works",
+        mandatory=True,
+        comment="OpenSSL support"
+    )
 



View it on GitLab: https://gitlab.com/NTPsec/ntpsec/commit/d815d6ee6a13992644a2a2129630e06ec5f1a5ea
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ntpsec.org/pipermail/vc/attachments/20170131/0f0c308b/attachment.html>


More information about the vc mailing list