subdir('src/hibernate-resume')
subdir('src/home')
subdir('src/hostname')
+subdir('src/hwdb')
subdir('src/id128')
subdir('src/import')
subdir('src/initctl')
subdir('src/system-update-generator')
subdir('src/systemctl')
subdir('src/sysupdate')
+subdir('src/sysusers')
subdir('src/sysv-generator')
subdir('src/timedate')
subdir('src/timesync')
endif
if enable_sysusers
- exe = executable(
- 'systemd-sysusers',
- 'src/sysusers/sysusers.c',
- include_directories : includes,
- link_with : [libshared],
- dependencies : [userspace],
- install_rpath : pkglibdir,
- install : true)
- public_programs += exe
-
if want_tests != 'false'
+ exe = executables_by_name.get('systemd-sysusers')
test('test-sysusers',
test_sysusers_sh,
# https://github.com/mesonbuild/meson/issues/2681
args : exe.full_path())
endif
- exe = executable(
- 'systemd-sysusers.standalone',
- 'src/sysusers/sysusers.c',
- include_directories : includes,
- c_args : '-DSTANDALONE',
- link_with : [libshared_static,
- libbasic,
- libbasic_gcrypt,
- libsystemd_static],
- dependencies : [userspace],
- build_by_default: have_standalone_binaries,
- install : have_standalone_binaries)
if have_standalone_binaries
- public_programs += exe
-
if want_tests != 'false'
+ exe = executables_by_name.get('systemd-sysusers.standalone')
test('test-sysusers.standalone',
test_sysusers_sh,
# https://github.com/mesonbuild/meson/issues/2681
endif
if conf.get('ENABLE_TMPFILES') == 1
- exe = executable(
- 'systemd-tmpfiles',
- systemd_tmpfiles_sources,
- include_directories : includes,
- link_with : [libshared],
- dependencies : [libacl,
- userspace],
- install_rpath : pkglibdir,
- install : true)
- public_programs += exe
-
if want_tests != 'false'
+ exe = executables_by_name.get('systemd-tmpfiles')
test('test-systemd-tmpfiles',
test_systemd_tmpfiles_py,
# https://github.com/mesonbuild/meson/issues/2681
args : exe.full_path())
endif
- exe = executable(
- 'systemd-tmpfiles.standalone',
- systemd_tmpfiles_sources,
- include_directories : includes,
- c_args : '-DSTANDALONE',
- link_with : [libshared_static,
- libbasic,
- libbasic_gcrypt,
- libsystemd_static],
- dependencies : [libacl,
- userspace],
- build_by_default: have_standalone_binaries,
- install : have_standalone_binaries)
if have_standalone_binaries
- public_programs += exe
-
if want_tests != 'false'
+ exe = executables_by_name.get('systemd-tmpfiles.standalone')
test('test-systemd-tmpfiles.standalone',
test_systemd_tmpfiles_py,
# https://github.com/mesonbuild/meson/issues/2681
endif
if conf.get('ENABLE_HWDB') == 1
- systemd_hwdb = executable(
- 'systemd-hwdb',
- 'src/hwdb/hwdb.c',
- include_directories : includes,
- link_with : udev_link_with,
- dependencies : [userspace],
- install_rpath : udev_rpath,
- install : true)
- public_programs += systemd_hwdb
-
if want_tests != 'false'
+ exe = executables_by_name.get('systemd-hwdb')
test('hwdb-test',
hwdb_test_sh,
suite : 'dist',
- args : [systemd_hwdb.full_path()],
+ args : exe.full_path(),
timeout : 90)
endif
endif
--- /dev/null
+# SPDX-License-Identifier: LGPL-2.1-or-later
+
+executables += [
+ executable_template + {
+ 'name' : 'systemd-sysusers',
+ 'public' : true,
+ 'conditions' : ['ENABLE_SYSUSERS'],
+ 'sources' : files('sysusers.c'),
+ },
+ executable_template + {
+ 'name' : 'systemd-sysusers.standalone',
+ 'public' : have_standalone_binaries,
+ 'conditions' : ['ENABLE_SYSUSERS'],
+ 'sources' : files('sysusers.c'),
+ 'c_args' : '-DSTANDALONE',
+ 'link_with' : [
+ libbasic,
+ libbasic_gcrypt,
+ libshared_static,
+ libsystemd_static,
+ ],
+ 'build_by_default' : have_standalone_binaries,
+ 'install' : have_standalone_binaries,
+ },
+]
'offline-passwd.c',
)
+executables += [
+ executable_template + {
+ 'name' : 'systemd-tmpfiles',
+ 'public' : true,
+ 'conditions' : ['ENABLE_TMPFILES'],
+ 'sources' : systemd_tmpfiles_sources,
+ 'dependencies' : libacl,
+ },
+ executable_template + {
+ 'name' : 'systemd-tmpfiles.standalone',
+ 'public' : have_standalone_binaries,
+ 'conditions' : ['ENABLE_TMPFILES'],
+ 'sources' : systemd_tmpfiles_sources,
+ 'c_args' : '-DSTANDALONE',
+ 'link_with' : [
+ libbasic,
+ libbasic_gcrypt,
+ libshared_static,
+ libsystemd_static,
+ ],
+ 'dependencies' : libacl,
+ 'build_by_default' : have_standalone_binaries,
+ 'install' : have_standalone_binaries,
+ },
+]
+
tests += [
{
'sources' : files(