ryantimwilson / rpms / systemd

Forked from rpms/systemd 2 months ago
Clone
36e8a3
From b6943446f8ffde53ce059b5e869c22bed8926827 Mon Sep 17 00:00:00 2001
36e8a3
From: Yu Watanabe <watanabe.yu+github@gmail.com>
36e8a3
Date: Mon, 25 Jun 2018 22:40:40 +0900
36e8a3
Subject: [PATCH] meson: check whether gnutls supports TCP fast open
36e8a3
36e8a3
Fixes #9403
36e8a3
36e8a3
Cherry-picked from: f02582f69fe1e7663a87ba80bd4f90d5d23ee75f
36e8a3
---
36e8a3
 README      | 1 +
36e8a3
 meson.build | 2 +-
36e8a3
 2 files changed, 2 insertions(+), 1 deletion(-)
36e8a3
36e8a3
diff --git a/README b/README
36e8a3
index 2cde08c37..7d06e0480 100644
36e8a3
--- a/README
36e8a3
+++ b/README
36e8a3
@@ -154,6 +154,7 @@ REQUIREMENTS:
36e8a3
         libmicrohttpd (optional)
36e8a3
         libpython (optional)
36e8a3
         libidn2 or libidn (optional)
36e8a3
+        gnutls >= 3.1.4 (optional, >= 3.5.3 is necessary to support DNS-over-TLS)
36e8a3
         elfutils >= 158 (optional)
36e8a3
         polkit (optional)
36e8a3
         pkg-config
36e8a3
diff --git a/meson.build b/meson.build
36e8a3
index ebc55872c..d58926c98 100644
36e8a3
--- a/meson.build
36e8a3
+++ b/meson.build
36e8a3
@@ -1148,7 +1148,7 @@ substs.set('DEFAULT_DNSSEC_MODE', default_dnssec)
36e8a3
 
36e8a3
 dns_over_tls = get_option('dns-over-tls')
36e8a3
 if dns_over_tls != 'false'
36e8a3
-        have = conf.get('HAVE_GNUTLS') == 1
36e8a3
+        have = libgnutls != [] and libgnutls.version().version_compare('>=3.5.3')
36e8a3
         if dns_over_tls == 'true' and not have
36e8a3
                 error('DNS-over-TLS support was requested, but dependencies are not available')
36e8a3
         endif