summaryrefslogtreecommitdiff
path: root/src/weston-launch.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/weston-launch.c')
-rw-r--r--src/weston-launch.c22
1 files changed, 20 insertions, 2 deletions
diff --git a/src/weston-launch.c b/src/weston-launch.c
index d8364c85..56e22b10 100644
--- a/src/weston-launch.c
+++ b/src/weston-launch.c
@@ -50,8 +50,6 @@
#include <grp.h>
#include <security/pam_appl.h>
-#include <xf86drm.h>
-
#ifdef HAVE_SYSTEMD_LOGIN
#include <systemd/sd-login.h>
#endif
@@ -70,6 +68,26 @@
#define MAX_ARGV_SIZE 256
+#ifdef HAVE_LIBDRM
+
+#include <xf86drm.h>
+
+#else
+
+static inline int
+drmDropMaster(int drm_fd)
+{
+ return 0;
+}
+
+static inline int
+drmSetMaster(int drm_fd)
+{
+ return 0;
+}
+
+#endif
+
struct weston_launch {
struct pam_conv pc;
pam_handle_t *ph;