app-id: dev.koljam.solarxy runtime: org.freedesktop.Platform runtime-version: '24.08' sdk: org.freedesktop.Sdk sdk-extensions: - org.freedesktop.Sdk.Extension.rust-stable command: solarxy finish-args: # Display: Wayland with X11 fallback - --socket=wayland - --socket=fallback-x11 - --share=ipc # GPU access (Vulkan via Mesa shipped in the runtime) - --device=dri # File picking goes through xdg-desktop-portal — no broad filesystem # access needed. rfd 0.15 uses the portal on Linux when running under # Flatpak. Verify after first build; if portal isn't picked up, # add `--filesystem=home:ro` as a fallback. # Rust SDK extension paths and offline cargo build environment. build-options: append-path: /usr/lib/sdk/rust-stable/bin build-args: - --share=network # cargo-sources.json supplies all crates; this # is only used during the one-off `cargo # vendor`-style population in dev. The # production Flathub build uses the offline # generated-sources flow below and does NOT # share network. env: CARGO_HOME: /run/build/solarxy/cargo modules: - name: solarxy buildsystem: simple build-commands: # Build only the GUI binary. The CLI is distributed via Homebrew / # cargo-dist shell installer; Flatpak isn't a sensible delivery # channel for terminal tools. The root `solarxy` crate is always-GUI # and has no feature flags — a bare `--bin solarxy` is sufficient. - cargo --offline build --release --bin solarxy - install -Dm755 target/release/solarxy /app/bin/solarxy # Desktop entry, icon, and AppStream metainfo - install -Dm644 packaging/flatpak/dev.koljam.solarxy.desktop /app/share/applications/dev.koljam.solarxy.desktop - install -Dm644 res/bundle/solarxy-256.png /app/share/icons/hicolor/256x256/apps/dev.koljam.solarxy.png - install -Dm644 res/bundle/solarxy-512.png /app/share/icons/hicolor/512x512/apps/dev.koljam.solarxy.png - install -Dm644 res/bundle/solarxy-1024.png /app/share/icons/hicolor/1024x1024/apps/dev.koljam.solarxy.png - install -Dm644 packaging/flatpak/dev.koljam.solarxy.metainfo.xml /app/share/metainfo/dev.koljam.solarxy.metainfo.xml # The license and the ported-source notices. The GPL says its text # travels with every copy, and a Flatpak is a copy; the notices carry # the same obligation from the work they attribute. `share/licenses` # is where distributions look for both. - install -Dm644 LICENSE /app/share/licenses/dev.koljam.solarxy/LICENSE - install -Dm644 THIRD-PARTY-NOTICES.md /app/share/licenses/dev.koljam.solarxy/THIRD-PARTY-NOTICES.md sources: # Source tree at the workspace root. Flathub will replace this with # an `archive` entry pointing at the GitHub release tarball + SHA256 # during the auto-bump (see .github/workflows/flathub-bump.yml). - type: dir path: ../.. # Vendored crate sources. Generated by packaging/flatpak/generate-sources.sh # using flatpak-builder-tools/cargo/flatpak-cargo-generator.py. - cargo-sources.json