From 395c77e7dd2020fcd73278adfdc84936d182808f Mon Sep 17 00:00:00 2001 From: Lars Wendler Date: Fri, 20 Jan 2023 10:56:26 +0100 Subject: [PATCH] Add elogind support Signed-off-by: Lars Wendler --- meson.build | 7 ++++++- meson_options.txt | 4 +++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/meson.build b/meson.build index 3f4fce2..21283c3 100644 --- a/meson.build +++ b/meson.build @@ -65,7 +65,12 @@ python = find_program('python3') require_glesv2 = get_option('video_drm3d').enabled() or get_option('renderer_gltex').enabled() require_libdrm = get_option('video_drm2d').enabled() or get_option('video_drm3d').enabled() -libsystemd_deps = dependency('libsystemd', disabler: true, required: get_option('multi_seat')) +if get_option('elogind').enabled() + multi_seat_dep = 'libelogind' +else + multi_seat_dep = 'libsystemd' +endif +libsystemd_deps = dependency(multi_seat_dep, disabler: true, required: get_option('multi_seat')) libdrm_deps = dependency('libdrm', disabler: true, required: require_libdrm) gbm_deps = dependency('gbm', disabler: true, required: get_option('video_drm3d')) egl_deps = dependency('egl', disabler: true, required: get_option('video_drm3d')) diff --git a/meson_options.txt b/meson_options.txt index 7460d5b..66c0885 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -7,7 +7,9 @@ option('docs', type: 'feature', value: 'auto', # multi-seat option('multi_seat', type: 'feature', value: 'auto', - description: 'Multi-seat support with systemd') + description: 'Multi-seat support with systemd or elogind') +option('elogind', type: 'feature', value: 'disabled', + description: 'Prefer elogind over systemd') # video backends option('video_fbdev', type: 'feature', value: 'auto', -- 2.39.1