{
 "app_id": "com.sweethome3d.Sweethome3d",
 "source_url": "https://raw.githubusercontent.com/flathub/com.sweethome3d.Sweethome3d/master/com.sweethome3d.Sweethome3d.json",
 "runtime": "org.freedesktop.Platform",
 "runtime_version": "25.08",
 "sdk": "org.freedesktop.Sdk",
 "finish_args": [
  "--share=ipc",
  "--socket=cups",
  "--socket=pulseaudio",
  "--socket=x11",
  "--device=dri",
  "--filesystem=home"
 ],
 "module_count": 2,
 "fetched_at": "2026-09-17T16:08:49.930678+00:00",
 "manifest": {
  "app-id": "com.sweethome3d.Sweethome3d",
  "runtime": "org.freedesktop.Platform",
  "runtime-version": "25.08",
  "sdk": "org.freedesktop.Sdk",
  "command": "SweetHome3D",
  "finish-args": [
   "--share=ipc",
   "--socket=x11",
   "--socket=pulseaudio",
   "--socket=cups",
   "--device=dri",
   "--filesystem=home"
  ],
  "modules": [
   {
    "name": "cups",
    "buildsystem": "autotools",
    "config-opts": [
     "--localstatedir=/var",
     "--with-rundir=/var/run/cups",
     "--with-domainsocket=/var/run/cups/cups.sock",
     "--without-systemd",
     "--disable-dbus",
     "--disable-pam",
     "--with-dnssd=no",
     "--without-rcdir"
    ],
    "cleanup": [
     "/bin",
     "/sbin/cupsaccept",
     "/sbin/cupsctl",
     "/sbin/cupsd",
     "/sbin/cupsdisable",
     "/sbin/cupsenable",
     "/sbin/cupsfilter",
     "/sbin/cupsreject",
     "/sbin/lpadmin",
     "/sbin/lpinfo",
     "/sbin/lpmove",
     "/etc",
     "/include",
     "/lib/cups",
     "/lib/libcupsimage*",
     "/share"
    ],
    "sources": [
     {
      "type": "archive",
      "url": "https://github.com/OpenPrinting/cups/releases/download/v2.4.19/cups-2.4.19-source.tar.gz",
      "sha256": "820984b12a67f98705785aae2dd1347fe0ac097828001d4583ff64574aed6389"
     },
     {
      "type": "patch",
      "path": "cups-disable-desktop-dir.patch"
     }
    ]
   },
   {
    "name": "sweethome3d",
    "buildsystem": "simple",
    "build-commands": [
     "mkdir -p /app/lib/",
     "cp -r ./SweetHome3D/ /app/lib/sweethome3d/",
     "mkdir -p /app/bin/",
     "gcc -o get-scale get-scale.c `pkg-config --libs --cflags gtk+-3.0`",
     "mv get-scale /app/bin/",
     "install -m755 launcher.sh /app/bin/SweetHome3D",
     "sh patch-jre-print.sh",
     "install -m0644 -D ./SweetHome3D/SweetHome3DIcon.png /app/share/icons/hicolor/256x256/apps/${FLATPAK_ID}.png",
     "install -Dm644 com.sweethome3d.Sweethome3d.desktop /app/share/applications/com.sweethome3d.Sweethome3d.desktop",
     "install -Dm644 com.sweethome3d.Sweethome3d.metainfo.xml /app/share/metainfo/com.sweethome3d.Sweethome3d.metainfo.xml",
     "mkdir -p /app/share/mime/packages/",
     "install -m644 -p -t /app/share/mime/packages com.sweethome3d.Sweethome3d.mime.xml",
     "update-mime-database /app/share/mime"
    ],
    "sources": [
     {
      "type": "archive",
      "only-arches": [
       "x86_64"
      ],
      "sha256": "53487eed09650d5cd4310733e3ec80434633ed9df372793acd6fab2c319c2322",
      "url": "https://downloads.sourceforge.net/project/sweethome3d/SweetHome3D/SweetHome3D-7.5/SweetHome3D-7.5-linux-x64.tgz",
      "dest": "SweetHome3D",
      "x-checker-data": {
       "type": "html",
       "url": "https://www.sweethome3d.com/history.jsp",
       "version-pattern": "</a>Version \n        ([\\d\\.-]*), ",
       "url-template": "https://downloads.sourceforge.net/project/sweethome3d/SweetHome3D/SweetHome3D-$version/SweetHome3D-$version-linux-x64.tgz"
      }
     },
     {
      "type": "patch",
      "path": "0001-Force-Java2D-to-use-OpenGL.patch"
     },
     {
      "type": "patch",
      "path": "0001-Use-get-scale-to-apply-a-scaling-factor.patch"
     },
     {
      "type": "file",
      "path": "com.sweethome3d.Sweethome3d.desktop"
     },
     {
      "type": "file",
      "path": "com.sweethome3d.Sweethome3d.metainfo.xml"
     },
     {
      "type": "file",
      "path": "com.sweethome3d.Sweethome3d.mime.xml"
     },
     {
      "type": "file",
      "path": "launcher.sh"
     },
     {
      "type": "file",
      "path": "get-scale.c"
     },
     {
      "type": "file",
      "path": "patch-jre-print.sh"
     }
    ]
   }
  ]
 }
}