{
 "app_id": "org.duckstation.DuckStation",
 "source_url": "https://raw.githubusercontent.com/RetroDECK/Duckstation/main/scripts/flatpak/org.duckstation.DuckStation.yaml",
 "runtime": "org.kde.Platform",
 "runtime_version": "6.7",
 "sdk": "org.kde.Sdk",
 "finish_args": [
  "--device=all",
  "--allow=bluetooth",
  "--share=network",
  "--share=ipc",
  "--socket=pulseaudio",
  "--talk-name=org.freedesktop.ScreenSaver",
  "--socket=x11",
  "--env=QT_QPA_PLATFORM=xcb"
 ],
 "module_count": 9,
 "fetched_at": "2026-09-20T13:05:32.499340+00:00",
 "manifest": {
  "app-id": "org.duckstation.DuckStation",
  "runtime": "org.kde.Platform",
  "runtime-version": "6.7",
  "sdk": "org.kde.Sdk",
  "sdk-extensions": [
   "org.freedesktop.Sdk.Extension.llvm17"
  ],
  "add-extensions": {
   "org.freedesktop.Platform.ffmpeg-full": {
    "directory": "lib/ffmpeg",
    "version": "23.08",
    "add-ld-path": ".",
    "autodownload": true
   }
  },
  "command": "duckstation-qt",
  "finish-args": [
   "--device=all",
   "--allow=bluetooth",
   "--share=network",
   "--share=ipc",
   "--socket=pulseaudio",
   "--talk-name=org.freedesktop.ScreenSaver",
   "--socket=x11",
   "--env=QT_QPA_PLATFORM=xcb"
  ],
  "modules": [
   "modules/20-sdl2.yaml",
   "modules/21-libbacktrace.yaml",
   "modules/22-shaderc.yaml",
   "modules/23-spirv-cross.yaml",
   "modules/24-cpuinfo.yaml",
   "modules/25-discord-rpc.yaml",
   "modules/26-soundtouch.yaml",
   "modules/27-lunasvg.yaml",
   {
    "name": "duckstation",
    "buildsystem": "cmake-ninja",
    "builddir": true,
    "no-make-install": true,
    "build-options": {
     "strip": false,
     "no-debuginfo": true,
     "cflags": "",
     "cflags-override": true,
     "cxxflags": "",
     "cxxflags-override": true,
     "config-opts": [
      "-DCMAKE_BUILD_TYPE=Release",
      "-DBUILD_TESTS=OFF",
      "-DCMAKE_INTERPROCEDURAL_OPTIMIZATION=ON",
      "-DCMAKE_C_COMPILER=/usr/lib/sdk/llvm17/bin/clang",
      "-DCMAKE_CXX_COMPILER=/usr/lib/sdk/llvm17/bin/clang++",
      "-DCMAKE_EXE_LINKER_FLAGS_INIT=-fuse-ld=lld",
      "-DCMAKE_MODULE_LINKER_FLAGS_INIT=-fuse-ld=lld",
      "-DCMAKE_SHARED_LINKER_FLAGS_INIT=-fuse-ld=lld"
     ]
    },
    "sources": [
     {
      "type": "dir",
      "path": "../.."
     }
    ],
    "post-install": [
     "cp -a bin \"${FLATPAK_DEST}\"",
     "install -Dm644 \"${FLATPAK_BUILDER_BUILDDIR}/scripts/org.duckstation.DuckStation.png\" \"${FLATPAK_DEST}/share/icons/hicolor/512x512/apps/org.duckstation.DuckStation.png\"",
     "install -Dm644 \"${FLATPAK_BUILDER_BUILDDIR}/scripts/org.duckstation.DuckStation.desktop\" \"${FLATPAK_DEST}/share/applications/org.duckstation.DuckStation.desktop\"",
     "install -Dm644 \"${FLATPAK_BUILDER_BUILDDIR}/scripts/flatpak/org.duckstation.DuckStation.metainfo.xml\" \"${FLATPAK_DEST}/share/metainfo/org.duckstation.DuckStation.metainfo.xml\"",
     "mkdir -p \"${FLATPAK_DEST}/lib/ffmpeg\""
    ]
   }
  ]
 }
}