From a12e9509333770a4a6e176f18bb089f298c8d6de Mon Sep 17 00:00:00 2001 From: Marko Lindqvist Date: Sat, 26 Nov 2022 05:43:59 +0200 Subject: [PATCH 33/33] Meson: Generate and install metainfo files See osdn #44095 Signed-off-by: Marko Lindqvist --- meson.build | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) diff --git a/meson.build b/meson.build index 0b4af5be1c..f153829ca7 100644 --- a/meson.build +++ b/meson.build @@ -1026,6 +1026,15 @@ install_data( install_dir : join_paths(get_option('prefix'), 'share/applications') ) +custom_target('mi_server', + input: 'bootstrap/org.freeciv.server.metainfo.xml.in', + output: '@BASENAME@', + command: [sh_exe, files('bootstrap/generate_metainfo.sh'), + '@OUTPUT@', + meson.project_build_root(), 'development'], + install: true, + install_dir: join_paths(get_option('datadir'), 'metainfo')) + nations = [ 'abkhaz', 'aborigines', @@ -2715,6 +2724,15 @@ install_data( install_dir : join_paths(get_option('prefix'), 'share/applications') ) +custom_target('mi_gtk322', + input: 'bootstrap/org.freeciv.gtk322.metainfo.xml.in', + output: '@BASENAME@', + command: [sh_exe, files('bootstrap/generate_metainfo.sh'), + '@OUTPUT@', + meson.project_build_root(), 'development'], + install: true, + install_dir: join_paths(get_option('datadir'), 'metainfo')) + endif if get_option('clients').contains('gtk4') @@ -2794,6 +2812,15 @@ install_data( install_dir : join_paths(get_option('prefix'), 'share/applications') ) +custom_target('mi_gtk4', + input: 'bootstrap/org.freeciv.gtk4.metainfo.xml.in', + output: '@BASENAME@', + command: [sh_exe, files('bootstrap/generate_metainfo.sh'), + '@OUTPUT@', + meson.project_build_root(), 'development'], + install: true, + install_dir: join_paths(get_option('datadir'), 'metainfo')) + endif if get_option('qtver') == 'qt6' @@ -3040,6 +3067,15 @@ install_data( install_dir : join_paths(get_option('prefix'), 'share/applications') ) +custom_target('mi_qt', + input: 'bootstrap/org.freeciv.qt.metainfo.xml.in', + output: '@BASENAME@', + command: [sh_exe, files('bootstrap/generate_metainfo.sh'), + '@OUTPUT@', + meson.project_build_root(), 'development'], + install: true, + install_dir: join_paths(get_option('datadir'), 'metainfo')) + endif if get_option('clients').contains('sdl2') @@ -3149,6 +3185,15 @@ install_data( install_dir : join_paths(get_option('prefix'), 'share/applications') ) +custom_target('mi_sdl2', + input: 'bootstrap/org.freeciv.sdl2.metainfo.xml.in', + output: '@BASENAME@', + command: [sh_exe, files('bootstrap/generate_metainfo.sh'), + '@OUTPUT@', + meson.project_build_root(), 'development'], + install: true, + install_dir: join_paths(get_option('datadir'), 'metainfo')) + endif if get_option('clients').contains('stub') @@ -3239,6 +3284,15 @@ install_data( install_dir : join_paths(get_option('prefix'), 'share/applications') ) +custom_target('mi_mp_gtk3', + input: 'bootstrap/org.freeciv.mp.gtk3.metainfo.xml.in', + output: '@BASENAME@', + command: [sh_exe, files('bootstrap/generate_metainfo.sh'), + '@OUTPUT@', + meson.project_build_root(), 'development'], + install: true, + install_dir: join_paths(get_option('datadir'), 'metainfo')) + endif @@ -3266,6 +3320,15 @@ install_data( install_dir : join_paths(get_option('prefix'), 'share/applications') ) +custom_target('mi_mp_gtk4', + input: 'bootstrap/org.freeciv.mp.gtk4.metainfo.xml.in', + output: '@BASENAME@', + command: [sh_exe, files('bootstrap/generate_metainfo.sh'), + '@OUTPUT@', + meson.project_build_root(), 'development'], + install: true, + install_dir: join_paths(get_option('datadir'), 'metainfo')) + endif if get_option('fcmp').contains('qt') @@ -3300,6 +3363,15 @@ install_data( install_dir : join_paths(get_option('prefix'), 'share/applications') ) +custom_target('mi_mp_qt', + input: 'bootstrap/org.freeciv.mp.qt.metainfo.xml.in', + output: '@BASENAME@', + command: [sh_exe, files('bootstrap/generate_metainfo.sh'), + '@OUTPUT@', + meson.project_build_root(), 'development'], + install: true, + install_dir: join_paths(get_option('datadir'), 'metainfo')) + endif if get_option('fcmp').contains('cli') @@ -3405,6 +3477,15 @@ install_data( install_dir : join_paths(get_option('prefix'), 'share/applications') ) +custom_target('mi_ruledit', + input: 'bootstrap/org.freeciv.ruledit.metainfo.xml.in', + output: '@BASENAME@', + command: [sh_exe, files('bootstrap/generate_metainfo.sh'), + '@OUTPUT@', + meson.project_build_root(), 'development'], + install: true, + install_dir: join_paths(get_option('datadir'), 'metainfo')) + endif executable('freeciv-manual', -- 2.35.1