Skip to content

Commit

Permalink
Final fixes before release. Fixes #338
Browse files Browse the repository at this point in the history
  • Loading branch information
kozec committed Feb 27, 2018
1 parent 18ba7b9 commit 948152a
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 5 deletions.
14 changes: 11 additions & 3 deletions appimage-build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ EXEC="scc"
EVDEV_VERSION=0.7.0
[ x"$BUILD_APPDIR" == "x" ] && BUILD_APPDIR=$(pwd)/appimage


function download_dep() {
NAME=$1
URL=$2
Expand All @@ -24,7 +25,7 @@ function build_dep() {
pushd /tmp/${NAME}
tar --extract --strip-components=1 -f /tmp/${NAME}.tar.gz
python2 setup.py build
PYTHONPATH=${BUILD_APPDIR}/usr/lib/python2.7/site-packages python2 setup.py install --prefix ${BUILD_APPDIR}/usr
python2 setup.py install --prefix ${BUILD_APPDIR}/usr
popd
}

Expand All @@ -35,7 +36,14 @@ download_dep "python-evdev-0.7.0" "https://github.com/gvalkov/python-evdev/archi
download_dep "pylibacl-0.5.3" "https://github.com/iustin/pylibacl/releases/download/pylibacl-v0.5.3/pylibacl-0.5.3.tar.gz"

# Prepare & build
mkdir -p ${BUILD_APPDIR}/usr/lib/python2.7/site-packages/
export PYTHONPATH=${BUILD_APPDIR}/usr/lib/python2.7/site-packages/
mkdir -p "$PYTHONPATH"/site-packages/
if [[ $(grep ID_LIKE /etc/os-release) == *"suse"* ]] ; then
# Special handling for OBS
ln -s lib64 ${BUILD_APPDIR}/usr/lib
export PYTHONPATH="$PYTHONPATH":${BUILD_APPDIR}/usr/lib64/python2.7/site-packages/
fi

build_dep "python-evdev-0.7.0"
build_dep "pylibacl-0.5.3"
python2 setup.py build
Expand All @@ -62,4 +70,4 @@ cp scripts/${APP}.appdata.xml ${BUILD_APPDIR}/usr/share/metainfo/${APP}.appdata.
cp scripts/appimage-AppRun.sh ${BUILD_APPDIR}/AppRun
chmod +x ${BUILD_APPDIR}/AppRun

echo "Run appimagetool ${BUILD_APPDIR} to finish prepared appimage"
echo "Run appimagetool -n ${BUILD_APPDIR} to finish prepared appimage"
2 changes: 1 addition & 1 deletion scc/gui/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -1212,7 +1212,7 @@ def mnuTurnoffController_activate(self, *a):


def show_error(self, message, ribar=None):
if self.ribar is None:
if self.ribar is None or self.ribar.get_label() is None:
self.ribar = ribar or RIBar(message, Gtk.MessageType.ERROR)
content = self.builder.get_object("content")
content.pack_start(self.ribar, False, False, 1)
Expand Down
2 changes: 1 addition & 1 deletion scc/gui/daemon_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,7 @@ def start(self, mode="start"):
self._on_daemon_died()
Gio.Subprocess.new([ find_binary('scc-daemon'), "/dev/null", mode ], Gio.SubprocessFlags.NONE)
self._connect()
GLib.timeout_add_seconds(5, self._check_connected)
GLib.timeout_add_seconds(10, self._check_connected)


def restart(self):
Expand Down
1 change: 1 addition & 0 deletions scc/lib/xinput.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#!/usr/bin/env python2
# -*- coding: utf-8 -*-
"""
XInput tools
Expand Down

0 comments on commit 948152a

Please sign in to comment.