summaryrefslogtreecommitdiff
path: root/meson.build
blob: e35b9abc681b814364068afefe059cf9a4f85fbe (plain)
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
project('gnome-dictionary', 'c',
  version: '41.alpha',
  default_options: [
    'buildtype=debugoptimized',
    'c_std=c99',
    'warning_level=1',
  ],
  license: 'GPL-2.0-or-later',
  meson_version: '>= 0.57.0',
)

gdict_version = meson.project_version().split('.')
gdict_major_version = gdict_version[0].to_int()
gdict_minor_version = gdict_version[1] in ['alpha', 'beta', 'rc'] ? 0 : gdict_version[1].to_int()
gdict_micro_version = 0

gdict_is_devel = gdict_version[1] in ['alpha', 'beta', 'rc']

gdict_prefix = get_option('prefix')
gdict_bindir = gdict_prefix / get_option('bindir')
gdict_libdir = gdict_prefix / get_option('libdir')
gdict_datadir = gdict_prefix / get_option('datadir')
gdict_includedir = gdict_prefix / get_option('includedir')
gdict_libexecdir = gdict_prefix / get_option('libexecdir')
gdict_mandir = gdict_prefix / get_option('mandir')
gdict_sysconfdir = gdict_prefix / get_option('sysconfdir')
gdict_schemadir = gdict_datadir / 'glib-2.0' / 'schemas'
gdict_servicedir = gdict_datadir / 'dbus-1' / 'services'

profile = get_option('profile')
debug = get_option('debug')
optimization = get_option('optimization')
buildtype = get_option('buildtype')
use_ipv6 = get_option('use_ipv6')

if profile == 'devel' or gdict_is_devel
  application_id = 'org.gnome.Dictionary.Devel'
else
  application_id = 'org.gnome.Dictionary'
endif

po_dir = join_paths(meson.current_source_dir(), 'po')

gnome = import('gnome')
i18n = import('i18n')

subdir('src')
subdir('po')
subdir('data')
subdir('help')

# Post-installation
gnome.post_install(
  glib_compile_schemas: true,
  gtk_update_icon_cache: true,
)