diff options
Diffstat (limited to 'backend')
-rw-r--r-- | backend/meson.build | 6 | ||||
-rw-r--r-- | backend/session/logind.c | 10 | ||||
-rw-r--r-- | backend/session/session.c | 2 | ||||
-rw-r--r-- | backend/wayland/output.c | 2 |
4 files changed, 16 insertions, 4 deletions
diff --git a/backend/meson.build b/backend/meson.build index eb8c5d8b..a3cb7b64 100644 --- a/backend/meson.build +++ b/backend/meson.build @@ -28,9 +28,13 @@ if systemd.found() backend_files += files('session/logind.c') endif +if elogind.found() + backend_files += files('session/logind.c') +endif + lib_wlr_backend = static_library( 'wlr_backend', backend_files, include_directories: wlr_inc, - dependencies: [wayland_server, egl, gbm, libinput, systemd, wlr_protos], + dependencies: [wayland_server, egl, gbm, libinput, systemd, elogind, wlr_protos], ) diff --git a/backend/session/logind.c b/backend/session/logind.c index 3b237360..42b48e94 100644 --- a/backend/session/logind.c +++ b/backend/session/logind.c @@ -5,8 +5,6 @@ #include <stdlib.h> #include <string.h> #include <errno.h> -#include <systemd/sd-bus.h> -#include <systemd/sd-login.h> #include <unistd.h> #include <sys/sysmacros.h> #include <sys/stat.h> @@ -15,6 +13,14 @@ #include <wlr/backend/session/interface.h> #include <wlr/util/log.h> +#ifdef HAS_SYSTEMD + #include <systemd/sd-bus.h> + #include <systemd/sd-login.h> +#elif HAS_ELOGIND + #include <elogind/sd-bus.h> + #include <elogind/sd-login.h> +#endif + enum { DRM_MAJOR = 226 }; const struct session_impl session_logind; diff --git a/backend/session/session.c b/backend/session/session.c index c9bc1397..cfa617f6 100644 --- a/backend/session/session.c +++ b/backend/session/session.c @@ -18,6 +18,8 @@ extern const struct session_impl session_direct; static const struct session_impl *impls[] = { #ifdef HAS_SYSTEMD &session_logind, +#elif HAS_ELOGIND + &session_logind, #endif &session_direct, NULL, diff --git a/backend/wayland/output.c b/backend/wayland/output.c index e5079001..3e673bcc 100644 --- a/backend/wayland/output.c +++ b/backend/wayland/output.c @@ -7,7 +7,7 @@ #include <sys/types.h> #include <sys/mman.h> #include <wayland-client.h> -#include <GLES3/gl3.h> +#include <GLES2/gl2.h> #include <wlr/interfaces/wlr_output.h> #include <wlr/util/log.h> #include "backend/wayland.h" |