aboutsummaryrefslogtreecommitdiff
path: root/meson.build
diff options
context:
space:
mode:
authorFurkan Sahin <furkan-dev@proton.me>2018-09-28 12:18:54 +0200
committerFurkan Sahin <furkan-dev@proton.me>2018-09-28 12:18:54 +0200
commit2343b99b7c423184e66eefec7f3ae7be95d16536 (patch)
treeed2d195ac03609bdb1b3132d1ef748ad59132e8a /meson.build
parent5fdf7a55eaa9a6eeaa4357ea8fa268ba61d62c15 (diff)
Add support for building swaylock without PAM
This involves setuid'ing swaylock, which then forks and drops perms on the parent process. The child process remains root and listens on a pipe for requests to validate passwords against /etc/shadow.
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build10
1 files changed, 6 insertions, 4 deletions
diff --git a/meson.build b/meson.build
index 76eaff20..de6573ea 100644
--- a/meson.build
+++ b/meson.build
@@ -74,6 +74,11 @@ if elogind.found()
swayidle_deps += elogind
endif
+if not systemd.found() and not elogind.found()
+ warning('The sway binary must be setuid when compiled without (e)logind')
+ warning('You must do this manually post-install: chmod a+s /path/to/sway')
+endif
+
scdoc = find_program('scdoc', required: false)
if scdoc.found()
@@ -139,10 +144,7 @@ subdir('swaybg')
subdir('swaybar')
subdir('swayidle')
subdir('swaynag')
-
-if libpam.found()
- subdir('swaylock')
-endif
+subdir('swaylock')
config = configuration_data()
config.set('sysconfdir', join_paths(prefix, sysconfdir))