-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmeson.build
55 lines (48 loc) · 1.25 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('wayboard', 'c',
version : '0.0.0',
license : 'GPL3',
)
add_project_arguments(
[
'-Wno-unused-parameter',
],
language: 'c',
)
wayland_protocols = dependency('wayland-protocols')
wayland_scanner = dependency('wayland-scanner', native: true)
wl_scanner = find_program(wayland_scanner.get_variable('wayland_scanner'), native: true)
wl_proto_dir = wayland_protocols.get_variable('pkgdatadir')
wl_proto_xml = [
wl_proto_dir + '/stable/xdg-shell/xdg-shell.xml',
]
wl_proto_header = []
wl_proto_src = []
foreach proto : wl_proto_xml
wl_proto_header += custom_target(
proto.underscorify() + '-header',
input: proto,
output: '@BASENAME@.h',
command: [wl_scanner, 'client-header', '@INPUT@', '@OUTPUT@'],
)
wl_proto_src += custom_target(
proto.underscorify() + '-src',
input: proto,
output: '@BASENAME@.c',
command: [wl_scanner, 'private-code', '@INPUT@', '@OUTPUT@'],
)
endforeach
cc = meson.get_compiler('c')
executable('wayboard',
wl_proto_src, wl_proto_header,
'wayboard.c',
dependencies: [
dependency('fcft'),
dependency('libinput'),
dependency('libudev'),
cc.find_library('rt'),
dependency('libconfig'),
dependency('pixman-1'),
dependency('wayland-client'),
],
install: true,
)