]> git.ipfire.org Git - thirdparty/systemd.git/blobdiff - meson.build
tests: allow passing additional arguments to nspawn via NSPAWN_ARGUMENTS
[thirdparty/systemd.git] / meson.build
index 3644e8d5cb6e78d06ac2c33e0f695a25655e1e5a..68423bdfa5ef4ead8099d973cf823a0ab8e76198 100644 (file)
@@ -1,9 +1,7 @@
 # SPDX-License-Identifier: LGPL-2.1+
-#
-# Copyright 2017 Zbigniew JÄ™drzejewski-Szmek
 
 project('systemd', 'c',
-        version : '238',
+        version : '239',
         license : 'LGPLv2+',
         default_options: [
                 'c_std=gnu99',
@@ -14,8 +12,8 @@ project('systemd', 'c',
         meson_version : '>= 0.44',
        )
 
-libsystemd_version = '0.22.0'
-libudev_version = '1.6.10'
+libsystemd_version = '0.23.0'
+libudev_version = '1.6.11'
 
 # We need the same data in two different formats, ugh!
 # Also, for hysterical reasons, we use different variable
@@ -427,6 +425,7 @@ decl_headers = '''
 #include <sys/stat.h>
 '''
 # FIXME: key_serial_t is only defined in keyutils.h, this is bound to fail
+# FIXME: these should use -D_GNU_SOURCE, since that is defined at build time
 
 foreach decl : ['char16_t',
                 'char32_t',
@@ -441,6 +440,10 @@ foreach decl : ['char16_t',
         conf.set10('HAVE_' + decl.underscorify().to_upper(), have)
 endforeach
 
+conf.set10('HAVE_STRUCT_STATX_IN_SYS_STAT_H', cc.sizeof('struct statx', prefix : '''
+#include <sys/stat.h>
+''', args : '-D_GNU_SOURCE') > 0)
+
 foreach decl : [['IFLA_INET6_ADDR_GEN_MODE',         'linux/if_link.h'],
                 ['IN6_ADDR_GEN_MODE_STABLE_PRIVACY', 'linux/if_link.h'],
                 ['IFLA_VRF_TABLE',                   'linux/if_link.h'],
@@ -1137,6 +1140,30 @@ conf.set('DEFAULT_DNSSEC_MODE',
          'DNSSEC_' + default_dnssec.underscorify().to_upper())
 substs.set('DEFAULT_DNSSEC_MODE', default_dnssec)
 
+dns_over_tls = get_option('dns-over-tls')
+if dns_over_tls != 'false'
+        have = (conf.get('HAVE_GNUTLS') == 1 and
+                libgnutls.version().version_compare('>=3.5.3'))
+        if dns_over_tls == 'true' and not have
+                error('DNS-over-TLS support was requested, but dependencies are not available')
+        endif
+else
+        have = false
+endif
+conf.set10('ENABLE_DNS_OVER_TLS', have)
+
+default_dns_over_tls = get_option('default-dns-over-tls')
+if fuzzer_build
+        default_dns_over_tls = 'no'
+endif
+if default_dns_over_tls != 'no' and conf.get('ENABLE_DNS_OVER_TLS') == 0
+        message('default-dns-over-tls cannot be set to opportunistic when DNS-over-TLS support is disabled. Setting default-dns-over-tls to no.')
+        default_dns_over_tls = 'no'
+endif
+conf.set('DEFAULT_DNS_OVER_TLS_MODE',
+         'DNS_OVER_TLS_' + default_dns_over_tls.underscorify().to_upper())
+substs.set('DEFAULT_DNS_OVER_TLS_MODE', default_dns_over_tls)
+
 want_importd = get_option('importd')
 if want_importd != 'false'
         have = (conf.get('HAVE_LIBCURL') == 1 and
@@ -1584,10 +1611,7 @@ if conf.get('ENABLE_RESOLVE') == 1
                    link_with : [libshared,
                                 libbasic_gcrypt,
                                 libsystemd_resolve_core],
-                   dependencies : [threads,
-                                   libgpg_error,
-                                   libm,
-                                   libidn],
+                   dependencies : systemd_resolved_dependencies,
                    install_rpath : rootlibexecdir,
                    install : true,
                    install_dir : rootlibexecdir)
@@ -2857,6 +2881,7 @@ status = [
         'symbolic gateway hostnames:        @0@'.format(', '.join(gateway_hostnames)),
 
         'default DNSSEC mode:               @0@'.format(default_dnssec),
+        'default DNS-over-TLS mode:         @0@'.format(default_dns_over_tls),
         'default cgroup hierarchy:          @0@'.format(default_hierarchy),
         'default KillUserProcesses setting: @0@'.format(kill_user_processes)]
 
@@ -2938,6 +2963,7 @@ foreach tuple : [
         ['localed'],
         ['networkd'],
         ['resolve'],
+        ['DNS-over-TLS'],
         ['coredump'],
         ['polkit'],
         ['legacy pkla',      install_polkit_pkla],