forked from wayland-tablet/libinput
-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
meson.build
118 lines (111 loc) · 3.27 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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
# Sphinx build
sphinx = find_program('sphinx-build-3', 'sphinx-build', required : false)
if not sphinx.found()
error('Program "sphinx-build" not found or not executable. Try building with -Ddocumentation=false')
endif
sphinx_config = configuration_data()
sphinx_config.set('PROJECT_NAME', meson.project_name())
sphinx_config.set('PROJECT_VERSION', meson.project_version())
sphinx_conf_py = configure_file(input : 'conf.py.in',
output : 'conf.py',
configuration : sphinx_config,
install : false)
src_extra = [
# dot drawings
'dot/seats-sketch.gv',
'dot/seats-sketch-libinput.gv',
'dot/libinput-stack-wayland.gv',
'dot/libinput-stack-xorg.gv',
'dot/libinput-stack-gnome.gv',
'dot/evemu.gv',
'dot/libinput-record.gv',
# svgs
'svg/button-debouncing-wave-diagram.svg',
'svg/button-scrolling.svg',
'svg/clickfinger.svg',
'svg/clickfinger-distance.svg',
'svg/edge-scrolling.svg',
'svg/gesture-2fg-ambiguity.svg',
'svg/palm-detection.svg',
'svg/pinch-gestures.svg',
'svg/pinch-gestures-softbuttons.svg',
'svg/ptraccel-linear.svg',
'svg/ptraccel-low-dpi.svg',
'svg/ptraccel-touchpad.svg',
'svg/ptraccel-trackpoint.svg',
'svg/software-buttons.svg',
'svg/software-buttons-conditions.svg',
'svg/software-buttons-thumbpress.svg',
'svg/software-buttons-visualized.svg',
'svg/swipe-gestures.svg',
'svg/tablet-axes.svg',
'svg/tablet-cintiq24hd-modes.svg',
'svg/tablet-interfaces.svg',
'svg/tablet-intuos-modes.svg',
'svg/tablet-left-handed.svg',
'svg/tablet-out-of-bounds.svg',
'svg/tablet.svg',
'svg/tap-n-drag.svg',
'svg/thumb-detection.svg',
'svg/top-software-buttons.svg',
'svg/touchscreen-gestures.svg',
'svg/trackpoint-delta-illustration.svg',
'svg/twofinger-scrolling.svg',
]
src_rst = files(
'absolute-axes.rst',
'absolute-coordinate-ranges.rst',
'architecture.rst',
'building.rst',
'button_debouncing.rst',
'clickpad-softbuttons.rst',
'contributing.rst',
'device-configuration-via-udev.rst',
'device-quirks.rst',
'faqs.rst',
'gestures.rst',
'middle-button-emulation.rst',
'normalization-of-relative-motion.rst',
'palm-detection.rst',
'pointer-acceleration.rst',
'reporting-bugs.rst',
'scrolling.rst',
'seats.rst',
'switches.rst',
't440-support.rst',
'tablet-support.rst',
'tapping.rst',
'test-suite.rst',
'timestamps.rst',
'tools.rst',
'touchpad-jumping-cursors.rst',
'touchpad-pressure.rst',
'touchpad-jitter.rst',
'touchpads.rst',
'trackpoints.rst',
'what-is-libinput.rst',
'features.rst',
'development.rst',
'troubleshooting.rst',
'configuration.rst',
)
src_sphinx = custom_target('sphinx-sources',
input : [src_rst, src_extra],
output : '.',
command : [prg_install, '-t', '@OUTDIR@', '@INPUT@'],
build_by_default: true)
index_page = vcs_tag(command : ['git', 'log', '-1', '--format=%h'],
fallback : 'unknown',
input : 'index.rst',
output : 'index.rst',
replace_string: '__GIT_VERSION__')
# drop '-a' once we are happy with all this
# do not use -j, it breaks on Ubuntu
sphinx_output_dir = 'Documentation'
custom_target('sphinx',
input : [ sphinx_conf_py, index_page ] + src_rst + src_extra,
output : [ sphinx_output_dir ],
command : [ sphinx, '-q', '-b', 'html', '-a',
meson.current_build_dir(), sphinx_output_dir],
depends: [ src_sphinx ],
build_by_default : true)