Skip to content

Commit 0e6b1ec

Browse files
author
arch
committed
improve flatpak build
1 parent 86e017b commit 0e6b1ec

File tree

3 files changed

+25
-49
lines changed

3 files changed

+25
-49
lines changed

build_flatpak.sh

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,12 @@
22

33
sudo sysctl kernel.unprivileged_userns_clone=1
44
sudo flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
5-
sudo flatpak install -y flathub org.freedesktop.Platform//21.08 org.freedesktop.Sdk//21.08
6-
sudo flatpak install -y flathub org.gnome.Platform//3.38 org.gnome.Sdk//3.38
75
sudo flatpak install -y flathub org.kde.Platform//5.15 org.kde.Sdk//5.15
8-
sudo flatpak install -y flathub org.gtk.Gtk3theme.Breeze-Dark
9-
flatpak-builder --repo=repo --force-clean build-dir org.flatpak.PythonFunscriptEditor.json
6+
7+
if [ "$@" = "--install" ]; then
8+
flatpak-builder --user --install --force-clean build-dir org.flatpak.PythonFunscriptEditor.json
9+
else
10+
flatpak-builder --repo=repo --force-clean build-dir org.flatpak.PythonFunscriptEditor.json
11+
fi
12+
13+
sudo sysctl kernel.unprivileged_userns_clone=0

environment_flatpak.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ dependencies:
2020
- cryptography=3.4.7=py38hd23ed53_0
2121
- dbus=1.13.18=hb2f20db_0
2222
- expat=2.4.1=h2531618_2
23-
- ffmpeg=4.3.1=hca11adc_2
2423
- fontconfig=2.13.1=h6c09931_0
2524
- freetype=2.10.4=h5ab3b9f_0
2625
- gettext=0.19.8.1=h0b5b191_1005

org.flatpak.PythonFunscriptEditor.json

Lines changed: 17 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -13,36 +13,9 @@
1313
"--socket=pulseaudio",
1414
"--filesystem=xdg-pictures",
1515
"--filesystem=home:rw",
16-
"--talk-name=org.gtk.vfs",
17-
"--talk-name=org.gtk.vfs.*",
18-
"--talk-name=org.gnome.SettingsDaemon.MediaKeys",
1916
"--env=LC_NUMERIC=C"
2017
],
2118
"modules": [
22-
{
23-
"name": "install-runtime",
24-
"buildsystem": "simple",
25-
"build-options": {
26-
"build-args": ["--share=network"]
27-
},
28-
"build-commands": [
29-
"export CONDA_ALWAYS_YES=\"true\"",
30-
"bash Miniconda3-py38_4.10.3-Linux-x86_64.sh -b -p /app/bin/conda -f",
31-
"/app/bin/conda/bin/activate",
32-
"/app/bin/conda/bin/conda env update -f environment_flatpak.yaml"
33-
],
34-
"sources": [
35-
{
36-
"type": "file",
37-
"url": "https://repo.anaconda.com/miniconda/Miniconda3-py38_4.10.3-Linux-x86_64.sh",
38-
"sha256": "935d72deb16e42739d69644977290395561b7a6db059b316958d97939e9bdf3d"
39-
},
40-
{
41-
"type": "file",
42-
"path": "environment_flatpak.yaml"
43-
}
44-
]
45-
},
4619
{
4720
"name": "luajit",
4821
"no-autogen": true,
@@ -187,26 +160,26 @@
187160
]
188161
},
189162
{
190-
"name": "kdecoration",
191-
"buildsystem": "cmake-ninja",
192-
"builddir": true,
163+
"name": "install-runtime",
164+
"buildsystem": "simple",
165+
"build-options": {
166+
"build-args": ["--share=network"]
167+
},
168+
"build-commands": [
169+
"export CONDA_ALWAYS_YES=\"true\"",
170+
"bash Miniconda3-py38_4.10.3-Linux-x86_64.sh -b -p /app/bin/conda -f",
171+
"/app/bin/conda/bin/activate",
172+
"/app/bin/conda/bin/conda env update -f environment_flatpak.yaml --prune"
173+
],
193174
"sources": [
194175
{
195-
"type": "git",
196-
"url": "https://invent.kde.org/kde/kdecoration.git",
197-
"commit": "70a98b43f3a866fc39c420176af90709dd34df70"
198-
}
199-
]
200-
},
201-
{
202-
"name": "breeze",
203-
"buildsystem": "cmake-ninja",
204-
"builddir": true,
205-
"sources": [
176+
"type": "file",
177+
"url": "https://repo.anaconda.com/miniconda/Miniconda3-py38_4.10.3-Linux-x86_64.sh",
178+
"sha256": "935d72deb16e42739d69644977290395561b7a6db059b316958d97939e9bdf3d"
179+
},
206180
{
207-
"type": "git",
208-
"url": "https://invent.kde.org/kde/breeze.git",
209-
"commit": "945ba0cc712fb1e4f68ce8862d1fbcb864f3e6fa"
181+
"type": "file",
182+
"path": "environment_flatpak.yaml"
210183
}
211184
]
212185
},

0 commit comments

Comments
 (0)