-
Notifications
You must be signed in to change notification settings - Fork 1
/
meson.build
52 lines (42 loc) · 1.31 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
project(
'primeindicator',
'vala', 'c',
version: '0.0.1'
)
i18n = import('i18n')
gettext_name = meson.project_name() + '-indicator'
add_global_arguments('-DGETTEXT_PACKAGE="@0@"'.format(gettext_name), language:'c')
wingpanel_dep = dependency('wingpanel-2.0')
indicator_dir_cmd = run_command('pkg-config', 'indicator3-0.4', '--variable=indicatordir')
if indicator_dir_cmd.returncode() != 0
message ('Indicator directory not found')
endif
indicator_dir = indicator_dir_cmd.stdout().strip()
# Other configs
conf = configuration_data()
conf.set_quoted('GETTEXT_PACKAGE', meson.project_name())
conf.set_quoted('AYANATAINDICATORDIR', indicator_dir)
add_global_arguments('-DDATADIR="' + get_option('datadir') + '"', language: 'c')
configure_file(output: 'config.h', configuration: conf)
config_h_dir = include_directories('.')
# Arguments for C
c_args = [
'-include', 'config.h',
'-w'
]
shared_module(
meson.project_name(),
'src/PrimeIndicator.vala',
dependencies: [
dependency('glib-2.0'),
dependency('gobject-2.0'),
dependency('granite'),
dependency('gtk+-3.0'),
meson.get_compiler('vala').find_library('posix'),
wingpanel_dep
],
install: true,
install_dir : wingpanel_dep.get_pkgconfig_variable('indicatorsdir')
)
subdir('data')
subdir('po')