'sysconfdir=/etc',
'localstatedir=/var',
],
- meson_version : '>= 0.45',
+ meson_version : '>= 0.46',
)
libsystemd_version = '0.23.0'
endif
add_project_arguments(cc.get_supported_arguments(possible_cc_flags), language : 'c')
+add_project_link_arguments(cc.get_supported_link_arguments(possible_link_flags), language : 'c')
# "negative" arguments: gcc on purpose does not return an error for "-Wno-"
# arguments, just emits a warning. So test for the "positive" version instead.
add_project_arguments('-Werror=shadow', language : 'c')
endif
-link_test_c = files('tools/meson-link-test.c')
-
-foreach arg : possible_link_flags
- have = run_command(check_compilation_sh,
- cc.cmd_array(), '-x', 'c', arg,
- '-include', link_test_c).returncode() == 0
- message('Linking with @0@ supported: @1@'.format(arg, have ? 'yes' : 'no'))
- if have
- add_project_link_arguments(arg, language : 'c')
- endif
-endforeach
-
cpp = ' '.join(cc.cmd_array()) + ' -E'
#####################################################################
conf.set10('ENABLE_ADM_GROUP', get_option('adm-group'))
conf.set10('ENABLE_WHEEL_GROUP', get_option('wheel-group'))
-substs.set('DEV_KVM_MODE', get_option('dev-kvm-mode'))
+dev_kvm_mode = get_option('dev-kvm-mode')
+substs.set('DEV_KVM_MODE', dev_kvm_mode)
+conf.set10('DEV_KVM_UACCESS', dev_kvm_mode != '0666')
substs.set('GROUP_RENDER_MODE', get_option('group-render-mode'))
kill_user_processes = get_option('default-kill-user-processes')
endif
conf.set10('HAVE_GNUTLS', have)
+want_openssl = get_option('openssl')
+if want_openssl != 'false' and not fuzzer_build
+ libopenssl = dependency('openssl',
+ version : '>= 1.1.0',
+ required : want_openssl == 'true')
+ have = libopenssl.found()
+else
+ have = false
+ libopenssl = []
+endif
+conf.set10('HAVE_OPENSSL', have)
+
want_elfutils = get_option('elfutils')
if want_elfutils != 'false' and not fuzzer_build
libdw = dependency('libdw',
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')
+ if dns_over_tls == 'openssl'
+ have_gnutls = false
+ else
+ have_gnutls = (conf.get('HAVE_GNUTLS') == 1 and libgnutls.version().version_compare('>= 3.5.3'))
+ if dns_over_tls == 'gnutls' and not have_gnutls
+ error('DNS-over-TLS support was requested with gnutls, but dependencies are not available')
+ endif
endif
+ if dns_over_tls == 'gnutls' or have_gnutls
+ have_openssl = false
+ else
+ have_openssl = conf.get('HAVE_OPENSSL') == 1
+ if dns_over_tls != 'auto' and not have_openssl
+ str = dns_over_tls == 'openssl' ? ' with openssl' : ''
+ error('DNS-over-TLS support was requested$0$, but dependencies are not available'.format(str))
+ endif
+ endif
+ have = have_gnutls or have_openssl
else
- have = false
+ have = have_gnutls = have_openssl = false
endif
conf.set10('ENABLE_DNS_OVER_TLS', have)
+conf.set10('DNS_OVER_TLS_USE_GNUTLS', have_gnutls)
+conf.set10('DNS_OVER_TLS_USE_OPENSSL', have_openssl)
default_dns_over_tls = get_option('default-dns-over-tls')
if fuzzer_build
libblkid],
install_rpath : rootlibexecdir,
install : true)
-public_programs += [exe]
+public_programs += exe
executable('systemd-journald',
systemd_journald_sources,
dependencies : [threads],
install_rpath : rootlibexecdir,
install : true)
-public_programs += [exe]
+public_programs += exe
exe = executable('journalctl',
journalctl_sources,
install_rpath : rootlibexecdir,
install : true,
install_dir : rootbindir)
-public_programs += [exe]
+public_programs += exe
executable('systemd-getty-generator',
'src/getty-generator/getty-generator.c',
install_rpath : rootlibexecdir,
install : true,
install_dir : rootlibexecdir)
- public_programs += [exe]
+ public_programs += exe
endif
if conf.get('ENABLE_RESOLVE') == 1
libidn],
install_rpath : rootlibexecdir,
install : true)
- public_programs += [exe]
+ public_programs += exe
meson.add_install_script(meson_make_symlink,
join_paths(bindir, 'resolvectl'),
install_rpath : rootlibexecdir,
install : true,
install_dir : rootbindir)
- public_programs += [exe]
+ public_programs += exe
exe = executable('systemd-inhibit',
'src/login/inhibit.c',
install_rpath : rootlibexecdir,
install : true,
install_dir : rootbindir)
- public_programs += [exe]
+ public_programs += exe
if conf.get('HAVE_PAM') == 1
version_script_arg = join_paths(meson.current_source_dir(), pam_systemd_sym)
dependencies : [libblkid],
install_rpath : rootlibexecdir,
install : true)
- public_programs += [exe]
+ public_programs += exe
endif
exe = executable('systemd-socket-activate', 'src/activate/activate.c',
dependencies : [threads],
install_rpath : rootlibexecdir,
install : true)
-public_programs += [exe]
+public_programs += exe
if get_option('link-systemctl-shared')
install_rpath : rootlibexecdir,
install : true,
install_dir : rootbindir)
-public_programs += [exe]
+public_programs += exe
if conf.get('ENABLE_PORTABLED') == 1
executable('systemd-portabled',
install_rpath : rootlibexecdir,
install : true,
install_dir : rootlibexecdir)
- public_programs += [exe]
+ public_programs += exe
endif
foreach alias : ['halt', 'poweroff', 'reboot', 'runlevel', 'shutdown', 'telinit']
link_with : [libshared],
install_rpath : rootlibexecdir,
install : true)
- public_programs += [exe]
+ public_programs += exe
endif
if conf.get('ENABLE_LOCALED') == 1
link_with : [libshared],
install_rpath : rootlibexecdir,
install : true)
- public_programs += [exe]
+ public_programs += exe
endif
if conf.get('ENABLE_TIMEDATED') == 1
link_with : [libshared],
dependencies : [libm],
install : true)
- public_programs += [exe]
+ public_programs += exe
endif
if conf.get('ENABLE_TIMESYNCD') == 1
install_rpath : rootlibexecdir,
install : true,
install_dir : rootbindir)
- public_programs += [exe]
+ public_programs += exe
endif
if conf.get('ENABLE_IMPORTD') == 1
install_rpath : rootlibexecdir,
install : true,
install_dir : rootlibexecdir)
- public_programs += [exe]
+ public_programs += exe
endif
if conf.get('ENABLE_REMOTE') == 1 and conf.get('HAVE_MICROHTTPD') == 1
liblz4],
install_rpath : rootlibexecdir,
install : true)
- public_programs += [exe]
+ public_programs += exe
endif
if conf.get('ENABLE_BINFMT') == 1
install_rpath : rootlibexecdir,
install : true,
install_dir : rootlibexecdir)
- public_programs += [exe]
+ public_programs += exe
meson.add_install_script('sh', '-c',
mkdir_p.format(binfmtdir))
install_rpath : rootlibexecdir,
install : true,
install_dir : rootlibexecdir)
-public_programs += [exe]
+public_programs += exe
executable('systemd-ac-power',
'src/ac-power/ac-power.c',
link_with : [libshared],
install_rpath : rootlibexecdir,
install : true)
-public_programs += [exe]
+public_programs += exe
exe = executable('systemd-delta',
'src/delta/delta.c',
link_with : [libshared],
install_rpath : rootlibexecdir,
install : true)
-public_programs += [exe]
+public_programs += exe
exe = executable('systemd-escape',
'src/escape/escape.c',
install_rpath : rootlibexecdir,
install : true,
install_dir : rootbindir)
-public_programs += [exe]
+public_programs += exe
exe = executable('systemd-notify',
'src/notify/notify.c',
install_rpath : rootlibexecdir,
install : true,
install_dir : rootbindir)
-public_programs += [exe]
+public_programs += exe
executable('systemd-volatile-root',
'src/volatile-root/volatile-root.c',
link_with : [libshared],
install_rpath : rootlibexecdir,
install : true)
-public_programs += [exe]
+public_programs += exe
exe = executable('systemd-ask-password',
'src/ask-password/ask-password.c',
install_rpath : rootlibexecdir,
install : true,
install_dir : rootbindir)
-public_programs += [exe]
+public_programs += exe
executable('systemd-reply-password',
'src/reply-password/reply-password.c',
install_rpath : rootlibexecdir,
install : true,
install_dir : rootbindir)
-public_programs += [exe]
+public_programs += exe
exe = executable('systemd-cgls',
'src/cgls/cgls.c',
link_with : [libshared],
install_rpath : rootlibexecdir,
install : true)
-public_programs += [exe]
+public_programs += exe
exe = executable('systemd-cgtop',
'src/cgtop/cgtop.c',
link_with : [libshared],
install_rpath : rootlibexecdir,
install : true)
-public_programs += [exe]
+public_programs += exe
executable('systemd-initctl',
'src/initctl/initctl.c',
link_with : [libshared],
install_rpath : rootlibexecdir,
install : true)
-public_programs += [exe]
+public_programs += exe
meson.add_install_script(meson_make_symlink,
'systemd-mount', join_paths(bindir, 'systemd-umount'))
link_with : [libshared],
install_rpath : rootlibexecdir,
install : true)
-public_programs += [exe]
+public_programs += exe
exe = executable('systemd-stdio-bridge',
'src/stdio-bridge/stdio-bridge.c',
link_with : [libshared],
install_rpath : rootlibexecdir,
install : true)
-public_programs += [exe]
+public_programs += exe
exe = executable('busctl',
'src/busctl/busctl.c',
link_with : [libshared],
install_rpath : rootlibexecdir,
install : true)
-public_programs += [exe]
+public_programs += exe
if conf.get('ENABLE_SYSUSERS') == 1
exe = executable('systemd-sysusers',
install_rpath : rootlibexecdir,
install : true,
install_dir : rootbindir)
- public_programs += [exe]
+ public_programs += exe
endif
if conf.get('ENABLE_TMPFILES') == 1
install_rpath : rootlibexecdir,
install : true,
install_dir : rootbindir)
- public_programs += [exe]
+ public_programs += exe
test('test-systemd-tmpfiles',
test_systemd_tmpfiles_py,
install_rpath : udev_rpath,
install : true,
install_dir : rootbindir)
- public_programs += [exe]
+ public_programs += exe
endif
if conf.get('ENABLE_QUOTACHECK') == 1
install_rpath : rootlibexecdir,
install : true,
install_dir : rootlibexecdir)
-public_programs += [exe]
+public_programs += exe
exe = executable('systemd-udevd',
systemd_udevd_sources,
install_rpath : udev_rpath,
install : true,
install_dir : rootlibexecdir)
-public_programs += [exe]
+public_programs += exe
exe = executable('udevadm',
udevadm_sources,
install_rpath : udev_rpath,
install : true,
install_dir : rootbindir)
-public_programs += [exe]
+public_programs += exe
executable('systemd-shutdown',
systemd_shutdown_sources,
dependencies : [libblkid],
install_rpath : rootlibexecdir,
install : true)
-public_programs += [exe]
+public_programs += exe
if conf.get('ENABLE_NETWORKD') == 1
executable('systemd-networkd',
install_rpath : rootlibexecdir,
install : true,
install_dir : rootbindir)
- public_programs += [exe]
+ public_programs += exe
endif
executable('systemd-sulogin-shell',
sanitizer = tuple[0]
build = tuple[1]
- have = run_command(check_compilation_sh,
- cc.cmd_array(), '-x', 'c',
- '-fsanitize=@0@'.format(sanitizer),
- '-include', link_test_c).returncode() == 0
- message('@0@ sanitizer supported: @1@'.format(sanitizer, have ? 'yes' : 'no'))
-
- if have
+ if cc.has_link_argument('-fsanitize=@0@'.format(sanitizer))
prev = ''
foreach p : fuzz_regression_tests
b = p.split('/')[-2]
# LDFLAGS: ${OUR_LDFLAGS} ${LDFLAGS}
if conf.get('ENABLE_EFI') == 1
- status += [
- 'efi arch: @0@'.format(efi_arch)]
+ status += 'efi arch: @0@'.format(efi_arch)
if have_gnu_efi
status += [
['qrencode'],
['microhttpd'],
['gnutls'],
+ ['openssl'],
['libcurl'],
['idn'],
['libidn2'],
['localed'],
['networkd'],
['resolve'],
- ['DNS-over-TLS'],
+ ['DNS-over-TLS(gnutls)', conf.get('DNS_OVER_TLS_USE_GNUTLS') == 1],
+ ['DNS-over-TLS(openssl)', conf.get('DNS_OVER_TLS_USE_OPENSSL') == 1],
['coredump'],
['polkit'],
['legacy pkla', install_polkit_pkla],
cond = conf.get(ident1, 0) == 1 or conf.get(ident2, 0) == 1
endif
if cond
- found += [tuple[0]]
+ found += tuple[0]
else
- missing += [tuple[0]]
+ missing += tuple[0]
endif
endforeach