-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmeson.build
55 lines (50 loc) · 1.2 KB
/
meson.build
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
project(
'stage',
'c',
version: '0.1',
license: 'MIT',
meson_version: '>=0.59.0',
default_options: [
'c_std=c11',
'warning_level=2',
'werror=true',
],
)
add_project_arguments(
[
'-DWLR_USE_UNSTABLE',
'-Wundef',
'-Wno-unused-parameter',
'-Wno-error=uninitialized',
],
language: 'c',
)
wl_protocol_dir = dependency('wayland-protocols', version: '>=1.32').get_variable('pkgdatadir')
protocols_being_used = [
[wl_protocol_dir, 'stable/xdg-shell/xdg-shell.xml'],
]
headers_for_protocols_being_used = []
foreach protocol : protocols_being_used
xml = join_paths(protocol)
headers_for_protocols_being_used += generator(
find_program('wayland-scanner'),
output: '@[email protected]',
arguments: ['server-header', '@INPUT@', '@OUTPUT@'],
).process(xml)
endforeach
incdir = include_directories('conf')
executable(
meson.project_name(),
'stage.c',
include_directories : incdir,
dependencies: [
dependency('wlroots', version: '>= 0.17.1', fallback: ['wlroots', 'wlroots']),
dependency('wayland-server'),
dependency('xkbcommon'),
dependency('libinput'),
declare_dependency(
sources: headers_for_protocols_being_used,
),
],
install: true,
)