summaryrefslogtreecommitdiffstats
path: root/abs/core/python_modules/python-setuptools/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'abs/core/python_modules/python-setuptools/PKGBUILD')
-rw-r--r--abs/core/python_modules/python-setuptools/PKGBUILD45
1 files changed, 26 insertions, 19 deletions
diff --git a/abs/core/python_modules/python-setuptools/PKGBUILD b/abs/core/python_modules/python-setuptools/PKGBUILD
index 31a941e..c90e33c 100644
--- a/abs/core/python_modules/python-setuptools/PKGBUILD
+++ b/abs/core/python_modules/python-setuptools/PKGBUILD
@@ -3,48 +3,55 @@
# Maintainer: Felix Yan <felixonmars@archlinux.org>
pkgbase=python-setuptools
-pkgname=('python2-setuptools')
-pkgver=36.2.0
+pkgname=('python-setuptools' 'python2-setuptools')
+pkgver=39.0.1
pkgrel=1
epoch=1
pkgdesc="Easily download, build, install, upgrade, and uninstall Python packages"
arch=('any')
license=('PSF')
url="http://pypi.python.org/pypi/setuptools"
-makedepends=('python2-packaging' 'python2-appdirs'
- 'python2-pip')
-checkdepends=('python2-pytest-runner'
- 'python2-pytest-flake8' 'python2-backports.unittest_mock' 'git')
+makedepends=('python-packaging' 'python2-packaging' 'python-appdirs' 'python2-appdirs')
+checkdepends=('python-pytest-runner' 'python2-pytest-runner' 'python-pytest-flake8'
+ 'python2-pytest-flake8' 'python-mock' 'python2-mock' 'python-pytest-fixture-config'
+ 'python2-pytest-fixture-config' 'python-pytest-virtualenv' 'python2-pytest-virtualenv'
+ 'python-wheel' 'python2-wheel' 'python-pip' 'python2-pip' 'git')
source=("$pkgbase-$pkgver.tar.gz::https://github.com/pypa/setuptools/archive/v$pkgver.tar.gz")
-sha512sums=('579e63feb9f5ea33e29f4ae3a2736a2cfd18e83927775a56553dbe34bcfa32f325457204333d4f183759dbcd57e4ad7f8b166fcfbf626db597b18e14bbcd9ea4')
+sha512sums=('34df8f10e89825975c82059c759690a2cc1486fc84c71a76875b92c2452529fbdd628e11e3043e479ea3f031af18b37a37b86d2a8d2505c300188eccdc109332')
prepare() {
- # Don't download and install deps
- sed -i '/pip.main(args)/d' setuptools-$pkgver/bootstrap.py
-
- rm -r setuptools-$pkgver/pkg_resources/_vendor
+ rm -r setuptools-$pkgver/{pkg_resources,setuptools}/_vendor
# Remove post-release tag since we are using stable tags
sed -e '/tag_build = .post/d' \
-e '/tag_date = 1/d' \
-i setuptools-$pkgver/setup.cfg
+ # 'Clean' installation is expected to fail since we removed bundled packages
+ sed -i '/^def test_clean_env_install/i import pytest\n\n@pytest.mark.xfail' setuptools-$pkgver/setuptools/tests/test_virtualenv.py
+
+ # Tests failed. Importing an unbundled new setuptools in a virtualenv does not work, but this won't
+ # affect normal virtualenv usage (which don't have to import the unbundled setuptools in *current*
+ # dir.
+ sed -e '/^def test_pip_upgrade_from_source/i @pytest.mark.xfail' \
+ -e '/^def test_test_command_install_requirements/i @pytest.mark.xfail' \
+ -i setuptools-$pkgver/setuptools/tests/test_virtualenv.py
+
cp -a setuptools-$pkgver{,-py2}
-# cd "$srcdir"/setuptools-$pkgver
-# sed -i -e "s|^#\!.*/usr/bin/env python|#!/usr/bin/env python3|" setuptools/command/easy_install.py
+ cd "$srcdir"/setuptools-$pkgver
+ sed -i -e "s|^#\!.*/usr/bin/env python|#!/usr/bin/env python3|" setuptools/command/easy_install.py
cd "$srcdir"/setuptools-$pkgver-py2
sed -i -e "s|^#\!.*/usr/bin/env python|#!/usr/bin/env python2|" setuptools/command/easy_install.py
- sed -i -e "s|'pip'|'pip2'|" setuptools/tests/{test_develop.py,test_namespaces.py}
export SETUPTOOLS_INSTALL_WINDOWS_SPECIFIC_FILES=0
}
build() {
-# cd "$srcdir"/setuptools-$pkgver
-# python bootstrap.py
-# python setup.py build
+ cd "$srcdir"/setuptools-$pkgver
+ python bootstrap.py
+ python setup.py build
cd "$srcdir"/setuptools-$pkgver-py2
python2 bootstrap.py
@@ -58,8 +65,8 @@ check() { (
# https://github.com/pypa/setuptools/pull/810
export PYTHONDONTWRITEBYTECODE=1
-# cd "$srcdir"/setuptools-$pkgver
-# python setup.py pytest
+ cd "$srcdir"/setuptools-$pkgver
+ python setup.py pytest
cd "$srcdir"/setuptools-$pkgver-py2
python2 setup.py pytest