build: package remus as a Flatpak for SteamOS
SteamOS has a read-only root filesystem, so a Flatpak is the way to install it. The build is offline from vendored crates. make flatpak-bundle writes one file to copy to a Steam machine, and make sdk-check runs the checks inside the SDK for hosts without the GStreamer development files.
This commit is contained in:
@@ -0,0 +1,47 @@
|
||||
id: me.anshorei.Fettleshed.Remus
|
||||
runtime: org.freedesktop.Platform
|
||||
runtime-version: '26.08'
|
||||
sdk: org.freedesktop.Sdk
|
||||
sdk-extensions:
|
||||
- org.freedesktop.Sdk.Extension.rust-stable
|
||||
command: remus
|
||||
|
||||
finish-args:
|
||||
- --share=network
|
||||
- --share=ipc
|
||||
- --socket=wayland
|
||||
- --socket=fallback-x11
|
||||
- --socket=pulseaudio
|
||||
# GPU rendering and gamepads (evdev). --device=input would be narrower but
|
||||
# needs Flatpak 1.15.6, which not every SteamOS release ships.
|
||||
- --device=all
|
||||
|
||||
build-options:
|
||||
append-path: /usr/lib/sdk/rust-stable/bin
|
||||
env:
|
||||
CARGO_HOME: /run/build/remus/cargo-home
|
||||
|
||||
modules:
|
||||
- name: remus
|
||||
buildsystem: simple
|
||||
build-commands:
|
||||
# Crates come from the vendor directory `make flatpak` prepares: the build has no network.
|
||||
- mkdir -p .cargo
|
||||
- printf '[source.crates-io]\nreplace-with = "vendored"\n[source.vendored]\ndirectory = "vendor"\n' > .cargo/config.toml
|
||||
- cargo build --release --offline --locked
|
||||
- install -Dm755 target/release/remus /app/bin/remus
|
||||
- install -Dm644 flatpak/me.anshorei.Fettleshed.Remus.desktop /app/share/applications/me.anshorei.Fettleshed.Remus.desktop
|
||||
- install -Dm644 flatpak/me.anshorei.Fettleshed.Remus.metainfo.xml /app/share/metainfo/me.anshorei.Fettleshed.Remus.metainfo.xml
|
||||
- install -Dm644 flatpak/me.anshorei.Fettleshed.Remus.svg /app/share/icons/hicolor/scalable/apps/me.anshorei.Fettleshed.Remus.svg
|
||||
- install -Dm644 LICENSE /app/share/licenses/me.anshorei.Fettleshed.Remus/LICENSE
|
||||
sources:
|
||||
- type: dir
|
||||
path: ..
|
||||
skip:
|
||||
- target
|
||||
- .git
|
||||
- .worklane
|
||||
- .flatpak-builder
|
||||
- type: dir
|
||||
path: ../target/flatpak/vendor
|
||||
dest: vendor
|
||||
Reference in New Issue
Block a user