diff options
Diffstat (limited to 'meson.build')
-rw-r--r-- | meson.build | 26 |
1 files changed, 5 insertions, 21 deletions
diff --git a/meson.build b/meson.build index bb60bc89..bffbe312 100644 --- a/meson.build +++ b/meson.build | |||
@@ -32,8 +32,6 @@ if is_freebsd | |||
32 | add_project_arguments('-D_C11_SOURCE', language: 'c') | 32 | add_project_arguments('-D_C11_SOURCE', language: 'c') |
33 | endif | 33 | endif |
34 | 34 | ||
35 | swayidle_deps = [] | ||
36 | |||
37 | jsonc = dependency('json-c', version: '>=0.13') | 35 | jsonc = dependency('json-c', version: '>=0.13') |
38 | pcre = dependency('libpcre') | 36 | pcre = dependency('libpcre') |
39 | wlroots = dependency('wlroots', fallback: ['wlroots', 'wlroots']) | 37 | wlroots = dependency('wlroots', fallback: ['wlroots', 'wlroots']) |
@@ -48,6 +46,7 @@ pango = dependency('pango') | |||
48 | pangocairo = dependency('pangocairo') | 46 | pangocairo = dependency('pangocairo') |
49 | gdk_pixbuf = dependency('gdk-pixbuf-2.0', required: false) | 47 | gdk_pixbuf = dependency('gdk-pixbuf-2.0', required: false) |
50 | pixman = dependency('pixman-1') | 48 | pixman = dependency('pixman-1') |
49 | libevdev = dependency('libevdev') | ||
51 | libinput = dependency('libinput', version: '>=1.6.0') | 50 | libinput = dependency('libinput', version: '>=1.6.0') |
52 | libpam = cc.find_library('pam', required: false) | 51 | libpam = cc.find_library('pam', required: false) |
53 | crypt = cc.find_library('crypt', required: false) | 52 | crypt = cc.find_library('crypt', required: false) |
@@ -67,6 +66,7 @@ endif | |||
67 | conf_data.set10('HAVE_GDK_PIXBUF', gdk_pixbuf.found()) | 66 | conf_data.set10('HAVE_GDK_PIXBUF', gdk_pixbuf.found()) |
68 | conf_data.set10('HAVE_SYSTEMD', systemd.found()) | 67 | conf_data.set10('HAVE_SYSTEMD', systemd.found()) |
69 | conf_data.set10('HAVE_ELOGIND', elogind.found()) | 68 | conf_data.set10('HAVE_ELOGIND', elogind.found()) |
69 | conf_data.set10('HAVE_TRAY', get_option('enable-tray') and (systemd.found() or elogind.found())) | ||
70 | 70 | ||
71 | if not systemd.found() and not elogind.found() | 71 | if not systemd.found() and not elogind.found() |
72 | 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') |
@@ -86,7 +86,6 @@ if scdoc.found() | |||
86 | 'sway/sway-output.5.scd', | 86 | 'sway/sway-output.5.scd', |
87 | 'swaylock/swaylock.1.scd', | 87 | 'swaylock/swaylock.1.scd', |
88 | 'swaymsg/swaymsg.1.scd', | 88 | 'swaymsg/swaymsg.1.scd', |
89 | 'swayidle/swayidle.1.scd', | ||
90 | 'swaynag/swaynag.1.scd', | 89 | 'swaynag/swaynag.1.scd', |
91 | 'swaynag/swaynag.5.scd', | 90 | 'swaynag/swaynag.5.scd', |
92 | ] | 91 | ] |
@@ -108,13 +107,7 @@ if scdoc.found() | |||
108 | endforeach | 107 | endforeach |
109 | endif | 108 | endif |
110 | 109 | ||
111 | # If prefix is '/usr', sysconfdir will be explicitly set to '/etc' by Meson to | 110 | add_project_arguments('-DSYSCONFDIR="/@0@"'.format(join_paths(prefix, sysconfdir)), language : 'c') |
112 | # enforce FHS compliance, so we should look for configs there as well. | ||
113 | if prefix == '/usr' | ||
114 | add_project_arguments('-DSYSCONFDIR="/@0@"'.format(sysconfdir), language : 'c') | ||
115 | else | ||
116 | add_project_arguments('-DSYSCONFDIR="/@0@/@1@"'.format(prefix, sysconfdir), language : 'c') | ||
117 | endif | ||
118 | 111 | ||
119 | version = get_option('sway-version') | 112 | version = get_option('sway-version') |
120 | if version != '' | 113 | if version != '' |
@@ -152,21 +145,13 @@ subdir('swaymsg') | |||
152 | subdir('client') | 145 | subdir('client') |
153 | subdir('swaybg') | 146 | subdir('swaybg') |
154 | subdir('swaybar') | 147 | subdir('swaybar') |
155 | subdir('swayidle') | ||
156 | subdir('swaynag') | 148 | subdir('swaynag') |
157 | subdir('swaylock') | 149 | subdir('swaylock') |
158 | 150 | ||
159 | config = configuration_data() | 151 | config = configuration_data() |
160 | config.set('datadir', join_paths(prefix, datadir)) | 152 | config.set('datadir', join_paths(prefix, datadir)) |
161 | config.set('prefix', prefix) | 153 | config.set('prefix', prefix) |
162 | 154 | config.set('sysconfdir', join_paths(prefix, sysconfdir)) | |
163 | # If prefix is '/usr', sysconfdir will be explicitly set to '/etc' by Meson to | ||
164 | # enforce FHS compliance, so we should look for configs there as well. | ||
165 | if prefix == '/usr' | ||
166 | config.set('sysconfdir', sysconfdir) | ||
167 | else | ||
168 | config.set('sysconfdir', join_paths(prefix, sysconfdir)) | ||
169 | endif | ||
170 | 155 | ||
171 | configure_file( | 156 | configure_file( |
172 | configuration: config, | 157 | configuration: config, |
@@ -226,7 +211,7 @@ endif | |||
226 | if (get_option('bash-completions')) | 211 | if (get_option('bash-completions')) |
227 | bash_files = files( | 212 | bash_files = files( |
228 | 'completions/bash/sway', | 213 | 'completions/bash/sway', |
229 | 'completions/bash/swayidle', | 214 | 'completions/bash/swaybar', |
230 | 'completions/bash/swaylock', | 215 | 'completions/bash/swaylock', |
231 | 'completions/bash/swaymsg', | 216 | 'completions/bash/swaymsg', |
232 | ) | 217 | ) |
@@ -238,7 +223,6 @@ endif | |||
238 | if (get_option('fish-completions')) | 223 | if (get_option('fish-completions')) |
239 | fish_files = files( | 224 | fish_files = files( |
240 | 'completions/fish/sway.fish', | 225 | 'completions/fish/sway.fish', |
241 | 'completions/fish/swayidle.fish', | ||
242 | 'completions/fish/swaylock.fish', | 226 | 'completions/fish/swaylock.fish', |
243 | 'completions/fish/swaymsg.fish', | 227 | 'completions/fish/swaymsg.fish', |
244 | 'completions/fish/swaynag.fish', | 228 | 'completions/fish/swaynag.fish', |