]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
dnsdist: Fix building with meson without all options enabled
authorRemi Gacogne <remi.gacogne@powerdns.com>
Fri, 27 Sep 2024 09:29:48 +0000 (11:29 +0200)
committerRemi Gacogne <remi.gacogne@powerdns.com>
Tue, 28 Jan 2025 13:37:20 +0000 (14:37 +0100)
pdns/dnsdistdist/dnsdist-nghttp2-in.cc
pdns/dnsdistdist/doh3.hh
pdns/dnsdistdist/doq.hh
pdns/dnsdistdist/meson/cdb/meson.build
pdns/dnsdistdist/meson/libsnmp/meson.build
pdns/dnsdistdist/meson/quiche/meson.build

index c93a8a3c953d29a7f7b43556b56d1d819a6c8066..2b19ecdeb2cc516c19538ee474e6dbd41aadd5f3 100644 (file)
  * along with this program; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  */
+#include "dnsdist-nghttp2-in.hh"
+
+#if defined(HAVE_DNS_OVER_HTTPS) && defined(HAVE_NGHTTP2)
 
 #include "dnsdist-dnsparser.hh"
 #include "dnsdist-doh-common.hh"
-#include "dnsdist-nghttp2-in.hh"
 #include "dnsdist-proxy-protocol.hh"
 #include "dnsparser.hh"
 
-#if defined(HAVE_DNS_OVER_HTTPS) && defined(HAVE_NGHTTP2)
-
 #if 0
 class IncomingDoHCrossProtocolContext : public CrossProtocolContext
 {
index 9e021c6114dbad17acfec4890ddf05cb4712c7f4..14850fcc700b3dc94baf561d77028bac8c713613 100644 (file)
@@ -33,7 +33,6 @@
 #include "iputils.hh"
 #include "libssl.hh"
 #include "stat_t.hh"
-#include "dnsdist-idstate.hh"
 
 struct DOH3ServerConfig;
 struct DownstreamState;
@@ -46,6 +45,7 @@ using h3_headers_t = std::unordered_map<std::string, std::string>;
 
 #ifdef HAVE_DNS_OVER_HTTP3
 
+#include "dnsdist-idstate.hh"
 #include "doq-common.hh"
 
 struct DOH3Frontend
index 4b0d2dc550a6314b11a0b773850ee1cb65b56386..66b64953df623e09d2ea43c8ac39af1a44a72f6b 100644 (file)
 #include "noinitvector.hh"
 #include "doq.hh"
 #include "stat_t.hh"
-#include "dnsdist-idstate.hh"
 
 struct DOQServerConfig;
 struct DownstreamState;
 
 #ifdef HAVE_DNS_OVER_QUIC
 
+#include "dnsdist-idstate.hh"
 #include "doq-common.hh"
 
 struct DOQFrontend
index 0b7870b0566a394d813557b2d6d7d3530feeb8fe..b05ee9dfc9fdab4e6848f3bcc9d7e73089ae45b5 100644 (file)
@@ -1,5 +1,3 @@
-dep_cdb = dependency('', required: false)
-
 dep_cdb = dependency('libcdb', required: false)
 
 if not dep_cdb.found()
index 208d8581ed42aeb73ad395c0cacbe3aa9af935f0..cdf26a9e5beea18a3fef35cf560cb94e7f86b391 100644 (file)
@@ -1,8 +1,8 @@
 opt_libsnmp = get_option('snmp')
 
-dep_libsnmp = declare_dependency()
+dep_libsnmp = dependency('', required: false)
 
-if get_option('snmp')
+if opt_libsnmp
     snmp_config = find_program('net-snmp-config', required: true)
     snmp_ldflags_res = run_command(snmp_config, '--netsnmp-agent-libs', check: true)
     snmp_ldflags = snmp_ldflags_res.stdout().strip().split()
index c680f035ab3fc6cbd862e92e37614d11c21345e4..0774c1a58dd8f7a4f61f3a5a76a4038ad0ac05d3 100644 (file)
@@ -1,4 +1,4 @@
-dep_libquiche = declare_dependency()
+dep_libquiche = dependency('', required: false)
 opt_libquiche = get_option('quiche')
 
 if (get_option('dns-over-quic') or get_option('dns-over-http3')) and opt_libquiche.allowed()