UnleashedRecomp/flatpak/io.github.hedge_dev.unleashedrecomp.json
Anirudh Sevugan bbbe22c9d7
try aarch64 support for llvm18
apparently flatpak-builder supports only-arches
for type:file (https://docs.flatpak.org/ko/latest/module-sources.html)
2026-03-20 00:36:20 -05:00

71 lines
2.6 KiB
JSON

{
"id": "io.github.hedge_dev.unleashedrecomp",
"runtime": "org.freedesktop.Platform",
"runtime-version": "25.08",
"sdk": "org.freedesktop.Sdk",
"finish-args": [
"--share=network",
"--socket=wayland",
"--socket=fallback-x11",
"--socket=pulseaudio",
"--device=all",
"--filesystem=host",
"--filesystem=/media",
"--filesystem=/run/media",
"--filesystem=/mnt"
],
"modules": [
{
"name": "llvm",
"buildsystem": "simple",
"build-commands": [
"mkdir -p /usr/lib/sdk/llvm18 llvm/extracted",
"tar -xJf llvm/*.tar.xz -C llvm/extracted",
"tar -xf llvm/extracted/*.tar --strip-components=1 -C /usr/lib/sdk/llvm18/"
],
"sources": [
{
"type": "file",
"url": "https://github.com/llvm/llvm-project/releases/download/llvmorg-18.1.8/clang+llvm-18.1.8-x86_64-linux-gnu-ubuntu-18.04.tar.xz",
"sha256": "54ec30358afcc9fb8aa74307db3046f5187f9fb89fb37064cdde906e062ebf36",
"dest": "llvm",
"only-arches": ["x86_64"]
},
{
"type": "file",
"url": "https://github.com/llvm/llvm-project/releases/download/llvmorg-18.1.8/clang+llvm-18.1.8-aarch64-linux-gnu.tar.xz",
"sha256": "dcaa1bebbfbb86953fdfbdc7f938800229f75ad26c5c9375ef242edad737d999",
"dest": "llvm",
"only-arches": ["aarch64"]
}
],
"cleanup": [ "*" ]
},
{
"name": "UnleashedRecomp",
"buildsystem": "simple",
"build-commands": [
"cmake --preset linux-release -DUNLEASHED_RECOMP_FLATPAK=ON -DSDL2MIXER_VORBIS=VORBISFILE -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DCMAKE_C_COMPILER_LAUNCHER=ccache",
"cmake --build out/build/linux-release --target UnleashedRecomp",
"mkdir -p /app/bin",
"cp out/build/linux-release/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": {
"append-path": "/usr/lib/sdk/llvm18/bin",
"prepend-ld-library-path": "/usr/lib/sdk/llvm18/lib",
"build-args": [
"--share=network"
]
}
}
]
}