contrib/python3-pexpect/Pkgfile

24 lines
859 B
Plaintext

# Description: Pexpect makes Python a better tool for controlling other applications
# URL: https://github.com/pexpect/pexpect
# Maintainer: Tim Biermann, tbier at posteo dot de
# Depends on: python3-ptyprocess
name=python3-pexpect
version=4.8.0
release=1
source=(https://github.com/pexpect/pexpect/archive/$version/$name-$version.tar.gz)
build() {
cd pexpect-$version
_pyver=$(/usr/bin/python3 -c 'import sys; print("%s.%s" % sys.version_info[:2])')
if prt-get isinst python3-flit-core; then
/usr/bin/python3 -m build --wheel --skip-dependency-check --no-isolation
/usr/bin/python3 -m installer --compile-bytecode 0 --destdir=$PKG dist/*.whl
else
/usr/bin/pip3 install --isolate --root=$PKG --ignore-installed --no-deps pexpect
fi
rm -rf $PKG/usr/lib/python$_pyver/site-packages/pexpect-$version.dist-info/{INSTALLER,REQUESTED}
}