diff --git a/build.sh b/build.sh new file mode 100755 index 0000000000000000000000000000000000000000..8ba62ae5e422c182e088518e249a45d5de0a65cf --- /dev/null +++ b/build.sh @@ -0,0 +1,23 @@ +#!/bin/sh + +FILE=org.gnu.hello.json +VERSION=2.10 + +APPID=`basename $FILE .json` + +if [ x$TARGET != x`uname -p` -a ! -z "$TARGET" ]; then + if [ ! -x qemu-static ]; then + echo "QEmu static emulator missing as 'qemu-static' executable" + exit 1 + fi + + ARCH_OPT="--arch=$TARGET" + ARCH_EMU_OPT="--arch-emulator=`pwd`/qemu-static" +else + TARGET=`uname -p` +fi + +echo ========== Building $APPID ================ +rm -rf app +flatpak-builder $ARCH_OPT $ARCH_EMU_OPT --ccache --require-changes --repo=hello-repo --subject="${APPID} ${VERSION}" ${EXPORT_ARGS-} app $FILE && \ +flatpak build-bundle $ARCH_OPT hello-repo/ $APPID.$TARGET.xdgapp $APPID master diff --git a/org.gnu.hello.json b/org.gnu.hello.json new file mode 100644 index 0000000000000000000000000000000000000000..7a2ac0a174ed44392ef78246b0588cc277f651ba --- /dev/null +++ b/org.gnu.hello.json @@ -0,0 +1,25 @@ +{ + "app-id": "org.gnu.hello", + "runtime": "org.freedesktop.Platform", + "runtime-version": "1.4", + "sdk": "org.freedesktop.Sdk", + "command": "hello", + "separate-locales": false, + "build-options" : { + "cflags": "-O2 -g", + "cxxflags": "-O2 -g" + }, + "cleanup": [ "/bin/flatpak-arch-emulator" ], + "modules": [ + { + "name": "gnu-hello", + "sources": [ + { + "type": "archive", + "url": "http://ftp.gnu.org/gnu/hello/hello-2.10.tar.gz", + "sha256": "31e066137a962676e89f69d1b65382de95a7ef7d914b8cb956f41ea72e0f516b" + } + ] + } + ] +}