From 8c8b6f60476eb4ab2ad847953e54712ca3ac755a Mon Sep 17 00:00:00 2001 From: Holden Date: Fri, 19 Jul 2024 12:25:00 -0400 Subject: [PATCH] CI: Add Flatpak Workflow --- .github/workflows/flatpak.yml | 25 +++++++++++ .../flatpack/org.mavlink.qgroundcontrol.yml | 43 +++++++++++++++++++ 2 files changed, 68 insertions(+) create mode 100644 .github/workflows/flatpak.yml create mode 100644 deploy/flatpack/org.mavlink.qgroundcontrol.yml diff --git a/.github/workflows/flatpak.yml b/.github/workflows/flatpak.yml new file mode 100644 index 00000000000..5b79bc7204c --- /dev/null +++ b/.github/workflows/flatpak.yml @@ -0,0 +1,25 @@ +name: Flatpak + +on: + push: + branches: [master] + pull_request: + +jobs: + flatpak: + name: "Flatpak" + runs-on: ubuntu-latest + container: + image: bilelmoussaoui/flatpak-github-actions:gnome-47 + options: --privileged + strategy: + matrix: + arch: [x86_64] + fail-fast: false + steps: + - uses: actions/checkout@v4 + - uses: flatpak/flatpak-github-actions/flatpak-builder@v6 + with: + bundle: palette.flatpak + manifest-path: org.gnome.zbrown.Palette.yml + cache-key: flatpak-builder-${{ github.sha }} diff --git a/deploy/flatpack/org.mavlink.qgroundcontrol.yml b/deploy/flatpack/org.mavlink.qgroundcontrol.yml new file mode 100644 index 00000000000..3856fd294a6 --- /dev/null +++ b/deploy/flatpack/org.mavlink.qgroundcontrol.yml @@ -0,0 +1,43 @@ +app-id: org.mavlink.qgroundcontrol +runtime: org.kde.Platform +runtime-version: "6.7" +sdk: org.kde.Sdk +command: QGroundControl +rename-appdata-file: org.mavlink.qgroundcontrol.metainfo.xml + +finish-args: + - --socket=wayland + - --socket=fallback-x11 + - --socket=pulseaudio + - --device=all # allow access USB Serial + - --share=ipc + - --share=network + - --filesystem=home + - --filesystem=xdg-run/gvfs # GVfs + - --filesystem=/media # automount via udisks + - --filesystem=/run/udev:ro # enables firmware upload & auto connecting + +build-options: + build-args: + - "--share=network" + +modules: + - name: QGroundControl + sources: + - type: git + url: https://github.com/mavlink/qgroundcontrol.git + commit: 2aefff18582141bebba650a0d033f8c9a5d3457c + buildsystem: cmake-ninja + builddir: true + config-opts: + - -D BUILD_SHARED_LIBS=OFF + - -D OpenGL_GL_PREFERENCE=GLVND + - -D BUILD_TESTING=OFF + cleanup: + - /include + - /bin/dbf* + - /bin/shp* + - /lib/cmake + - /share/shapelib + - '*.a' + - '*.cmake'