]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
dnsdist: Gracefully fall back to older versions of Quiche 15134/head
authorRemi Gacogne <remi.gacogne@powerdns.com>
Fri, 7 Feb 2025 15:01:50 +0000 (16:01 +0100)
committerRemi Gacogne <remi.gacogne@powerdns.com>
Fri, 7 Feb 2025 15:01:50 +0000 (16:01 +0100)
Before this commit we only tried older versions of Quiche if the
`quiche` feature was not explicitely enabled, and failed otherwise.

pdns/dnsdistdist/meson/quiche/meson.build

index d03aade91f6e48966ee24466216e26dc7b2ef4f5..31980cf6b9fbe1bb74a3322fb23b26804287d444 100644 (file)
@@ -1,18 +1,20 @@
 dep_libquiche = dependency('', required: false)
 opt_libquiche = get_option('quiche')
+opt_quic = get_option('dns-over-quic')
+opt_doh3 = get_option('dns-over-http3')
 
-if (get_option('dns-over-quic') or get_option('dns-over-http3')) and opt_libquiche.allowed()
-  dep_libquiche = dependency('quiche', version: '>= 0.23.0', required: opt_libquiche)
+if (opt_quic or opt_doh3) and opt_libquiche.allowed()
+  dep_libquiche = dependency('quiche', version: '>= 0.23.0', required: false)
   if dep_libquiche.found()
     conf.set('HAVE_QUICHE_H3_EVENT_HEADERS_HAS_MORE_FRAMES', dep_libquiche.found(), description: 'if the Quiche API has quiche_h3_event_headers_has_more_frames instead of quiche_h3_event_headers_has_body')
   else
-    dep_libquiche = dependency('quiche', version: '>= 0.22.0', required: opt_libquiche)
+    dep_libquiche = dependency('quiche', version: '>= 0.22.0', required: false)
   endif
 
   if dep_libquiche.found()
     conf.set('HAVE_QUICHE_STREAM_ERROR_CODES', dep_libquiche.found(), description: 'if the Quiche API includes error code in quiche_conn_stream_recv and quiche_conn_stream_send')
   else
-    dep_libquiche = dependency('quiche', version: '>= 0.15.0', required: opt_libquiche)
+    dep_libquiche = dependency('quiche', version: '>= 0.15.0', required: opt_libquiche or opt_quic or opt_doh3)
   endif
 endif