1 From 063efb330a3f341c2548e2cf1f67f83e49cd6395 Mon Sep 17 00:00:00 2001
2 From: Simon Kelley <simon@thekelleys.org.uk>
3 Date: Tue, 17 Jun 2014 19:49:31 +0100
4 Subject: [PATCH] Build config: add -DNO_GMP for use with nettle/mini-gmp
8 bld/pkg-wrapper | 9 +++++++--
9 src/config.h | 7 +++++++
11 4 files changed, 17 insertions(+), 4 deletions(-)
15 @@ -61,7 +61,7 @@ lua_cflags = `echo $(COPTS) | $(top)/
16 lua_libs = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_LUASCRIPT $(PKG_CONFIG) --libs lua5.1`
17 nettle_cflags = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_DNSSEC $(PKG_CONFIG) --cflags nettle hogweed`
18 nettle_libs = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_DNSSEC $(PKG_CONFIG) --libs nettle hogweed`
19 -gmp_libs = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_DNSSEC $(PKG_CONFIG) --copy -lgmp`
20 +gmp_libs = `echo $(COPTS) | $(top)/bld/pkg-wrapper HAVE_DNSSEC NO_GMP --copy -lgmp`
21 sunos_libs = `if uname | grep SunOS >/dev/null 2>&1; then echo -lsocket -lnsl -lposix4; fi`
22 version = -DVERSION='\"`$(top)/bld/get-version $(top)`\"'
26 @@ -11,9 +11,14 @@ in=`cat`
28 if grep "^\#[[:space:]]*define[[:space:]]*$search" config.h >/dev/null 2>&1 || \
29 echo $in | grep $search >/dev/null 2>&1; then
31 +# Nasty, nasty, in --copy, arg 2 is another config to search for, use with NO_GMP
32 if [ $op = "--copy" ]; then
34 + if grep "^\#[[:space:]]*define[[:space:]]*$pkg" config.h >/dev/null 2>&1 || \
35 + echo $in | grep $pkg >/dev/null 2>&1; then
40 elif grep "^\#[[:space:]]*define[[:space:]]*${search}_STATIC" config.h >/dev/null 2>&1 || \
41 echo $in | grep ${search}_STATIC >/dev/null 2>&1; then
42 pkg=`$pkg --static $op $*`
45 @@ -105,6 +105,8 @@ HAVE_AUTH
46 define this to include the facility to act as an authoritative DNS
47 server for one or more zones.
50 + include DNSSEC validator.
54 @@ -118,6 +120,11 @@ NO_AUTH
55 which are enabled by default in the distributed source tree. Building dnsmasq
56 with something like "make COPTS=-DNO_SCRIPT" will do the trick.
59 + Don't include the ECDSA cypher in DNSSEC validation. Needed for older Nettle versions.
61 + Don't use and link against libgmp, Useful if nettle is built with --enable-mini-gmp.
69 # include <nettle/ecc-curve.h>
71 #include <nettle/nettle-meta.h>
73 +#include <nettle/bignum.h>
76 #define SERIAL_UNDEF -100