]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
Meson: Add system build flag
authorFred Morcos <fred.morcos@open-xchange.com>
Tue, 9 Apr 2024 10:17:37 +0000 (12:17 +0200)
committerFred Morcos <fred.morcos@open-xchange.com>
Tue, 9 Apr 2024 10:17:37 +0000 (12:17 +0200)
meson/systemd/meson.build
meson_options.txt

index 74f515bfd44ced9382f30e132c2d7238f8936081..13b097b7a9110c4299c127bbda6e1183214188a7 100644 (file)
@@ -1,13 +1,9 @@
-dep_systemd = dependency('libsystemd', required: false)
+opt_systemd = get_option('systemd')
+
+dep_systemd = dependency('libsystemd', required: opt_systemd)
 conf.set('HAVE_SYSTEMD', dep_systemd.found(), description: 'systemd')
 summary('Systemd', dep_systemd.found(), bool_yn: true, section: 'Configuration')
 
 if dep_systemd.found()
   summary('Version', dep_systemd.version(), section: 'Systemd')
-
-  systemd_service_user = get_option('systemd-service-user')
-  systemd_service_group = get_option('systemd-service-group')
-
-  summary('Service User', systemd_service_user, section: 'Systemd')
-  summary('Service Group', systemd_service_group, section: 'Systemd')
 endif
index 64d5dc8d2c8af806512abe0f234b0720ba9af734..c33ae9b8db155930dc44b0b6e23afb306760375a 100644 (file)
@@ -36,6 +36,7 @@ option('module-lua2', type: 'combo', choices: ['disabled', 'static', 'dynamic'],
 option('tools', type: 'boolean', value: false, description: 'Build extra tools')
 option('tools-ixfrdist', type: 'boolean', value: false, description: 'Build ixfrdist')
 option('lua-records', type: 'boolean', value: true, description: 'Support Lua records')
+option('systemd', type: 'feature', value: 'auto', description: 'Systemd notification (requires libsystemd)')
 option('systemd-service-user', type: 'string', value: 'pdns', description: 'Systemd service user (setuid and unit file; user is not created)')
 option('systemd-service-group', type: 'string', value: 'pdns', description: 'Systemd service group (setgid and unit file; group is not created)')
 option('auto-var-init', type: 'combo', value: 'disabled', choices: ['zero', 'pattern', 'disabled'], description: 'Enable initialization of automatic variables')