From f930d904c8aa0b9a878487a01662c4ed0515fc0a Mon Sep 17 00:00:00 2001 From: Marko Lindqvist Date: Tue, 10 Jan 2023 23:25:33 +0200 Subject: [PATCH 24/24] flatpak: Add gtk4-client flatpak See osdn #46509 Signed-off-by: Marko Lindqvist --- Makefile.am | 1 + flatpak/build_flatpak.sh | 4 +++- flatpak/org.freeciv.gtk4.yml | 23 +++++++++++++++++++++++ 3 files changed, 27 insertions(+), 1 deletion(-) create mode 100644 flatpak/org.freeciv.gtk4.yml diff --git a/Makefile.am b/Makefile.am index 3565afb11c..39897fcbc7 100644 --- a/Makefile.am +++ b/Makefile.am @@ -91,6 +91,7 @@ EXTRA_DIST = autogen.sh \ meson_options.txt \ flatpak/build_flatpak.sh \ flatpak/org.freeciv.gtk322.yml \ + flatpak/org.freeciv.gtk4.yml \ flatpak/org.freeciv.mp.gtk3.yml \ flatpak/org.freeciv.qt.yml \ flatpak/org.freeciv.sdl2.yml \ diff --git a/flatpak/build_flatpak.sh b/flatpak/build_flatpak.sh index 681abcb97d..10c5cace00 100755 --- a/flatpak/build_flatpak.sh +++ b/flatpak/build_flatpak.sh @@ -13,11 +13,13 @@ FCVER=$(../fc_version) -if ! flatpak-builder --user --repo=repo --force-clean build org.freeciv.gtk322.yml || +if ! flatpak-builder --user --repo=repo --force-clean build org.freeciv.gtk4.yml || + ! flatpak-builder --user --repo=repo --force-clean build org.freeciv.gtk322.yml || ! flatpak-builder --user --repo=repo --force-clean build org.freeciv.mp.gtk3.yml || ! flatpak-builder --user --repo=repo --force-clean build org.freeciv.qt.yml || ! flatpak-builder --user --repo=repo --force-clean build org.freeciv.sdl2.yml || ! flatpak build-update-repo repo || + ! flatpak build-bundle repo "freeciv-gtk4-${FCVER}.flatpak" org.freeciv.gtk4 || ! flatpak build-bundle repo "freeciv-gtk3.22-${FCVER}.flatpak" org.freeciv.gtk322 || ! flatpak build-bundle repo "freeciv-mp-gtk3-${FCVER}.flatpak" org.freeciv.mp.gtk3 || ! flatpak build-bundle repo "freeciv-qt-${FCVER}.flatpak" org.freeciv.qt || diff --git a/flatpak/org.freeciv.gtk4.yml b/flatpak/org.freeciv.gtk4.yml new file mode 100644 index 0000000000..5e9f14fee7 --- /dev/null +++ b/flatpak/org.freeciv.gtk4.yml @@ -0,0 +1,23 @@ +app-id: org.freeciv.gtk4 +runtime: org.gnome.Platform +runtime-version: '42' +sdk: org.gnome.Sdk +command: freeciv-gtk4 +rename-icon: freeciv-client +modules: + - name: freeciv-gtk4 + buildsystem: simple + build-commands: + # On git clone, regenerate configure with autogen.sh + - if test -f ./.git && test -x ./autogen.sh ; then ./autogen.sh --no-configure-run ; fi + - mkdir build + - cd build && ../configure --prefix=/app --enable-client=gtk4 --disable-fcmp --disable-freeciv-manual && make -j$(nproc) && make install + sources: + - type: dir + path: .. +finish-args: + - --socket=wayland + - --socket=fallback-x11 + - --share=network + - --socket=pulseaudio + - --filesystem=~/.freeciv:create -- 2.39.0