Skip to content

Commit

Permalink
Store data in flatpak data instead of user .local path
Browse files Browse the repository at this point in the history
  • Loading branch information
mirkobrombin committed Nov 28, 2020
1 parent ecdb48e commit 80b6c29
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 5 deletions.
39 changes: 37 additions & 2 deletions pm.mirko.bottles.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@
"runtime": "org.gnome.Platform",
"runtime-version": "3.38",
"sdk": "org.gnome.Sdk",
"add-extensions": {
"org.gnome.Platform.Compat.i386": {
"directory": "lib/i386-linux-gnu",
"version": "3.38"
}
},
"command": "bottles",
"tags": ["devel", "development"],
"finish-args": [
Expand All @@ -13,8 +19,9 @@
"--share=ipc",
"--socket=fallback-x11",
"--socket=wayland",
"--socket=pulseaudio",
"--socket=pulseaudio",
"--socket=session-bus",
"--filesystem=~/.local/share/bottles:create",
"--filesystem=xdg-desktop",
"--filesystem=xdg-documents",
"--filesystem=xdg-pictures",
Expand All @@ -23,6 +30,20 @@
"--filesystem=xdg-download",
"--device=all"
],
"x-compat-i386-opts": {
"prepend-pkg-config-path": "/app/lib32/pkgconfig:/usr/lib/i386-linux-gnu/pkgconfig",
"ldflags": "-L/app/lib32",
"append-path": "/usr/lib/sdk/toolchain-i386/bin",
"env": {
"CC": "i686-unknown-linux-gnu-gcc",
"CXX": "i686-unknown-linux-gnu-g++"
},
"libdir": "/app/lib32"
},
"sdk-extensions": [
"org.gnome.Sdk.Compat.i386",
"org.freedesktop.Sdk.Extension.toolchain-i386"
],
"cleanup": [
"/include",
"/lib/pkgconfig",
Expand All @@ -34,7 +55,21 @@
"*.la",
"*.a"
],
"modules": [
"modules": [{
"name": "i386-libs",
"buildsystem": "simple",
"build-commands": [
"mkdir -p /app/lib/i386-linux-gnu",
"install -Dm644 ld.so.conf -t /app/etc/",
"mkdir -p /app/bottles",
"mkdir -p /app/bottles/temp",
"mkdir -p /app/bottles/bottles"
],
"sources": [{
"type": "file",
"path": "ld.so.conf"
}]
},
{
"name": "bottles",
"builddir": true,
Expand Down
6 changes: 3 additions & 3 deletions src/runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,9 @@ class BottlesRunner:
'''
Define local path for temp and runners
'''
temp_path = "%s/.local/share/bottles/temp" % Path.home()
runners_path = "%s/.local/share/bottles/runners" % Path.home()
bottles_path = "%s/.local/share/bottles/bottles" % Path.home()
temp_path = "/app/bottles/temp"
runners_path = "/app/bottles/runners"
bottles_path = "/app/bottles/bottles"

runners_available = []
local_bottles = {}
Expand Down

0 comments on commit 80b6c29

Please sign in to comment.