{
 "app_id": "net.werwolv.ImHex",
 "source_url": "https://raw.githubusercontent.com/flathub/net.werwolv.ImHex/master/net.werwolv.ImHex.yaml",
 "runtime": "org.freedesktop.Platform",
 "runtime_version": "25.08",
 "sdk": "org.freedesktop.Sdk",
 "finish_args": [
  "--share=network",
  "--share=ipc",
  "--socket=x11",
  "--socket=wayland",
  "--socket=fallback-x11",
  "--device=dri"
 ],
 "module_count": 6,
 "fetched_at": "2026-09-17T16:13:57.050726+00:00",
 "manifest": {
  "app-id": "net.werwolv.ImHex",
  "runtime": "org.freedesktop.Platform",
  "runtime-version": "25.08",
  "sdk": "org.freedesktop.Sdk",
  "command": "imhex",
  "rename-desktop-file": "imhex.desktop",
  "finish-args": [
   "--share=ipc",
   "--share=network",
   "--socket=wayland",
   "--socket=fallback-x11",
   "--device=dri"
  ],
  "modules": [
   {
    "name": "glfw",
    "buildsystem": "cmake-ninja",
    "builddir": true,
    "config-opts": [
     "-DBUILD_SHARED_LIBS=ON",
     "-DGLFW_BUILD_EXAMPLES=OFF",
     "-DGLFW_BUILD_TESTS=OFF",
     "-DGLFW_BUILD_DOCS=OFF"
    ],
    "sources": [
     {
      "type": "archive",
      "url": "https://github.com/glfw/glfw/releases/download/3.4/glfw-3.4.zip",
      "sha256": "b5ec004b2712fd08e8861dc271428f048775200a2df719ccf575143ba749a3e9"
     }
    ],
    "cleanup": [
     "/include",
     "/lib/pkgconfig",
     "/lib/pkgconfig",
     "/lib64/pkgconfig",
     "/lib/cmake",
     "/lib64/cmake"
    ]
   },
   {
    "name": "mbedtls",
    "buildsystem": "cmake-ninja",
    "config-opts": [
     "-DCMAKE_C_FLAGS=-fPIC",
     "-DENABLE_TESTING=OFF",
     "-DENABLE_PROGRAMS=OFF"
    ],
    "sources": [
     {
      "type": "archive",
      "url": "https://github.com/ARMmbed/mbedtls/archive/refs/tags/v3.4.0.tar.gz",
      "sha256": "1b899f355022e8d02c4d313196a0a16af86c5a692456fa99d302915b8cf0320a"
     }
    ],
    "cleanup": [
     "/include",
     "/lib/pkgconfig",
     "/lib64/pkgconfig",
     "/lib/cmake",
     "/lib64/cmake"
    ]
   },
   {
    "name": "yara",
    "buildsystem": "autotools",
    "sources": [
     {
      "type": "git",
      "url": "https://github.com/VirusTotal/yara.git",
      "tag": "v4.3.1",
      "commit": "a6f6ce1d6d74a03c396660db25765f2a794d9e30"
     }
    ],
    "cleanup": [
     "/include",
     "/lib/pkgconfig",
     "/lib64/pkgconfig",
     "/lib/cmake",
     "/lib64/cmake"
    ]
   },
   {
    "name": "libssh2",
    "buildsystem": "cmake-ninja",
    "config-opts": [
     "-DBUILD_SHARED_LIBS=ON",
     "-DENABLE_ZLIB_COMPRESSION=OFF",
     "-DENABLE_MANUAL=OFF",
     "-DENABLE_EXAMPLES=OFF",
     "-DENABLE_TESTING=OFF"
    ],
    "sources": [
     {
      "type": "git",
      "url": "https://github.com/libssh2/libssh2.git",
      "tag": "libssh2-1.11.1",
      "commit": "a312b43325e3383c865a87bb1d26cb52e3292641"
     }
    ],
    "cleanup": [
     "/include",
     "/lib/pkgconfig",
     "/lib64/pkgconfig",
     "/lib/cmake",
     "/lib64/cmake"
    ]
   },
   {
    "name": "md4c",
    "buildsystem": "cmake-ninja",
    "config-opts": [
     "-DBUILD_SHARED_LIBS=ON",
     "-DMD4C_BUILD_TESTS=OFF",
     "-DMD4C_BUILD_EXAMPLES=OFF",
     "-DMD4C_BUILD_DOCS=OFF"
    ],
    "sources": [
     {
      "type": "git",
      "url": "https://github.com/mity/md4c.git",
      "tag": "release-0.5.2",
      "commit": "729e6b8b320caa96328968ab27d7db2235e4fb47"
     }
    ]
   },
   {
    "name": "imhex",
    "buildsystem": "cmake-ninja",
    "builddir": true,
    "build-options": {
     "cxxflags": "-Wno-error=maybe-uninitialized"
    },
    "config-opts": [
     "-DUSE_SYSTEM_CURL=ON",
     "-DUSE_SYSTEM_FMT=ON",
     "-DUSE_SYSTEM_YARA=ON",
     "-DIMHEX_OFFLINE_BUILD=ON",
     "-DIMHEX_STRICT_WARNINGS=OFF",
     "-DCMAKE_INSTALL_LIBDIR=lib",
     "-DCMAKE_INSTALL_RPATH='$ORIGIN/../lib:$ORIGIN/../lib64'"
    ],
    "sources": [
     {
      "type": "git",
      "url": "https://github.com/WerWolv/ImHex.git",
      "tag": "v1.38.1",
      "commit": "76cf8771158012095d3b3ed58cc93c27ccfac7df",
      "x-checker-data": {
       "type": "git",
       "tag-pattern": "^v([\\d.]+)$"
      }
     },
     {
      "type": "git",
      "url": "https://github.com/WerWolv/ImHex-Patterns.git",
      "tag": "ImHex-v1.38.1",
      "commit": "4646e4b9653c8b208024c5285b00f3084684021c",
      "dest": "ImHex-Patterns",
      "x-checker-data": {
       "type": "git",
       "tag-pattern": "^ImHex-v([\\d.]+)$"
      }
     },
     {
      "type": "file",
      "path": "net.werwolv.ImHex.metainfo.xml"
     },
     {
      "type": "file",
      "path": "icon.svg"
     }
    ],
    "post-install": [
     "install -Dm644 ../net.werwolv.ImHex.metainfo.xml ${FLATPAK_DEST}/share/metainfo/net.werwolv.ImHex.metainfo.xml",
     "install -Dm0644 ../icon.svg ${FLATPAK_DEST}/share/icons/hicolor/scalable/apps/${FLATPAK_ID}.svg",
     "desktop-file-edit --set-key=\"Icon\" --set-value=\"${FLATPAK_ID}\" \"${FLATPAK_DEST}/share/applications/imhex.desktop\""
    ]
   }
  ]
 }
}