summaryrefslogtreecommitdiff
path: root/security
diff options
context:
space:
mode:
authorhe <he@pkgsrc.org>2020-06-08 15:07:42 +0000
committerhe <he@pkgsrc.org>2020-06-08 15:07:42 +0000
commita31489aacc6b131b65ddb9f5362e6243629b7306 (patch)
treeae91e76674167b4e3949d97ee69056f7b863f3b6 /security
parent267d094e3f25ff8477fea7f849ac5c20f53e68d0 (diff)
downloadpkgsrc-a31489aacc6b131b65ddb9f5362e6243629b7306.tar.gz
Add an m4 + configure patch so that -lcrypto is searched for
EVP_sha1 and EVP_sha256. Without this, opendnssec would build but would not recognize any of those algorithms for tsig, and therefore be pretty useless. I'll admit that I'm not entirely certain why this is now suddenly required; those functions are in the same library in 9.0 as in 8.0. Bump PKGREVISION.
Diffstat (limited to 'security')
-rw-r--r--security/opendnssec/Makefile5
-rw-r--r--security/opendnssec/patches/patch-configure56
-rw-r--r--security/opendnssec/patches/patch-m4_acx__ssl.m412
3 files changed, 70 insertions, 3 deletions
diff --git a/security/opendnssec/Makefile b/security/opendnssec/Makefile
index 88c2446bcb9..9979d7abccf 100644
--- a/security/opendnssec/Makefile
+++ b/security/opendnssec/Makefile
@@ -1,9 +1,8 @@
-# $NetBSD: Makefile,v 1.80 2020/06/02 08:24:41 adam Exp $
+# $NetBSD: Makefile,v 1.81 2020/06/08 15:07:42 he Exp $
#
DISTNAME= opendnssec-1.4.14
-#PKGREVISION= 9
-PKGREVISION= 3
+PKGREVISION= 4
CATEGORIES= security net
MASTER_SITES= https://www.opendnssec.org/files/source/
diff --git a/security/opendnssec/patches/patch-configure b/security/opendnssec/patches/patch-configure
new file mode 100644
index 00000000000..b82c6952a85
--- /dev/null
+++ b/security/opendnssec/patches/patch-configure
@@ -0,0 +1,56 @@
+$NetBSD: patch-configure,v 1.1 2020/06/08 15:07:43 he Exp $
+
+--- configure.orig 2020-06-08 14:38:08.801388307 +0000
++++ configure
+@@ -16981,6 +16981,51 @@ fi
+
+ fi
+
++ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EVP_sha1 in -lcrypto" >&5
++$as_echo_n "checking for EVP_sha1 in -lcrypto... " >&6; }
++if ${ac_cv_lib_crypto_EVP_sha1+:} false; then :
++ $as_echo_n "(cached) " >&6
++else
++ ac_check_lib_save_LIBS=$LIBS
++LIBS="-lcrypto $LIBS"
++cat confdefs.h - <<_ACEOF >conftest.$ac_ext
++/* end confdefs.h. */
++
++/* Override any GCC internal prototype to avoid an error.
++ Use char because int might match the return type of a GCC
++ builtin and then its argument prototype would still apply. */
++#ifdef __cplusplus
++extern "C"
++#endif
++char EVP_sha1 ();
++int
++main ()
++{
++return EVP_sha1 ();
++ ;
++ return 0;
++}
++_ACEOF
++if ac_fn_c_try_link "$LINENO"; then :
++ ac_cv_lib_crypto_EVP_sha1=yes
++else
++ ac_cv_lib_crypto_EVP_sha1=no
++fi
++rm -f core conftest.err conftest.$ac_objext \
++ conftest$ac_exeext conftest.$ac_ext
++LIBS=$ac_check_lib_save_LIBS
++fi
++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_EVP_sha1" >&5
++$as_echo "$ac_cv_lib_crypto_EVP_sha1" >&6; }
++if test "x$ac_cv_lib_crypto_EVP_sha1" = xyes; then :
++ cat >>confdefs.h <<_ACEOF
++#define HAVE_LIBCRYPTO 1
++_ACEOF
++
++ LIBS="-lcrypto $LIBS"
++
++fi
++
+ for ac_func in EVP_sha1 EVP_sha256
+ do :
+ as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
diff --git a/security/opendnssec/patches/patch-m4_acx__ssl.m4 b/security/opendnssec/patches/patch-m4_acx__ssl.m4
new file mode 100644
index 00000000000..24dfbe7e1a5
--- /dev/null
+++ b/security/opendnssec/patches/patch-m4_acx__ssl.m4
@@ -0,0 +1,12 @@
+$NetBSD: patch-m4_acx__ssl.m4,v 1.1 2020/06/08 15:07:43 he Exp $
+
+--- m4/acx_ssl.m4.orig 2017-02-23 09:28:27.000000000 +0000
++++ m4/acx_ssl.m4
+@@ -43,6 +43,7 @@ AC_DEFUN([ACX_SSL], [
+ AC_MSG_ERROR([OpenSSL found in $ssldir, but version 0.9.7 or higher is required])
+ ])
+ ] )
++ AC_CHECK_LIB(crypto, EVP_sha1)
+ AC_CHECK_FUNCS([EVP_sha1 EVP_sha256])
+ fi
+ AC_SUBST(HAVE_SSL)