forked from elementary/monitor
-
Notifications
You must be signed in to change notification settings - Fork 0
/
meson.build
72 lines (55 loc) · 2.07 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
project('com.github.stsdc.monitor', 'vala', 'c', version: '0.12.0')
# these are Meson modules
gnome = import('gnome')
i18n = import('i18n')
sass = find_program('sassc')
# common dirs
prefix = get_option('prefix')
datadir = join_paths(prefix, get_option('datadir'))
libdir = join_paths(prefix, get_option('libdir'))
icondir = join_paths(datadir, 'icons', 'hicolor')
vapidir = meson.current_source_dir() / 'vapi/'
add_global_arguments('-DGETTEXT_PACKAGE="@0@"'.format(meson.project_name()), language:'c')
add_project_arguments(['--vapidir', vapidir], language: 'vala')
add_project_arguments(['-DWNCK_I_KNOW_THIS_IS_UNSTABLE', '-w'], language: 'c')
livechart_proj = subproject('live-chart')
# subprojects should be skipped: https://mesonbuild.com/Release-notes-for-0-58-0.html#skip-subprojects-installation
# needs meson 0.58.0
# elementary_stylesheet = subproject('stylesheet')
app_dependencies = [
dependency('granite', version: '>= 5.2.0'),
dependency('glib-2.0'),
dependency('gtk+-3.0'),
dependency('gee-0.8'),
dependency('gio-2.0'),
dependency('gobject-2.0'),
dependency('libgtop-2.0'),
dependency('libwnck-3.0'),
dependency('libhandy-1', version: '>=0.90.0'),
dependency('gdk-x11-3.0'),
dependency('x11'),
dependency('udisks2'),
livechart_proj.get_variable('livechart_dep'),
meson.get_compiler('c').find_library('m', required : false),
meson.get_compiler('vala').find_library('posix'),
meson.get_compiler('c').find_library('XNVCtrl'),
meson.get_compiler('c').find_library('X11'),
meson.get_compiler('vala').find_library('libxnvctrl', dirs: vapidir),
]
config_data = configuration_data()
config_data.set('GETTEXT_PACKAGE', meson.project_name())
subdir('data')
config_data.set('VCS_TAG', '@VCS_TAG@')
project_config = vcs_tag(
input: configure_file(
input: 'src/Conf.vala.in',
output: 'Conf.vala.in',
configuration: config_data
),
output: 'Conf.vala',
command: ['git', 'describe', '--tags', '--dirty']
)
subdir('src')
# Add in a post install script
meson.add_install_script('meson/post_install.py')
subdir('po')