app-id: org.metamuffin.hurrycurry.client runtime: org.freedesktop.Platform runtime-version: "24.08" sdk: org.freedesktop.Sdk sdk-extensions: - org.freedesktop.Sdk.Extension.node20 command: hurrycurry finish-args: - --share=ipc - --socket=wayland - --socket=fallback-x11 - --socket=pulseaudio - --device=all - --share=network build-options: arch: x86_64: env: # Only enable link-time optimization when targeting x86_64 # (causes issues on other architectures) SCONS_FLAGS_EXTRA: use_lto=yes env: BUILD_NAME: hurrycurry modules: - shared-modules/glu/glu-9.json - name: scons buildsystem: simple cleanup: ["*"] sources: - type: archive sha256: e2d78aa56e4646e5dbaf50c0758c6d1e4b0418464d8d6d07a09beb6cf257538f url: https://downloads.sourceforge.net/project/scons/scons/4.9.1/SCons-4.9.1.tar.gz build-commands: - python3 -m pip install --no-index --no-build-isolation --prefix=/app . - name: godot buildsystem: simple sources: - type: archive sha256: ddbd6527cdb3ddb02910b383301a5c9117b1c33c777ef1c86d1b1eea43dcb651 url: https://github.com/godotengine/godot/releases/download/4.4.1-stable/godot-4.4.1-stable.tar.xz - type: file path: custom.py build-commands: - python3 /app/bin/scons $SCONS_FLAGS_EXTRA profile=custom.py target=editor -j "$FLATPAK_BUILDER_N_JOBS" - python3 /app/bin/scons $SCONS_FLAGS_EXTRA profile=custom.py target=template_release -j "$FLATPAK_BUILDER_N_JOBS" - install -Dm755 bin/godot.linuxbsd.template_release.* /app/bin/godot - install -Dm755 bin/godot.linuxbsd.editor.* /app/bin/godot-editor - name: rust buildsystem: simple build-options: strip: false no-debuginfo: true cleanup: ["*"] sources: - type: archive only-arches: - aarch64 dest: rust url: https://static.rust-lang.org/dist/2025-05-31/rust-nightly-aarch64-unknown-linux-gnu.tar.xz sha256: ac7e6732407f4a57cb26a525e116e83a2324395b1f376c327d27335509c5ed1d - type: archive only-arches: - x86_64 dest: rust url: https://static.rust-lang.org/dist/2025-05-31/rust-nightly-x86_64-unknown-linux-gnu.tar.xz sha256: 4089fb3f7c7e2c4220bb9b4596532328fe9e7142b166d7d5431962fa37787392 build-commands: - cd rust && ./install.sh --prefix=/app/sdk/rust-nightly --without=rust-docs --without=rust-docs-json-preview --disable-ldconfig --verbose - name: hurrycurry buildsystem: simple build-options: append-path: /usr/lib/sdk/node20/bin:/app/sdk/rust-nightly/bin env: CARGO_HOME: /run/build/hurrycurry/cargo sources: - type: archive sha256: 27140aeb642f3edb04169b6102e720bfe965d2d082ce7c0d5ac5f8579715cad8 url: https://codeberg.org/hurrycurry/hurrycurry/archive/81bad4ada7a75cb337524962971f26682005f100.tar.gz - generated-sources.json build-commands: - cargo --offline fetch --manifest-path Cargo.toml - make JSR=node -C data - make DATA_SEARCH_PATH=/app/share/hurrycurry/data CARGOFLAGS=--offline -C server discover server - make -C client assets - install -Dm755 target/release/hurrycurry-server /app/bin/hurrycurry-server - install -Dm755 target/release/hurrycurry-discover /app/bin/hurrycurry-discover - install -dD /app/share/hurrycurry/data/recipes - install -dD /app/share/hurrycurry/data/maps - cp -v data/index.yaml /app/share/hurrycurry/data/index.yaml - cp -v data/book.json /app/share/hurrycurry/data/book.json - cp -vr data/recipes/*.yaml /app/share/hurrycurry/data/recipes - cp -vr data/maps/*.yaml /app/share/hurrycurry/data/maps - godot-editor --headless --export-pack wasm32-unknown-unknown /app/share/hurrycurry/client.pck client/project.godot - rm /app/bin/godot-editor - > for size in {32,64,128,256,512}; do ffmpeg -i client/icons/main.png -vf scale=${size}:${size} "$size.png" install -Dm644 "$size.png" "/app/share/icons/hicolor/${size}x${size}/apps/org.metamuffin.hurrycurry.client.png" done - name: hurrycurry-dist buildsystem: simple sources: - type: archive sha256: 10a6988875eac447104d220a380dd5de9874a004889be2ff0be552623c3a927d url: https://codeberg.org/hurrycurry/hurrycurry-dist-extra/archive/v2.3.5.tar.gz - type: script dest-filename: hurrycurry commands: - exec /app/bin/godot --main-pack /app/share/hurrycurry/client.pck $@ build-commands: - python translate.py - install -Dm755 hurrycurry /app/bin/hurrycurry - install -Dm644 org.metamuffin.hurrycurry.client.desktop /app/share/applications/org.metamuffin.hurrycurry.client.desktop - install -Dm644 org.metamuffin.hurrycurry.client.metainfo.xml /app/share/metainfo/org.metamuffin.hurrycurry.client.metainfo.xml