68 lines
1.7 KiB
Meson
68 lines
1.7 KiB
Meson
project(
|
|
'media-player',
|
|
'vala',
|
|
version: '0.1.0',
|
|
license: 'GPL-3.0-or-later',
|
|
meson_version: '>= 1.2.0',
|
|
default_options: ['warning_level=1', 'buildtype=debugoptimized', 'c_std=gnu11'],
|
|
)
|
|
|
|
prefix = get_option('prefix')
|
|
libdir = prefix / get_option('libdir')
|
|
datadir = prefix / get_option('datadir')
|
|
|
|
vapi_dir = meson.project_source_root() / 'vapi'
|
|
add_project_arguments(['--vapidir', vapi_dir], language: 'vala')
|
|
|
|
gnome = import('gnome')
|
|
i18n = import('i18n')
|
|
|
|
phosh_dep = dependency('phosh-plugins', version: '>= 0.45')
|
|
quick_setting_plugins_dir = phosh_dep.get_variable('quick_setting_plugins_dir')
|
|
quick_setting_prefs_dir = phosh_dep.get_variable('quick_setting_prefs_dir')
|
|
|
|
common_deps = [
|
|
dependency('gee-0.8'),
|
|
dependency('gio-2.0'),
|
|
dependency('gtk+-3.0'),
|
|
dependency('libphosh-0.45'),
|
|
# For our bundles phosh-0.45 vapi
|
|
dependency('gnome-desktop-3.0'),
|
|
dependency('libnm'),
|
|
]
|
|
|
|
common_c_args = ['-include', 'player-config.h', '-DG_LOG_USE_STRUCTURED']
|
|
|
|
conf = configuration_data()
|
|
conf.set_quoted('G_LOG_DOMAIN', meson.project_name())
|
|
configure_file(output: 'player-config.h', configuration: conf)
|
|
cc = meson.get_compiler('c')
|
|
|
|
c_args = [
|
|
# Disable Vala compiled shitcode warnings
|
|
'-Wno-unused-variable',
|
|
'-Wno-unused-parameter',
|
|
'-Wno-unused-but-set-variable',
|
|
'-Wno-discarded-qualifiers',
|
|
'-Wno-missing-field-initializers',
|
|
'-Wno-unused-function',
|
|
'-Wno-address',
|
|
]
|
|
|
|
project_c_args = []
|
|
foreach arg : c_args
|
|
if cc.has_multi_arguments(arg)
|
|
project_c_args += arg
|
|
endif
|
|
endforeach
|
|
add_project_arguments(project_c_args, language: 'c')
|
|
|
|
subdir('po')
|
|
# The example plugin
|
|
subdir('src')
|
|
|
|
gnome.post_install(
|
|
glib_compile_schemas: true,
|
|
gtk_update_icon_cache: true,
|
|
update_desktop_database: true,
|
|
)
|