aboutsummaryrefslogtreecommitdiff
path: root/backend
diff options
context:
space:
mode:
Diffstat (limited to 'backend')
-rw-r--r--backend/backend.c2
-rw-r--r--backend/meson.build5
2 files changed, 6 insertions, 1 deletions
diff --git a/backend/backend.c b/backend/backend.c
index c67be617..58ac756e 100644
--- a/backend/backend.c
+++ b/backend/backend.c
@@ -94,6 +94,7 @@ struct wlr_backend *wlr_backend_autocreate(struct wl_display *display) {
}
}
+#ifdef WLR_HAS_X11_BACKEND
const char *x11_display = getenv("DISPLAY");
if (x11_display) {
struct wlr_backend *x11_backend =
@@ -101,6 +102,7 @@ struct wlr_backend *wlr_backend_autocreate(struct wl_display *display) {
wlr_multi_backend_add(backend, x11_backend);
return backend;
}
+#endif
// Attempt DRM+libinput
struct wlr_session *session = wlr_session_create(display);
diff --git a/backend/meson.build b/backend/meson.build
index c0ed76f1..a74ea024 100644
--- a/backend/meson.build
+++ b/backend/meson.build
@@ -24,7 +24,6 @@ backend_files = files(
'wayland/output.c',
'wayland/registry.c',
'wayland/wl_seat.c',
- 'x11/backend.c',
)
backend_deps = [
@@ -50,6 +49,10 @@ if conf_data.get('WLR_HAS_SYSTEMD', false)
backend_deps += systemd
endif
+if conf_data.get('WLR_HAS_X11_BACKEND', false)
+ backend_files += files('x11/backend.c')
+endif
+
if conf_data.get('WLR_HAS_ELOGIND', false)
backend_files += files('session/logind.c')
backend_deps += elogind