aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKazuki Yamaguchi <k@rhe.jp>2018-05-12 15:42:04 +0900
committerGitHub <noreply@github.com>2018-05-12 15:42:04 +0900
commit02590daf3c981a90859cc77a7e925fb555b0adcb (patch)
tree12530ceab3437d8226ef9feded7daa81ef2faca4
parent8f755f22521ee1f2973f195abd9f8c8534aae5c0 (diff)
parent75de15ddcdab6efe7faf3ca1f6b5c6e5b6ba57cc (diff)
downloadruby-openssl-02590daf3c981a90859cc77a7e925fb555b0adcb.tar.gz
Merge pull request #193 from rhenium/ky/libressl-2.7
extconf.rb: fix build with LibreSSL 2.7.0
-rw-r--r--ext/openssl/extconf.rb5
1 files changed, 4 insertions, 1 deletions
diff --git a/ext/openssl/extconf.rb b/ext/openssl/extconf.rb
index 75da65cd..998d9104 100644
--- a/ext/openssl/extconf.rb
+++ b/ext/openssl/extconf.rb
@@ -157,8 +157,11 @@ OpenSSL.check_func_or_macro("SSL_get_server_tmp_key", "openssl/ssl.h")
have_func("SSL_is_server")
# added in 1.1.0
+if !have_struct_member("SSL", "ctx", "openssl/ssl.h") ||
+ try_static_assert("LIBRESSL_VERSION_NUMBER >= 0x2070000fL", "openssl/opensslv.h")
+ $defs.push("-DHAVE_OPAQUE_OPENSSL")
+end
have_func("CRYPTO_lock") || $defs.push("-DHAVE_OPENSSL_110_THREADING_API")
-have_struct_member("SSL", "ctx", "openssl/ssl.h") || $defs.push("-DHAVE_OPAQUE_OPENSSL")
have_func("BN_GENCB_new")
have_func("BN_GENCB_free")
have_func("BN_GENCB_get_arg")