summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMark Blakeney2020-05-29 13:31:06 +1000
committerMark Blakeney2020-05-29 13:35:41 +1000
commit6bb6cc3f4d60e63fca89a8992959ad8fba8e8689 (patch)
treefeee2dbf7ec91ccfac99bff85ac204df3d476a2a
parentf340b7eb339b454b7e7061512135fc7254fc105e (diff)
downloadaur-6bb6cc3f4d60e63fca89a8992959ad8fba8e8689.tar.gz
Change installation from setuptools to pip
Unlike setuptools, pip installs this package cleanly using wheels.
-rw-r--r--.SRCINFO4
-rw-r--r--.gitignore1
-rw-r--r--PKGBUILD46
3 files changed, 7 insertions, 44 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 73a8b0c06fcf..e3990947adb0 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,11 +1,11 @@
pkgbase = python-ptvsd
pkgdesc = Python debugger package for use with Visual Studio and Visual Studio Code
pkgver = 4.3.2
- pkgrel = 2
+ pkgrel = 3
url = https://github.com/microsoft/ptvsd
arch = x86_64
license = MIT
- makedepends = python-setuptools
+ makedepends = python-pip
depends = python>=3.4
source = python-ptvsd-4.3.2.tar.gz::https://github.com/microsoft/ptvsd/archive/v4.3.2.tar.gz
sha1sums = 0ea052d12c5f78e676194c8ef3a476fe76d29ea8
diff --git a/.gitignore b/.gitignore
index 6dd39bbd03b8..a6cd1334d01b 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,3 +2,4 @@ pkg/
src/
*.tar
*.[gx]z
+*.log
diff --git a/PKGBUILD b/PKGBUILD
index 541e31eb1ea5..fd5e99c8d5d4 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,58 +2,20 @@
_pkgname=ptvsd
pkgname=python-$_pkgname
pkgver=4.3.2
-pkgrel=2
+pkgrel=3
pkgdesc="Python debugger package for use with Visual Studio and Visual Studio Code"
url="https://github.com/microsoft/$_pkgname"
license=("MIT")
arch=("x86_64")
depends=("python>=3.4")
-makedepends=("python-setuptools")
+makedepends=("python-pip")
source=("$pkgname-$pkgver.tar.gz::$url/archive/v$pkgver.tar.gz")
sha1sums=('0ea052d12c5f78e676194c8ef3a476fe76d29ea8')
-# These are python2 files required for legacy support of the package on
-# non-Arch systems. These all fail to byte-compile which causes package
-# errors so we will just remove them before the install step.
-_badfiles=(
- "reraise2.py"
- "_vendored/pydevd/pydevd_attach_to_process/_check.py"
- "_vendored/pydevd/pydevd_attach_to_process/winappdbg/plugins/do_example.py"
- "_vendored/pydevd/pydevd_attach_to_process/winappdbg/plugins/do_exchain.py"
- "_vendored/pydevd/pydevd_attach_to_process/winappdbg/plugins/do_exploitable.py"
- "_vendored/pydevd/_pydevd_bundle/pydevconsole_code_for_ironpython.py"
- "_vendored/pydevd/_pydevd_bundle/pydevd_exec.py"
- "_vendored/pydevd/_pydev_imps/_pydev_inspect.py"
- "_vendored/pydevd/_pydev_imps/_pydev_pkgutil_old.py"
- "_vendored/pydevd/_pydev_imps/_pydev_SimpleXMLRPCServer.py"
- "_vendored/pydevd/_pydev_imps/_pydev_SocketServer.py"
- "_vendored/pydevd/_pydev_imps/_pydev_uuid_old.py"
- "_vendored/pydevd/_pydev_imps/_pydev_xmlrpclib.py"
- "_vendored/pydevd/pydev_ipython/inputhookglut.py"
-)
-
-build() {
- cd $_pkgname-$pkgver
-
- _vers="$pkgver-$pkgrel"
- echo "Setting build version to $_vers in $PWD/setup.py"
- sed -i "/version=/s/=.*/=\'$_vers\',/" setup.py
-
- python setup.py build
- cd build/lib/$_pkgname
-
- echo "Setting embedded version to $_vers in $PWD/_version.py"
- sed -i "/\"version\":/s/\"[^\"]*\"$/\"$_vers\"/" _version.py
-
- echo "Removing legacy/unneeded files for Arch Linux .."
- for f in "${_badfiles[@]}"; do
- rm -v $f
- done
-}
-
package() {
cd $_pkgname-$pkgver
- python setup.py install --root="$pkgdir/" --optimize=1 --skip-build
+ PIP_CONFIG_FILE=/dev/null pip install --isolated --root="$pkgdir" \
+ --ignore-installed --no-deps .
}
# vim:set ts=2 sw=2 et: