Move to YAML based Flatpak manifest

This commit is contained in:
AFCMS 2024-05-16 16:04:33 +02:00
parent b53ebaaebd
commit fc9a13bf9d
No known key found for this signature in database
GPG Key ID: 8720389A25B652E3
3 changed files with 57 additions and 54 deletions

View File

@ -45,7 +45,7 @@ jobs:
with:
arch: x86_64
bundle: ${{ env.FILE_NAME }}
manifest-path: net.minetest.minetest.json
manifest-path: net.minetest.minetest.yaml
cache-key: flatpak-builder-${{ github.sha }}
restore-cache: ${{ (github.event_name == 'workflow_dispatch' && inputs.use_cache) || !startsWith(github.ref, 'refs/tags/') }}
upload-artifact: true

View File

@ -1,53 +0,0 @@
{
"$schema": "https://raw.githubusercontent.com/flatpak/flatpak-builder/main/data/flatpak-manifest.schema.json",
"id": "net.minetest.minetest",
"runtime": "org.freedesktop.Platform",
"runtime-version": "23.08",
"sdk": "org.freedesktop.Sdk",
"command": "minetest",
"rename-icon": "minetest",
"finish-args": [
"--socket=wayland",
"--socket=fallback-x11",
"--socket=pulseaudio",
"--device=all",
"--share=network"
],
"modules": [
{
"name": "libluajit",
"no-autogen": true,
"make-args": [
"PREFIX=/app"
],
"make-install-args": [
"PREFIX=/app"
],
"cleanup": [
"/bin"
],
"sources": [
{
"type": "git",
"url": "https://github.com/LuaJIT/LuaJIT.git",
"commit": "5790d253972c9d78a0c2aece527eda5b134bbbf7"
}
]
},
{
"name": "minetest",
"buildsystem": "cmake-ninja",
"config-opts": [
"-DCMAKE_BUILD_TYPE=Release",
"-DENABLE_CURSES=0",
"-DENABLE_GETTEXT=1"
],
"sources": [
{
"type": "dir",
"path": "."
}
]
}
]
}

View File

@ -0,0 +1,56 @@
---
$schema: "https://raw.githubusercontent.com/flatpak/flatpak-builder/main/data/flatpak-manifest.schema.json"
app-id: net.minetest.minetest
runtime: org.freedesktop.Platform
runtime-version: "23.08"
sdk: org.freedesktop.Sdk
command: minetest
rename-icon: minetest
finish-args:
- "--socket=wayland"
- "--socket=fallback-x11"
- "--socket=pulseaudio"
- "--device=all"
- "--share=ipc"
- "--share=network"
cleanup:
- "/include"
- "/lib/pkgconfig"
- "/share/aclocal"
- "/share/gtk-doc"
- "/share/man"
- "*.la"
- "*.a"
modules:
- name: libluajit
no-autogen: true
make-args:
- PREFIX=/app
make-install-args:
- PREFIX=/app
cleanup:
- "/bin"
sources:
- type: git
url: https://github.com/LuaJIT/LuaJIT.git
commit: dad04f1754723e76ba9dcf9f401f3134a0cd3972
- name: minetest
buildsystem: cmake-ninja
config-opts:
- "-DENABLE_CURSES=0"
- "-DENABLE_GETTEXT=1"
cleanup:
- "/share/minetest/games/devtest"
post-install:
- mv $FLATPAK_DEST/bin/minetest $FLATPAK_DEST/bin/minetest.bin
- install -Dm755 minetest.sh $FLATPAK_DEST/bin/minetest
sources:
- type: dir
path: .
- type: script
dest-filename: minetest.sh
commands:
- 'MINETEST_USER_PATH=$HOME/.var/app/net.minetest.minetest/.minetest exec minetest.bin "$@"'