summaryrefslogtreecommitdiffstats
path: root/meson.build
diff options
context:
space:
mode:
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build40
1 files changed, 17 insertions, 23 deletions
diff --git a/meson.build b/meson.build
index 6b23b4e3..bb60bc89 100644
--- a/meson.build
+++ b/meson.build
@@ -9,11 +9,17 @@ project(
9 ], 9 ],
10) 10)
11 11
12add_project_arguments('-Wno-unused-parameter', language: 'c') 12add_project_arguments(
13add_project_arguments('-Wno-unused-function', language: 'c') 13 [
14add_project_arguments('-Wno-unused-result', language: 'c') 14 '-DWL_HIDE_DEPRECATED',
15add_project_arguments('-DWL_HIDE_DEPRECATED', language: 'c') 15 '-DWLR_USE_UNSTABLE',
16add_project_arguments('-DWLR_USE_UNSTABLE', language: 'c') 16
17 '-Wno-unused-parameter',
18 '-Wno-unused-result',
19 '-Wundef',
20 ],
21 language: 'c',
22)
17 23
18cc = meson.get_compiler('c') 24cc = meson.get_compiler('c')
19 25
@@ -53,30 +59,18 @@ git = find_program('git', required: false)
53 59
54conf_data = configuration_data() 60conf_data = configuration_data()
55 61
62conf_data.set10('HAVE_XWAYLAND', get_option('enable-xwayland'))
56if get_option('enable-xwayland') 63if get_option('enable-xwayland')
57 conf_data.set('HAVE_XWAYLAND', true)
58 xcb = dependency('xcb') 64 xcb = dependency('xcb')
59else
60 conf_data.set('HAVE_XWAYLAND', false)
61endif
62
63if gdk_pixbuf.found()
64 conf_data.set('HAVE_GDK_PIXBUF', true)
65endif
66
67if systemd.found()
68 conf_data.set('SWAY_IDLE_HAS_SYSTEMD', true)
69 swayidle_deps += systemd
70endif 65endif
71 66
72if elogind.found() 67conf_data.set10('HAVE_GDK_PIXBUF', gdk_pixbuf.found())
73 conf_data.set('SWAY_IDLE_HAS_ELOGIND', true) 68conf_data.set10('HAVE_SYSTEMD', systemd.found())
74 swayidle_deps += elogind 69conf_data.set10('HAVE_ELOGIND', elogind.found())
75endif
76 70
77if not systemd.found() and not elogind.found() 71if not systemd.found() and not elogind.found()
78 warning('The sway binary must be setuid when compiled without (e)logind') 72 warning('The sway binary must be setuid when compiled without (e)logind')
79 warning('You must do this manually post-install: chmod a+s /path/to/sway') 73 warning('You must do this manually post-install: chmod a+s /path/to/sway')
80endif 74endif
81 75
82scdoc = find_program('scdoc', required: false) 76scdoc = find_program('scdoc', required: false)