-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmeson.build
76 lines (65 loc) · 2.06 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
project('hr.from.josipantolis.sage', 'vala', 'c')
i18n = import('i18n')
add_global_arguments('-DGETTEXT_PACKAGE="@0@"'.format (meson.project_name()), language:'c')
gnome = import('gnome')
gresource = gnome.compile_resources(
'gresource',
'data' / 'gresource.xml',
source_dir: 'data'
)
executable(
meson.project_name(),
gresource,
'src' / 'Application.vala',
'src' / 'Game.vala',
'src' / 'Hint.vala',
'src' / 'MainWindow.vala',
'src' / 'Store.vala',
'src' / 'Widgets' / 'BoardGrid.vala',
'src' / 'Widgets' / 'ColorPickerBox.vala',
'src' / 'Widgets' / 'Colors.vala',
'src' / 'Widgets' / 'EndGameDialog.vala',
'src' / 'Widgets' / 'GuessRow.vala',
'src' / 'Widgets' / 'GuessToggle.vala',
'src' / 'Widgets' / 'HeaderBar.vala',
'src' / 'Widgets' / 'HelpPopover.vala',
'src' / 'Widgets' / 'HintsGrid.vala',
'src' / 'Widgets' / 'ValidateRowButton.vala',
dependencies: [
dependency('gee-0.8'),
dependency('gtk4'),
dependency('granite-7')
],
install: true
)
icon_sizes = ['16', '24', '32', '48', '64', '128']
foreach i : icon_sizes
install_data(
'data' / 'icons' / i + '.svg',
install_dir: get_option('datadir') / 'icons' / 'hicolor' / i + 'x' + i / 'apps',
rename: meson.project_name() + '.svg'
)
install_data(
'data' / 'icons' / i + '.svg',
install_dir: get_option('datadir') / 'icons' / 'hicolor' / i + 'x' + i + '@2' / 'apps',
rename: meson.project_name() + '.svg'
)
endforeach
i18n.merge_file(
input: 'data' / 'sage.desktop.in',
output: meson.project_name() + '.desktop',
po_dir: meson.source_root() / 'po',
type: 'desktop',
install: true,
install_dir: get_option('datadir') / 'applications'
)
i18n.merge_file(
input: 'data' / 'sage.appdata.xml.in',
output: meson.project_name() + '.appdata.xml',
po_dir: meson.source_root() / 'po',
install: true,
install_dir: get_option('datadir') / 'metainfo'
)
subdir('po')
meson.add_install_script('meson/post_install.py')
subdir('data')