pkgsrc-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
pkg/54755: Making net/dnsmasq build with newer nettle when dnssec is enabled.
>Number: 54755
>Category: pkg
>Synopsis: Making net/dnsmasq build with newer nettle when dnssec is enabled.
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: pkg-manager
>State: open
>Class: change-request
>Submitter-Id: net
>Arrival-Date: Wed Dec 11 16:00:01 +0000 2019
>Originator: Ben Gergely
>Release: current
>Organization:
potato
>Environment:
NetBSD funcube 9.99.19 NetBSD 9.99.19 (FUNCUBE) #0: Fri Dec 6 19:25:40 GMT 2019 potato@funcube:/usr/obj/sys/arch/amd64/compile/FUNCUBE amd64
>Description:
Making net/dnsmasq build with newer nettle when dnssec is enabled.
--- crypto.o ---
crypto.c: In function 'dnsmasq_ecdsa_verify':
crypto.c:297:36: error: 'nettle_secp_256r1' undeclared (first use in this function); did you mean 'nettle_get_secp_256r1'?
nettle_ecc_point_init(key_256, &nettle_secp_256r1);
^~~~~~~~~~~~~~~~~
nettle_get_secp_256r1
crypto.c:297:36: note: each undeclared identifier is reported only once for each function it appears in
crypto.c:310:36: error: 'nettle_secp_384r1' undeclared (first use in this function); did you mean 'nettle_secp_256r1'?
nettle_ecc_point_init(key_384, &nettle_secp_384r1);
^~~~~~~~~~~~~~~~~
nettle_secp_256r1
*** [crypto.o] Error code 1
>How-To-Repeat:
cd /usr/pkgsrc/net/dnsmasq ; make PKG_OPTIONS.dnsmasq+=dnssec
>Fix:
Patch it, or wait for a new version of dnsmasq I guess.
Index: distinfo
===================================================================
RCS file: /cvsroot/pkgsrc/net/dnsmasq/distinfo,v
retrieving revision 1.37
diff -u -u -r1.37 distinfo
--- distinfo 30 Oct 2018 11:16:06 -0000 1.37
+++ distinfo 11 Dec 2019 15:48:57 -0000
@@ -5,4 +5,5 @@
SHA512 (dnsmasq-2.80.tar.xz) = 58e56beb553fc41311e5dc16d8b0eb3b6801e2bdfbcd0e7a6659703f08960b6ad10d48b0b14a4d727636faf35483e01597cff2ae49e7fe9fa9e214f437b1c068
Size (dnsmasq-2.80.tar.xz) = 501072 bytes
SHA1 (patch-src_bpf.c) = 05dc64c016c608e6b963ce9ee80c28e872a88f9e
+SHA1 (patch-src_crypto.c) = c5cdfb845ab8e5bd4b1f464ba448d9d795641cde
SHA1 (patch-src_dump.c) = 3e7553e8ed2444536ba94187f7a100a9abdbb353
Index: patches/patch-src_crypto.c
===================================================================
RCS file: patches/patch-src_crypto.c
diff -N patches/patch-src_crypto.c
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-src_crypto.c 11 Dec 2019 15:48:57 -0000
@@ -0,0 +1,35 @@
+$NetBSD: patch-src_bpf.c $
+
+Make compat. with older nettle.
+
+--- src/crypto.c.orig
++++ src/crypto.c
+@@ -275,6 +275,10 @@ static int dnsmasq_ecdsa_verify(struct blockdata *key_
+ static struct ecc_point *key_256 = NULL, *key_384 = NULL;
+ static mpz_t x, y;
+ static struct dsa_signature *sig_struct;
++#if NETTLE_VERSION_MAJOR == 3 && NETTLE_VERSION_MINOR < 4
++#define nettle_get_secp_256r1() (&nettle_secp_256r1)
++#define nettle_get_secp_384r1() (&nettle_secp_384r1)
++#endif
+
+ if (!sig_struct)
+ {
+@@ -294,7 +298,7 @@ static int dnsmasq_ecdsa_verify(struct blockdata *key_
+ if (!(key_256 = whine_malloc(sizeof(struct ecc_point))))
+ return 0;
+
+- nettle_ecc_point_init(key_256, &nettle_secp_256r1);
++ nettle_ecc_point_init(key_256, nettle_get_secp_256r1());
+ }
+
+ key = key_256;
+@@ -307,7 +311,7 @@ static int dnsmasq_ecdsa_verify(struct blockdata *key_
+ if (!(key_384 = whine_malloc(sizeof(struct ecc_point))))
+ return 0;
+
+- nettle_ecc_point_init(key_384, &nettle_secp_384r1);
++ nettle_ecc_point_init(key_384, nettle_get_secp_384r1());
+ }
+
+ key = key_384;
Home |
Main Index |
Thread Index |
Old Index