meson.build 1.45 KB
Newer Older
1
project('five-or-more', ['c', 'vala'],
Robert Roth's avatar
Robert Roth committed
2
  version: '3.32.0',
3 4
  meson_version: '>= 0.43.0',
  license: 'GPLv2'
Ruxandra Simion's avatar
Ruxandra Simion committed
5 6 7 8 9 10 11 12 13 14 15 16 17
)

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

locale_dir = join_paths(get_option('prefix'), get_option('localedir'))
po_dir = join_paths(meson.source_root(), 'po')
data_dir = join_paths (get_option ('prefix'), get_option ('datadir'))
pkgdata_dir = join_paths (data_dir, 'five-or-more')

# Dependencies
glib_min_version = '2.32'

ruxandraS's avatar
ruxandraS committed
18
gee_dep = dependency('gee-0.8')
19 20 21 22 23 24
gio_dep = dependency('gio-2.0', version: '>= ' + glib_min_version)
glib_dep = dependency('glib-2.0', version: '>= ' + glib_min_version)
gmodule_export_dep = dependency('gmodule-export-2.0')
gtk_dep = dependency('gtk+-3.0', version: '>= 3.20.0')
libgnome_games_support_dep = dependency('libgnome-games-support-1')
librsvg_dep = dependency('librsvg-2.0', version: '>= 2.32.0')
Ruxandra Simion's avatar
Ruxandra Simion committed
25 26

# Libraries
27 28
cc = meson.get_compiler('c')
libmath_dep = cc.find_library('m')
Ruxandra Simion's avatar
Ruxandra Simion committed
29 30 31 32 33

# Configuration
conf = configuration_data()

conf.set_quoted('GETTEXT_PACKAGE', meson.project_name())
ruxandraS's avatar
ruxandraS committed
34
conf.set_quoted('LOCALE_DIRECTORY', locale_dir)
Ruxandra Simion's avatar
Ruxandra Simion committed
35 36 37 38 39 40
conf.set_quoted('DATA_DIRECTORY', pkgdata_dir)
conf.set_quoted('VERSION', meson.project_version())

configure_file(output: 'config.h', configuration: conf)
config_h_dir = include_directories('.')

41 42 43 44 45 46
add_project_arguments([
    '-include', 'config.h'
  ],
  language: 'c'
)

Ruxandra Simion's avatar
Ruxandra Simion committed
47 48 49 50 51 52 53 54
# Extra scripts
meson.add_install_script('meson_post_install.py')

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