diff options
author | Dan-Simon Myrland <dansimon@radiotube.org> | 2025-06-07 09:52:44 +0700 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2025-06-07 09:58:30 +0700 |
commit | 98f8f3daa2ebbd314d758404952bad341964a396 (patch) | |
tree | 82c2194c09b2221c80b0fbe4cbb7cc1fad2acb3f /python/python3-tasklib/python3-tasklib.SlackBuild | |
parent | ae600cd83cc42e752028e521f29df6611c57aad0 (diff) |
python/python3-tasklib: Added (Python library).
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'python/python3-tasklib/python3-tasklib.SlackBuild')
-rw-r--r-- | python/python3-tasklib/python3-tasklib.SlackBuild | 61 |
1 files changed, 61 insertions, 0 deletions
diff --git a/python/python3-tasklib/python3-tasklib.SlackBuild b/python/python3-tasklib/python3-tasklib.SlackBuild new file mode 100644 index 0000000000..81905a3203 --- /dev/null +++ b/python/python3-tasklib/python3-tasklib.SlackBuild @@ -0,0 +1,61 @@ +#!/bin/bash +# Slackware build script for python3-tasklib +# Written by Dan-Simon Myrland <dansimon@radiotube.org> + +cd $(dirname $0) ; CWD=$(pwd) + +PRGNAM=python3-tasklib +DIRNAM=tasklib +VERSION=${VERSION:-2.5.1} +BUILD=${BUILD:-1} +TAG=${TAG:-_SBo} +PKGTYPE=${PKGTYPE:-tgz} + +if [ -z "$ARCH" ]; then + case "$( uname -m )" in + i?86) ARCH=i586 ;; + arm*) ARCH=arm ;; + *) ARCH=$( uname -m ) ;; + esac +fi + +if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then + echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE" + exit 0 +fi + +TMP=${TMP:-/tmp/SBo} +PKG=$TMP/package-$PRGNAM +OUTPUT=${OUTPUT:-/tmp} + +# no need for CFLAGS or LIBDIRSUFFIX. actually this would be noarch, +# except for the lib vs. lib64 python problem. + +set -e + +rm -rf $PKG +mkdir -p $TMP $PKG $OUTPUT +cd $TMP +rm -rf $PRGNAM-$VERSION +tar xvf $CWD/$DIRNAM-$VERSION.tar.gz +cd $DIRNAM-$VERSION +chown -R root:root . +find -L . -perm /111 -a \! -perm 755 -a -exec chmod 755 {} + -o \ + \! -perm /111 -a \! -perm 644 -a -exec chmod 644 {} + + +PYVER=$(python3 -c 'import sys; print("%d.%d" % sys.version_info[:2])') +export PYTHONPATH=/opt/python$PYVER/site-packages + +python3 -m build --wheel --no-isolation +python3 -m installer --destdir "$PKG" dist/*.whl + +PKGDOC=$PKG/usr/doc/$PRGNAM-$VERSION +mkdir -p $PKGDOC +cp -a AUTHORS README.rst $PKGDOC +cat $CWD/$PRGNAM.SlackBuild > $PKGDOC/$PRGNAM.SlackBuild + +mkdir -p $PKG/install +cat $CWD/slack-desc > $PKG/install/slack-desc + +cd $PKG +/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE |