-
Notifications
You must be signed in to change notification settings - Fork 22
/
org.godotengine.Godot.yaml
114 lines (101 loc) · 3.63 KB
/
org.godotengine.Godot.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
app-id: org.godotengine.Godot
runtime: org.freedesktop.Sdk
runtime-version: '23.08'
default-branch: stable
sdk: org.freedesktop.Sdk
add-extensions:
org.freedesktop.Sdk.Extension.openjdk17:
directory: jdk
version: '23.08'
no-autodownload: false
autodelete: false
command: godot
build-options:
arch:
x86_64:
env:
# Only enable link-time optimization when targeting x86_64
# (causes issues on other architectures)
SCONS_FLAGS_EXTRA: use_lto=yes
env:
# Will be appended to the version string displayed in the editor and command-line help
BUILD_NAME: flathub
# SCons flags common to all builds
# Shouldn't be quoted when used as it's a single string, not an array
SCONS_FLAGS: >
platform=linuxbsd
CCFLAGS=-I/app/include
prefix=/app
unix_global_settings_path=/app
progress=no
builtin_freetype=no
builtin_libogg=no
builtin_libpng=no
builtin_libtheora=no
builtin_libvorbis=no
builtin_libwebp=no
builtin_openssl=no
builtin_libvpx=no
builtin_zlib=no
builtin_graphite=no
builtin_harfbuzz=no
udev=no
finish-args:
- --share=ipc
- --socket=x11
- --share=network
- --socket=pulseaudio
- --filesystem=host
- --device=all
- --talk-name=org.freedesktop.Flatpak
modules:
- shared-modules/glu/glu-9.json
- name: jdk
buildsystem: simple
build-commands:
- mkdir -p /app/jdk
- name: scons
buildsystem: simple
cleanup: ['*']
sources:
- type: archive
sha256: d9fcd831700ce373ecd30ac55e9d7eff20754215cff5967c4972237d614a326e
url: https://downloads.sourceforge.net/project/scons/scons/4.7.0/SCons-4.7.0.tar.gz
x-checker-data:
type: anitya
project-id: 4770
url-template: https://downloads.sourceforge.net/project/scons/scons/$version/SCons-$version.tar.gz
build-commands:
- pip3 install --no-index --no-build-isolation --prefix=/app .
- name: godot-tools
buildsystem: simple
sources:
- type: archive
sha256: da14e36448f1efd2955fe85d7ededc9e6ac8c893f76723b4852e7587306c761d
url: https://github.com/godotengine/godot/releases/download/4.2.2-stable/godot-4.2.2-stable.tar.xz
x-checker-data:
type: anitya
project-id: 12162
url-template: https://github.com/godotengine/godot/releases/download/$version/godot-$version.tar.xz
- type: script
dest-filename: godot.sh
commands:
- export APPDATA="$XDG_DATA_HOME"
- if [ -f /app/jdk/enable.sh ]; then source /app/jdk/enable.sh; fi
- /app/bin/godot-bin "$@"
- type: file
path: org.godotengine.Godot.appdata.xml
build-commands:
- python3 /app/bin/scons $SCONS_FLAGS $SCONS_FLAGS_EXTRA target=editor -j "$FLATPAK_BUILDER_N_JOBS"
- install -D -m755 bin/godot.linuxbsd.editor.* /app/bin/godot-bin
- install -D -m755 godot.sh /app/bin/godot
- desktop-file-edit --set-icon=$FLATPAK_ID misc/dist/linux/$FLATPAK_ID.desktop
- install -Dm644 misc/dist/linux/$FLATPAK_ID.desktop /app/share/applications/$FLATPAK_ID.desktop
- install -Dm644 misc/dist/linux/$FLATPAK_ID.xml /app/share/mime/packages/$FLATPAK_ID.xml
- install -Dm644 $FLATPAK_ID.appdata.xml /app/share/appdata/$FLATPAK_ID.appdata.xml
- install -Dm644 icon.svg /app/share/icons/hicolor/scalable/apps/$FLATPAK_ID.svg
- >
for size in {32,64,128,256}; do
rsvg-convert icon.svg -w "$size" -h "$size" -a -f png -o "$size.png";
install -Dm644 "$size.png" "/app/share/icons/hicolor/${size}x${size}/apps/$FLATPAK_ID.png";
done