When OpenSSL is built without deprecated APIs, pkg-config first tries OpenSSL in the staging directory but fails as it cannot find the deprecated SSL_library_init function and ends up finding the system one. Added PKG_BUILD_PARALLEL for faster compilation. Added -Wl,--gc-sections to LDFLAGS to save ~10KB from the resulting ipk. Reworked configure section as some of those options were renamed or removed. Removed EXTRA_* hacks that are no longer necessary. Signed-off-by: Rosen Penev <rosenp@gmail.com>
27 lines
826 B
Diff
27 lines
826 B
Diff
From cff1385b398b59c74c535d6c0cd9deec561101fd Mon Sep 17 00:00:00 2001
|
|
From: Rosen Penev <rosenp@gmail.com>
|
|
Date: Fri, 15 Feb 2019 15:02:34 -0800
|
|
Subject: [PATCH] Fix finding OpenSSL when 1.1 with deprecated APIs disabled
|
|
|
|
SSL_library_init is a deprecated function. OPENSSL_init_ssl is not in 1.0.2.
|
|
SSL_CTX_new is in both.
|
|
---
|
|
configure.ac | 2 +-
|
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
|
|
diff --git a/configure.ac b/configure.ac
|
|
index e8290dfd..8dde6095 100644
|
|
--- a/configure.ac
|
|
+++ b/configure.ac
|
|
@@ -319,7 +319,7 @@ PKG_CHECK_MODULES([OPENSSL], [openssl], [
|
|
CFLAGS="$CFLAGS $OPENSSL_CFLAGS"
|
|
LIBS="$LIBS $OPENSSL_LIBS"
|
|
], [
|
|
- AC_CHECK_LIB([ssl], [SSL_library_init], [
|
|
+ AC_CHECK_LIB([ssl], [SSL_CTX_new], [
|
|
LIBS="$LIBS -lssl -lcrypto"
|
|
], [
|
|
AC_MSG_ERROR([The OpenSSL library was not found])
|
|
--
|
|
2.17.1
|
|
|