aboutsummaryrefslogtreecommitdiff
path: root/python/stopit/stopit.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'python/stopit/stopit.SlackBuild')
-rw-r--r--python/stopit/stopit.SlackBuild17
1 files changed, 11 insertions, 6 deletions
diff --git a/python/stopit/stopit.SlackBuild b/python/stopit/stopit.SlackBuild
index e968160951fe9..b29224c7b7f39 100644
--- a/python/stopit/stopit.SlackBuild
+++ b/python/stopit/stopit.SlackBuild
@@ -2,7 +2,7 @@
# Slackware build script for stopit
-# Copyright 2015 Brenton Earl <brent@exitstatusone.com>
+# Copyright 2015, 2018 Brenton Earl <brent@exitstatusone.com>
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -23,13 +23,13 @@
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
PRGNAM=stopit
-VERSION=${VERSION:-1.1.1}
+VERSION=${VERSION:-1.1.2}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
- i?86) ARCH=i486 ;;
+ i?86) ARCH=i586 ;;
arm*) ARCH=arm ;;
*) ARCH=$( uname -m ) ;;
esac
@@ -40,8 +40,8 @@ TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
-if [ "$ARCH" = "i486" ]; then
- SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+if [ "$ARCH" = "i586" ]; then
+ SLKCFLAGS="-O2 -march=i586 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
@@ -71,11 +71,16 @@ find -L . \
python setup.py install --root=$PKG
+# Python 3 support.
+if $(python3 -c 'import sys' 2>/dev/null); then
+ python3 setup.py install --root=$PKG
+fi
+
find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
-cp -a CHANGES.rst PKG-INFO README.rst $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a CHANGES* README* $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
mkdir -p $PKG/install