Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions .github/workflows/validate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,9 @@ jobs:
build-flatpak:
name: Build Flatpak
runs-on: ubuntu-24.04
strategy:
matrix:
preset: ["Flatpak-Debug", "Flatpak-Release"]
env:
FLATPAK_ID: io.github.hedge_dev.unleashedrecomp

Expand All @@ -185,7 +188,7 @@ jobs:
uses: actions/cache@v4
with:
path: /tmp/ccache
key: ccache-${{ runner.os }}
key: ccache-${{ runner.os }}-${{ matrix.preset }}

- name: Prepare Project
run: cp ./private/* ./UnleashedRecompLib/private
Expand All @@ -198,13 +201,13 @@ jobs:
run: |
echo "commit_message=$(git log -1 --pretty=%s)" >> $GITHUB_ENV
export CCACHE_DIR=/tmp/ccache
flatpak-builder --user --force-clean --install-deps-from=flathub --repo=repo --ccache builddir ./flatpak/${{ env.FLATPAK_ID }}.json
flatpak-builder --user --force-clean --install-deps-from=flathub --repo=repo --ccache builddir ./flatpak/${{ env.FLATPAK_ID }}-${{ matrix.preset }}.json
flatpak build-bundle repo ./${{ env.FLATPAK_ID }}.flatpak ${{ env.FLATPAK_ID }} --runtime-repo=https://flathub.org/repo/flathub.flatpakrepo

- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: UnleashedRecomp-Flatpak
name: UnleashedRecomp-${{ matrix.preset }}
path: ./${{ env.FLATPAK_ID }}.flatpak
build-macos:
name: Build macOS
Expand Down
48 changes: 48 additions & 0 deletions flatpak/io.github.hedge_dev.unleashedrecomp-Flatpak-Debug.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
{
"id": "io.github.hedge_dev.unleashedrecomp",
"runtime": "org.freedesktop.Platform",
"runtime-version": "24.08",
"sdk": "org.freedesktop.Sdk",
"sdk-extensions" : [ "org.freedesktop.Sdk.Extension.llvm18" ],
"finish-args": [
"--share=network",
"--socket=wayland",
"--socket=fallback-x11",
"--socket=pulseaudio",
"--device=all",
"--filesystem=host",
"--filesystem=/media",
"--filesystem=/run/media",
"--filesystem=/mnt"
],
"modules": [
{
"name": "UnleashedRecomp",
"buildsystem": "simple",
"build-commands": [
"cmake --preset linux-debug -DUNLEASHED_RECOMP_FLATPAK=ON -DSDL2MIXER_VORBIS=VORBISFILE -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DCMAKE_C_COMPILER_LAUNCHER=ccache",
"cmake --build out/build/linux-debug --target UnleashedRecomp",
"mkdir -p /app/bin",
"cp out/build/linux-debug/UnleashedRecomp/UnleashedRecomp /app/bin/UnleashedRecomp",
"install -Dm644 UnleashedRecompResources/images/game_icon.png /app/share/icons/hicolor/128x128/apps/${FLATPAK_ID}.png",
"install -Dm644 flatpak/io.github.hedge_dev.unleashedrecomp.metainfo.xml /app/share/metainfo/${FLATPAK_ID}.metainfo.xml",
"install -Dm644 flatpak/io.github.hedge_dev.unleashedrecomp.desktop /app/share/applications/${FLATPAK_ID}.desktop"
],
"sources": [
{
"type": "dir",
"path": "../"
}
],
"build-options": {
"no-debuginfo": true,
"strip": false,
"append-path": "/usr/lib/sdk/llvm18/bin",
"prepend-ld-library-path": "/usr/lib/sdk/llvm18/lib",
"build-args": [
"--share=network"
]
}
}
]
}
Loading