mirror of
https://github.com/Ponce/slackbuilds
synced 2024-11-16 19:50:19 +01:00
python/pyusb: Add optional python3 support.
Signed-off-by: Kyle Guinn <elyk03@gmail.com>
This commit is contained in:
parent
ddca1e03e0
commit
e48c5df4d7
1 changed files with 8 additions and 4 deletions
|
@ -2,7 +2,7 @@
|
|||
|
||||
# Slackware build script for PyUSB
|
||||
|
||||
# Copyright 2014-2017 Kyle Guinn <elyk03@gmail.com>, USA
|
||||
# Copyright 2014-2019 Kyle Guinn <elyk03@gmail.com>
|
||||
# All rights reserved.
|
||||
#
|
||||
# Redistribution and use of this script, with or without modification, is
|
||||
|
@ -24,7 +24,7 @@
|
|||
|
||||
PRGNAM=pyusb
|
||||
VERSION=${VERSION:-1.0.2}
|
||||
BUILD=${BUILD:-1}
|
||||
BUILD=${BUILD:-2}
|
||||
TAG=${TAG:-_SBo}
|
||||
|
||||
if [ -z "$ARCH" ]; then
|
||||
|
@ -48,12 +48,16 @@ rm -rf $PKG
|
|||
mkdir -p $TMP $PKG $OUTPUT
|
||||
cd $TMP
|
||||
rm -rf $PRGNAM-$VERSION
|
||||
tar -xzvf $CWD/$PRGNAM-$VERSION.tar.gz
|
||||
tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
|
||||
cd $PRGNAM-$VERSION
|
||||
chown -R root:root .
|
||||
chmod -R u+w,go-w,a+rX-st .
|
||||
|
||||
python ./setup.py install --root=$PKG
|
||||
python2 ./setup.py install --root=$PKG
|
||||
if python3 -c 'import sys' 2>/dev/null; then
|
||||
rm -rf build
|
||||
python3 ./setup.py install --root=$PKG
|
||||
fi
|
||||
|
||||
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
|
||||
cp -a $DOCS $PKG/usr/doc/$PRGNAM-$VERSION
|
||||
|
|
Loading…
Reference in a new issue