From c125323a8e2d826372230968e5aa6aa844a78ea5 Mon Sep 17 00:00:00 2001 From: Marko Lindqvist Date: Fri, 5 Aug 2022 05:11:40 +0300 Subject: [PATCH 30/32] flatpak: Build modpack installer flatpak See osdn #45104 Signed-off-by: Marko Lindqvist --- Makefile.am | 1 + flatpak/build_flatpak.sh | 4 +++- flatpak/org.freeciv.mp.gtk3.yml | 22 ++++++++++++++++++++++ 3 files changed, 26 insertions(+), 1 deletion(-) create mode 100644 flatpak/org.freeciv.mp.gtk3.yml diff --git a/Makefile.am b/Makefile.am index cfe4a3b5df..2e4156b1ac 100644 --- a/Makefile.am +++ b/Makefile.am @@ -83,6 +83,7 @@ EXTRA_DIST = autogen.sh \ meson_options.txt \ flatpak/build_flatpak.sh \ flatpak/org.freeciv.gtk322.yml \ + flatpak/org.freeciv.mp.gtk3.yml \ scripts/mapimg2anim \ scripts/setup_auth_server.sh \ scripts/replace \ diff --git a/flatpak/build_flatpak.sh b/flatpak/build_flatpak.sh index 163c857ef2..ea9cbfaba1 100755 --- a/flatpak/build_flatpak.sh +++ b/flatpak/build_flatpak.sh @@ -3,8 +3,10 @@ FCVER=$(../fc_version) if ! 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 build-update-repo repo || - ! flatpak build-bundle repo "freeciv-gtk3.22-${FCVER}.flatpak" org.freeciv.gtk322 + ! 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 then echo "FAILURE" >&2 exit 1 diff --git a/flatpak/org.freeciv.mp.gtk3.yml b/flatpak/org.freeciv.mp.gtk3.yml new file mode 100644 index 0000000000..a1ee3c93be --- /dev/null +++ b/flatpak/org.freeciv.mp.gtk3.yml @@ -0,0 +1,22 @@ +app-id: org.freeciv.mp.gtk3 +runtime: org.freedesktop.Platform +runtime-version: '21.08' +sdk: org.freedesktop.Sdk +command: freeciv-mp-gtk3 +rename-icon: freeciv-modpack +modules: + - name: freeciv-mp-gtk3 + 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-fcmp=gtk3 --disable-client --disable-server --disable-freeciv-manual && make -j$(nproc) && make install + sources: + - type: dir + path: .. +finish-args: + - --socket=wayland + - --socket=fallback-x11 + - --share=network + - --filesystem=~/.freeciv:create -- 2.35.1