aboutsummaryrefslogtreecommitdiff
path: root/external/unbound/dnscrypt/dnscrypt.m4
diff options
context:
space:
mode:
authorErik de Castro Lopo <erikd@mega-nerd.com>2017-06-16 20:16:05 +1000
committerErik de Castro Lopo <erikd@mega-nerd.com>2017-06-17 23:04:00 +1000
commita85b5759f34c0c4110a479a8b5fa606f15ed9b23 (patch)
tree518cb8346249a42fd2aa8a78c09c3631e14db6aa /external/unbound/dnscrypt/dnscrypt.m4
parentMerge pull request #2059 (diff)
downloadmonero-a85b5759f34c0c4110a479a8b5fa606f15ed9b23.tar.xz
Upgrade unbound library
These files were pulled from the 1.6.3 release tarball. This new version builds against OpenSSL version 1.1 which will be the default in the new Debian Stable which is due to be released RealSoonNow (tm).
Diffstat (limited to 'external/unbound/dnscrypt/dnscrypt.m4')
-rw-r--r--external/unbound/dnscrypt/dnscrypt.m425
1 files changed, 25 insertions, 0 deletions
diff --git a/external/unbound/dnscrypt/dnscrypt.m4 b/external/unbound/dnscrypt/dnscrypt.m4
new file mode 100644
index 000000000..077d28221
--- /dev/null
+++ b/external/unbound/dnscrypt/dnscrypt.m4
@@ -0,0 +1,25 @@
+# dnscrypt.m4
+
+# dnsc_DNSCRYPT([action-if-true], [action-if-false])
+# --------------------------------------------------------------------------
+# Check for required dnscrypt libraries and add dnscrypt configure args.
+AC_DEFUN([dnsc_DNSCRYPT],
+[
+ AC_ARG_ENABLE([dnscrypt],
+ AS_HELP_STRING([--enable-dnscrypt],
+ [Enable dnscrypt support (requires libsodium)]),
+ [opt_dnscrypt=$enableval], [opt_dnscrypt=no])
+
+ if test "x$opt_dnscrypt" != "xno"; then
+ AC_ARG_WITH([libsodium], AC_HELP_STRING([--with-libsodium=path],
+ [Path where libsodium is installed, for dnscrypt]), [
+ CFLAGS="$CFLAGS -I$withval/include"
+ LDFLAGS="$LDFLAGS -L$withval/lib"
+ ])
+ AC_SEARCH_LIBS([sodium_init], [sodium], [],
+ AC_MSG_ERROR([The sodium library was not found. Please install sodium!]))
+ $1
+ else
+ $2
+ fi
+])