From b0284415ac68240e33f33ab2db8ac19aa658ed28 Mon Sep 17 00:00:00 2001 From: Benjamin Tissoires Date: Wed, 24 Jan 2018 15:33:19 +0100 Subject: [PATCH] Add a flatpak-builder json flatpak-builder can produce an app by calling: $> flatpak-builder --force-clean flatpak-tuhi \ org.freedesktop.tuhi.json and it can run it through: $> flatpak-builder --run flatpak-tuhi org.freedesktop.tuhi.json tuhi The install with a local repo would be: $> flatpak-builder --repo=repo --force-clean flatpak-tuhi \ org.freedesktop.tuhi.json $> flatpak --user remote-add --no-gpg-verify --if-not-exists \ tuhi-repo repo $> flatpak --user install tuhi-repo org.freedesktop.tuhi $> flatpak org.freedesktop.tuhi Fixes #31 --- .gitignore | 2 + org.freedesktop.tuhi.json | 106 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 108 insertions(+) create mode 100644 org.freedesktop.tuhi.json diff --git a/.gitignore b/.gitignore index b729240..f0aa0d7 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,5 @@ +.flatpak* +flatpak* tuhi.egg-info __pycache__ *.swp diff --git a/org.freedesktop.tuhi.json b/org.freedesktop.tuhi.json new file mode 100644 index 0000000..539a2c4 --- /dev/null +++ b/org.freedesktop.tuhi.json @@ -0,0 +1,106 @@ +{ + "id": "org.freedesktop.tuhi", + "command": "/app/bin/tuhi", + "runtime": "org.freedesktop.Platform", + "sdk": "org.freedesktop.Sdk", + "runtime-version": "1.6", + "cleanup": [ "/cache", + "/include", + "/lib/pkgconfig", + "/man", + "/share/aclocal", + "/share/devhelp", + "/share/gir-1.0", + "/share/gtk-doc", + "/share/man", + "/share/pkgconfig", + "/share/vala", + "/lib/systemd", + "*.la", "*.a" ], + "build-options" : { + "cflags": "-O2 -g", + "cxxflags": "-O2 -g" + }, + "finish-args": [ + "--system-talk-name=org.bluez", + "--own-name=org.freedesktop.tuhi1" + ], + "modules": [ + { + "name": "cpython", + "sources": [ + { + "type": "archive", + "url": "https://www.python.org/ftp/python/3.6.4/Python-3.6.4.tar.xz", + "sha256": "159b932bf56aeaa76fd66e7420522d8c8853d486b8567c459b84fe2ed13bcaba" + } + ] + }, + { + "name": "pycairo", + "build-options" : { + "env": { + "PYTHON": "/app/bin/python3" + } + }, + "buildsystem": "simple", + "build-commands": [ + "python3 ./setup.py build", + "python3 ./setup.py install" + ], + "sources": [ + { + "type": "archive", + "url": "https://github.com/pygobject/pycairo/releases/download/v1.14.1/pycairo-1.14.1.tar.gz", + "sha256": "0d13a0a6eeaf0c357db04392943eb9b25767445608d31dde1307f003f68c5754" + } + ] + }, + { + "name": "pygobject", + "config-opts": ["--enable-compile-warnings=minimum"], + "build-options" : { + "env": { + "PYTHON": "/app/bin/python3" + } + }, + "sources": [ + { + "type": "git", + "url": "https://gitlab.gnome.org/GNOME/pygobject.git" + } + ] + }, + { + "name": "pyxdg", + "buildsystem": "simple", + "build-options" : { + "env": { + "PYTHON": "/app/bin/python3" + } + }, + "sources": [ + { + "type": "git", + "url": "git://anongit.freedesktop.org/xdg/pyxdg" + } + ], + "build-commands": [ + "python3 setup.py install --verbose" + ] + }, + { + "name": "tuhi", + "buildsystem": "simple", + "sources": [ + { + "type": "git", + "path": "." + } + ], + "build-commands": [ + "python3 setup.py install --verbose" + ] + } + ] +}