{
 "app_id": "io.unom.Punktfunk",
 "source_url": "https://raw.githubusercontent.com/punktfunk/punktfunk/main/packaging/flatpak/io.unom.Punktfunk.yml",
 "runtime": "org.gnome.Platform",
 "runtime_version": "50",
 "sdk": "org.gnome.Sdk",
 "finish_args": [
  "--socket=wayland",
  "--socket=fallback-x11",
  "--share=ipc",
  "--filesystem=/tmp/.X11-unix:ro",
  "--device=all",
  "--filesystem=/run/udev:ro",
  "--filesystem=xdg-run/pipewire-0",
  "--socket=pulseaudio",
  "--share=network",
  "--filesystem=~/.config/punktfunk:create",
  "--env=ENABLE_GAMESCOPE_WSI=1",
  "--env=GAMESCOPE_WAYLAND_DISPLAY=gamescope-0",
  "--filesystem=xdg-run/gamescope-0"
 ],
 "module_count": 4,
 "fetched_at": "2026-09-21T19:41:32.784328+00:00",
 "manifest": {
  "app-id": "io.unom.Punktfunk",
  "runtime": "org.gnome.Platform",
  "runtime-version": "50",
  "sdk": "org.gnome.Sdk",
  "sdk-extensions": [
   "org.freedesktop.Sdk.Extension.rust-stable",
   "org.freedesktop.Sdk.Extension.llvm20"
  ],
  "command": "punktfunk-client",
  "cleanup": [
   "/include",
   "/lib/pkgconfig",
   "/lib/cmake",
   "/share/aclocal",
   "/man",
   "/share/man",
   "*.a",
   "*.la"
  ],
  "finish-args": [
   "--socket=wayland",
   "--socket=fallback-x11",
   "--share=ipc",
   "--filesystem=/tmp/.X11-unix:ro",
   "--device=all",
   "--filesystem=/run/udev:ro",
   "--filesystem=xdg-run/pipewire-0",
   "--socket=pulseaudio",
   "--share=network",
   "--filesystem=~/.config/punktfunk:create",
   "--env=ENABLE_GAMESCOPE_WSI=1",
   "--env=GAMESCOPE_WAYLAND_DISPLAY=gamescope-0",
   "--filesystem=xdg-run/gamescope-0"
  ],
  "build-options": {
   "append-path": "/usr/lib/sdk/rust-stable/bin:/usr/lib/sdk/llvm20/bin",
   "env": {
    "PKG_CONFIG_PATH": "/app/lib/pkgconfig:/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/lib/pkgconfig",
    "LIBCLANG_PATH": "/usr/lib/sdk/llvm20/lib",
    "RUSTFLAGS": "-C link-arg=-fuse-ld=mold"
   },
   "arch": {
    "aarch64": {
     "env": {
      "PKG_CONFIG_PATH": "/app/lib/pkgconfig:/usr/lib/aarch64-linux-gnu/pkgconfig:/usr/lib/pkgconfig"
     }
    }
   }
  },
  "modules": [
   {
    "name": "sdl3",
    "buildsystem": "cmake-ninja",
    "config-opts": [
     "-DCMAKE_BUILD_TYPE=Release",
     "-DSDL_SHARED=ON",
     "-DSDL_STATIC=OFF",
     "-DSDL_HIDAPI=ON",
     "-DSDL_TEST_LIBRARY=OFF",
     "-DSDL_EXAMPLES=OFF"
    ],
    "sources": [
     {
      "type": "archive",
      "url": "https://github.com/libsdl-org/SDL/releases/download/release-3.4.10/SDL3-3.4.10.tar.gz",
      "sha256": "12b34280415ec8418c864408b93d008a20a6530687ee613d60bfbd20411f2785",
      "x-checker-data": {
       "type": "anitya",
       "project-id": 4974,
       "stable-only": true,
       "url-template": "https://github.com/libsdl-org/SDL/releases/download/release-$version/SDL3-$version.tar.gz"
      }
     }
    ],
    "cleanup": [
     "/bin",
     "/include",
     "/lib/cmake",
     "/lib/pkgconfig"
    ]
   },
   {
    "name": "vulkan-headers",
    "buildsystem": "cmake-ninja",
    "sources": [
     {
      "type": "archive",
      "url": "https://github.com/KhronosGroup/Vulkan-Headers/archive/refs/tags/vulkan-sdk-1.4.313.0.tar.gz",
      "sha256": "20743c99a96c07290f24377360e7a12bdd2c465ba202e0c7ef2ec25d446cf61d"
     }
    ],
    "cleanup": [
     "*"
    ]
   },
   {
    "name": "gamescope-wsi-layer",
    "buildsystem": "simple",
    "build-commands": [
     "cp -r subprojects/packagefiles/glm/. subprojects/glm/",
     "cp -r subprojects/packagefiles/stb/. subprojects/stb/",
     "meson setup _build --prefix=/app --libdir=lib --wrap-mode=nodownload -Denable_gamescope=false -Denable_gamescope_wsi_layer=true -Denable_tests=false -Denable_openvr_support=false",
     "ninja -C _build",
     "ninja -C _build install"
    ],
    "sources": [
     {
      "type": "git",
      "url": "https://github.com/ValveSoftware/gamescope.git",
      "commit": "5fb8dce4a09d0a68d097b9faf9513782106bc843"
     },
     {
      "type": "git",
      "url": "https://github.com/g-truc/glm.git",
      "commit": "0af55ccecd98d4e5a8d1fad7de25ba429d60e863",
      "dest": "subprojects/glm"
     },
     {
      "type": "git",
      "url": "https://github.com/nothings/stb.git",
      "commit": "5736b15f7ea0ffb08dd38af21067c314d6a3aae9",
      "dest": "subprojects/stb"
     }
    ],
    "cleanup": [
     "/include",
     "/lib/pkgconfig",
     "/share/gamescope"
    ]
   },
   {
    "name": "punktfunk-client",
    "buildsystem": "simple",
    "build-options": {
     "env": {
      "CARGO_HOME": "/run/build/punktfunk-client/cargo",
      "CARGO_NET_OFFLINE": "true",
      "SKIA_BINARIES_URL": "file:///run/build/punktfunk-client/skia-binaries.tar.gz"
     }
    },
    "build-commands": [
     "sed -i '\\#\"clients/windows\",#d' Cargo.toml",
     "sed -i '\\#\"crates/punktfunk-setup-win\",#d' Cargo.toml",
     "python3 packaging/flatpak/prune-windows-toml.py crates/pf-client-core/Cargo.toml",
     "cargo --offline build --release -p punktfunk-client-linux -p punktfunk-client-session -p punktfunk-cli",
     "install -Dm0755 target/release/punktfunk-client ${FLATPAK_DEST}/bin/punktfunk-client",
     "install -Dm0755 target/release/punktfunk-session ${FLATPAK_DEST}/bin/punktfunk-session",
     "install -Dm0755 target/release/punktfunk ${FLATPAK_DEST}/bin/punktfunk",
     "install -Dm0644 packaging/flatpak/io.unom.Punktfunk.desktop ${FLATPAK_DEST}/share/applications/io.unom.Punktfunk.desktop",
     "install -Dm0644 packaging/linux/io.unom.Punktfunk.Console.desktop ${FLATPAK_DEST}/share/applications/io.unom.Punktfunk.Console.desktop",
     "install -Dm0644 packaging/flatpak/io.unom.Punktfunk.metainfo.xml ${FLATPAK_DEST}/share/metainfo/io.unom.Punktfunk.metainfo.xml",
     "install -Dm0644 packaging/linux/icons/hicolor/scalable/apps/io.unom.Punktfunk.svg ${FLATPAK_DEST}/share/icons/hicolor/scalable/apps/io.unom.Punktfunk.svg"
    ],
    "sources": [
     {
      "type": "dir",
      "path": "../.."
     },
     "cargo-sources.json",
     {
      "type": "file",
      "only-arches": [
       "x86_64"
      ],
      "url": "https://github.com/rust-skia/skia-binaries/releases/download/0.99.0/skia-binaries-a25a0fdb7d90429aa2d1-x86_64-unknown-linux-gnu-jpegd-jpege-pdf-textlayout-vulkan.tar.gz",
      "sha256": "158407a4b5ce8738431bb76498be3a44fda770e51d61aac18a0e0e97becdc1de",
      "dest-filename": "skia-binaries.tar.gz"
     },
     {
      "type": "file",
      "only-arches": [
       "aarch64"
      ],
      "url": "https://github.com/rust-skia/skia-binaries/releases/download/0.99.0/skia-binaries-a25a0fdb7d90429aa2d1-aarch64-unknown-linux-gnu-jpegd-jpege-pdf-textlayout-vulkan.tar.gz",
      "sha256": "cf5469d1d963f704cc997f9b3342d11c49b917002361947e5c7bf7dcc3f13534",
      "dest-filename": "skia-binaries.tar.gz"
     }
    ]
   }
  ]
 }
}