diff options
author | Daiki Ueno <dueno@src.gnome.org> | 2021-02-11 18:32:56 +0100 |
---|---|---|
committer | Daiki Ueno <dueno@src.gnome.org> | 2021-03-27 09:49:47 +0100 |
commit | 5012bee0d6c85001d6224b0fbcf8624c569debb1 (patch) | |
tree | 72a17901dd23d1aee3e541c0443dbd7ce137160b /meson.build | |
parent | e225c52586d17a9cc44ac57e7bc58ad417f42fe9 (diff) | |
download | gcr-5012bee0d6c85001d6224b0fbcf8624c569debb1.tar.gz |
gcr-ssh-agent: Wire up systemd activation
Diffstat (limited to 'meson.build')
-rw-r--r-- | meson.build | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/meson.build b/meson.build index 3456d32..ca3c469 100644 --- a/meson.build +++ b/meson.build @@ -55,6 +55,16 @@ libsecret_dep = dependency('libsecret-1', version: '>= 0.20', required: get_opti ssh_add_path = find_program('ssh-add', required: get_option('ssh_agent')).path() ssh_agent_path = find_program('ssh-agent', required: get_option('ssh_agent')).path() +with_systemd = false +libsystemd_deps = [] +libsystemd = dependency('libsystemd', required: get_option('systemd')) +systemd = dependency('systemd', required: get_option('systemd')) +if libsystemd.found() and systemd.found() + systemduserunitdir = systemd.get_pkgconfig_variable('systemduserunitdir') + libsystemd_deps += libsystemd + with_systemd = true +endif + if get_option('gtk') gtk_min_version = '3.22' gtk_dep = dependency('gtk+-3.0', version: '>=' + gtk_min_version) @@ -74,6 +84,7 @@ conf.set_quoted('GPG_EXECUTABLE', gpg_path) conf.set_quoted('LIBGCRYPT_VERSION', libgcrypt_dep.version()) conf.set_quoted('SSH_ADD_EXECUTABLE', ssh_add_path) conf.set_quoted('SSH_AGENT_EXECUTABLE', ssh_agent_path) +conf.set10('WITH_SYSTEMD', with_systemd) config_file = configure_file( output: 'config.h', configuration: conf, |