# Maintainer: Alexey Pavlov _realname=setuptools pkgbase="python-${_realname}" pkgname=("python-${_realname}") pkgver=63.2.0 pkgrel=1 pkgdesc="Easily download, build, install, upgrade, and uninstall Python packages" arch=('any') license=('PSF') url="https://pypi.python.org/pypi/setuptools" depends=('python') provides=("python3-${_realname}" 'python3-distribute') replaces=("python3-${_realname}" 'python3-distribute') conflicts=("python3-${_realname}") source=("${_realname}-${pkgver}.tar.gz::https://github.com/pypa/setuptools/archive/v${pkgver}.tar.gz") sha512sums=('1e44bc5de2e9587a761c1a1060d5b7da405eca0711128ce35a524cb20e968456e85e48553f73ca9eb179d8b90e71250e02992ff16fceef62c7017a8c312e0a41') prepare() { export SETUPTOOLS_INSTALL_WINDOWS_SPECIFIC_FILES=0 } build() { cd "${srcdir}/setuptools-${pkgver}" /usr/bin/python setup.py egg_info /usr/bin/python setup.py build } check() { ( # Workaround UTF-8 tests by setting LC_CTYPE export LC_CTYPE=en_US.UTF-8 # https://github.com/pypa/setuptools/pull/810 export PYTHONDONTWRITEBYTECODE=1 # Check python module # cd "${srcdir}/setuptools-${pkgver}" # /usr/bin/python setup.py pytest )} package() { cd "${srcdir}/setuptools-${pkgver}" /usr/bin/python setup.py install --prefix=/usr --root="${pkgdir}" --optimize=1 --skip-build }