2018-02-10 13:13:06 +01:00
|
|
|
gnome = import('gnome')
|
|
|
|
zathura_resources = gnome.compile_resources(
|
|
|
|
'resources',
|
|
|
|
'zathura.gresource.xml',
|
|
|
|
c_name: 'zathura_resources',
|
|
|
|
dependencies: files('zathura.css_t', 'org.pwmt.zathura.xml')
|
|
|
|
)
|
|
|
|
|
|
|
|
install_data('org.pwmt.zathura.xml', install_dir: dbusinterfacesdir)
|
2020-07-19 10:37:03 +02:00
|
|
|
install_data('org.pwmt.zathura.svg', install_dir: join_paths(datadir, 'icons', 'hicolor', 'scalable', 'apps'))
|
2018-11-27 22:30:18 +01:00
|
|
|
|
2018-12-09 23:25:55 +01:00
|
|
|
rsvg_convert = find_program('rsvg-convert', required: get_option('convert-icon'), native: true)
|
2018-11-27 22:30:18 +01:00
|
|
|
if rsvg_convert.found()
|
|
|
|
foreach width : [16, 32, 64, 128, 256]
|
|
|
|
subdir('icon-@0@'.format(width))
|
|
|
|
endforeach
|
|
|
|
endif
|
2018-02-25 18:39:03 +01:00
|
|
|
|
|
|
|
i18n = import('i18n')
|
2021-09-12 16:11:35 +02:00
|
|
|
podir = join_paths(meson.project_source_root(), 'po')
|
2018-02-25 19:59:36 +01:00
|
|
|
|
2018-02-25 19:49:08 +01:00
|
|
|
desktop = i18n.merge_file('desktop',
|
2018-02-25 19:47:50 +01:00
|
|
|
input: 'org.pwmt.zathura.desktop.in',
|
|
|
|
output: 'org.pwmt.zathura.desktop',
|
2018-02-25 18:39:03 +01:00
|
|
|
install: true,
|
|
|
|
install_dir: desktopdir,
|
2018-02-25 19:59:36 +01:00
|
|
|
po_dir: podir,
|
2018-02-25 18:39:03 +01:00
|
|
|
type: 'desktop'
|
|
|
|
)
|
2018-02-25 19:49:08 +01:00
|
|
|
|
2018-02-25 19:59:36 +01:00
|
|
|
appdata = i18n.merge_file('appdata',
|
|
|
|
input: 'org.pwmt.zathura.appdata.xml.in',
|
|
|
|
output: 'org.pwmt.zathura.appdata.xml',
|
|
|
|
install: true,
|
|
|
|
install_dir: metainfodir,
|
|
|
|
po_dir: podir,
|
|
|
|
)
|
|
|
|
|
2018-11-27 22:42:25 +01:00
|
|
|
desktop_file_validate = find_program('desktop-file-validate', required: get_option('tests'), native: true)
|
2018-02-25 19:49:08 +01:00
|
|
|
if desktop_file_validate.found()
|
|
|
|
test('validate-desktop',
|
|
|
|
desktop_file_validate,
|
|
|
|
args: [desktop.full_path()]
|
|
|
|
)
|
|
|
|
endif
|
2018-02-25 19:59:36 +01:00
|
|
|
|
2018-11-27 22:42:25 +01:00
|
|
|
appstream_util = find_program('appstream-util', required: get_option('tests'), native: true)
|
2018-02-25 19:59:36 +01:00
|
|
|
if appstream_util.found()
|
|
|
|
test('validate-appdata',
|
|
|
|
appstream_util,
|
2018-11-27 22:40:15 +01:00
|
|
|
args: ['validate-relax', '--nonet', appdata.full_path()]
|
2018-02-25 19:59:36 +01:00
|
|
|
)
|
|
|
|
endif
|
2018-05-22 09:21:14 +02:00
|
|
|
|
|
|
|
conf_data = configuration_data()
|
|
|
|
conf_data.set('PLUGINDIR', join_paths(prefix, plugindir))
|
|
|
|
bash_completion = configure_file(
|
|
|
|
input: 'bash-completion.in',
|
|
|
|
output: 'zathura',
|
|
|
|
configuration: conf_data
|
|
|
|
)
|
2018-05-22 14:55:34 +02:00
|
|
|
zsh_completion = configure_file(
|
|
|
|
input: 'zsh-completion.in',
|
|
|
|
output: '_zathura',
|
|
|
|
configuration: conf_data
|
|
|
|
)
|
2019-07-02 19:17:06 +02:00
|
|
|
fish_completion = configure_file(
|
|
|
|
input: 'fish-completion.in',
|
|
|
|
output: 'zathura.fish',
|
|
|
|
configuration: conf_data
|
|
|
|
)
|
2018-05-22 09:21:14 +02:00
|
|
|
|
2020-01-22 03:39:00 +01:00
|
|
|
bash_comp = dependency('bash-completion', required: false)
|
|
|
|
if bash_comp.found()
|
|
|
|
bash_compdir = bash_comp.get_pkgconfig_variable('completionsdir')
|
|
|
|
else
|
|
|
|
bash_compdir = join_paths(datadir, 'bash-completion', 'completions')
|
|
|
|
endif
|
|
|
|
|
|
|
|
fish_comp = dependency('fish', required: false)
|
|
|
|
if fish_comp.found()
|
|
|
|
fish_compdir = fish_comp.get_pkgconfig_variable('completionsdir')
|
|
|
|
else
|
2020-01-22 03:39:26 +01:00
|
|
|
fish_compdir = join_paths(datadir, 'fish', 'vendor_completions.d')
|
2020-01-22 03:39:00 +01:00
|
|
|
endif
|
|
|
|
|
|
|
|
install_data(bash_completion, install_dir: bash_compdir)
|
2019-08-11 04:29:04 +02:00
|
|
|
install_data(zsh_completion, install_dir: join_paths(datadir, 'zsh', 'site-functions'))
|
2020-01-22 03:39:00 +01:00
|
|
|
install_data(fish_completion, install_dir: fish_compdir)
|