makedeb
Lightweight, Python library and cli for downloading YouTube videos, fork of pytube.
Viewing /PKGBUILD
.
Click here to go back to the Git tree for python3-pytubefix.
# Maintainer: exponential <echo ZXhwb25lbnRpYWxtYXRyaXhAcHJvdG9ubWFpbC5jb20K | base64 -d>
_pkgname=pytubefix
pkgname=python3-pytubefix
pkgver="9.1.1"
pkgrel=0
pkgdesc="Lightweight, Python library and cli for downloading YouTube videos, fork of pytube."
arch=('all')
url='https://github.com/JuanBindez/pytubefix'
license=('MIT')
depends=('python3')
# opt or mandatory?
optdepends=('nodejs')
makedepends=('python3-build' 'python3-installer' 'python3-wheel')
source=("${pkgname}-${pkgver}.tar.gz::https://github.com/JuanBindez/pytubefix/archive/refs/tags/v${pkgver}.tar.gz")
b2sums=('5e797da020ee0eb54fd18f060c4a66773ea8dbd7079966b45fb751a5a371c3cfaf7d0f57362faaab126b8ba14c2c5d6235e13fcc53da0e3418aae34ba425c94c')
prepare(){
cd "$srcdir/${_pkgname}-${pkgver}"
# setuptools 67.4.0 is too high
sed -i 's!setuptools>=67.4.0!setuptools>=0.0.0!' pyproject.toml
}
build(){
cd "$srcdir/${_pkgname}-${pkgver}"
python3 -m build --no-isolation --wheel
}
package() {
cd $srcdir/${_pkgname}-${pkgver}
python3 -m installer --destdir="$pkgdir" dist/*.whl #--optimize=1 --skip-build
# Manual remove local
mv "$pkgdir/usr/local/"* "$pkgdir/usr/"
rmdir "$pkgdir/usr/local"
#doc
install -Dm644 "README.md" "$pkgdir/usr/share/doc/$pkgname/readme"
install -Dm644 LICENSE "$pkgdir/usr/share/doc/$pkgname/license"
}