diff options
author | Isaac Yu <isaacyu1@isaacyu1.com> | 2022-05-25 13:05:31 -0700 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2022-06-04 10:37:17 +0700 |
commit | 86a8c3142f749f7d72c4166743090364687d4b68 (patch) | |
tree | 7fc5a4846c78d8a99944af5137926c340c0772c8 /python/threadpoolctl/threadpoolctl.SlackBuild | |
parent | 185d76c39ebad65ca509c6e3c07ff945099fb8a4 (diff) | |
download | slackbuilds-86a8c3142f749f7d72c4166743090364687d4b68.tar.gz |
python/threadpoolctl: Update for 3.1.0
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'python/threadpoolctl/threadpoolctl.SlackBuild')
-rw-r--r-- | python/threadpoolctl/threadpoolctl.SlackBuild | 19 |
1 files changed, 16 insertions, 3 deletions
diff --git a/python/threadpoolctl/threadpoolctl.SlackBuild b/python/threadpoolctl/threadpoolctl.SlackBuild index 8e31541328..7f33fbae45 100644 --- a/python/threadpoolctl/threadpoolctl.SlackBuild +++ b/python/threadpoolctl/threadpoolctl.SlackBuild @@ -25,7 +25,7 @@ cd $(dirname $0) ; CWD=$(pwd) PRGNAM=threadpoolctl -VERSION=${VERSION:-3.0.0} +VERSION=${VERSION:-3.1.0} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} PKGTYPE=${PKGTYPE:-tgz} @@ -75,13 +75,26 @@ find -L . \ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; -python3 setup.py install --root=$PKG +# Use this setup.py shim: +cat << EOF > setup.py +from distutils.core import setup +setup(name='${PRGNAM}', + version='${VERSION}', + py_modules=['${PRGNAM}'], +) +EOF + +# With the shim, it's a good idea to use "unshare -n" to prevent downloading +# anything extra: +unshare -n python3 setup.py install --root=$PKG || exit 1 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 *.md LICENSE PKG-INFO dev-requirements.txt $PKG/usr/doc/$PRGNAM-$VERSION +cp -a \ + CHANGES.md LICENSE multiple_openmp.md PKG-INFO README.md dev-requirements.txt \ + $PKG/usr/doc/$PRGNAM-$VERSION cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild mkdir -p $PKG/install |