summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMark Blakeney2020-07-17 20:39:43 +1000
committerMark Blakeney2020-07-17 20:39:43 +1000
commit4131d5742d82b628fae7d7fb310236b70439afa9 (patch)
treef6dabf5767cb88eac954c1684b31bbf83c2fc2f3
parent6bb6cc3f4d60e63fca89a8992959ad8fba8e8689 (diff)
downloadaur-4131d5742d82b628fae7d7fb310236b70439afa9.tar.gz
Fix build issues
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD29
2 files changed, 27 insertions, 4 deletions
diff --git a/.SRCINFO b/.SRCINFO
index e3990947adb0..e1dc7534797b 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = python-ptvsd
pkgdesc = Python debugger package for use with Visual Studio and Visual Studio Code
pkgver = 4.3.2
- pkgrel = 3
+ pkgrel = 4
url = https://github.com/microsoft/ptvsd
arch = x86_64
license = MIT
diff --git a/PKGBUILD b/PKGBUILD
index fd5e99c8d5d4..1299eba99d7d 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
_pkgname=ptvsd
pkgname=python-$_pkgname
pkgver=4.3.2
-pkgrel=3
+pkgrel=4
pkgdesc="Python debugger package for use with Visual Studio and Visual Studio Code"
url="https://github.com/microsoft/$_pkgname"
license=("MIT")
@@ -14,8 +14,31 @@ sha1sums=('0ea052d12c5f78e676194c8ef3a476fe76d29ea8')
package() {
cd $_pkgname-$pkgver
- PIP_CONFIG_FILE=/dev/null pip install --isolated --root="$pkgdir" \
- --ignore-installed --no-deps .
+
+ _vers="$pkgver-$pkgrel"
+ sed -i "/version=/s/=.*/=\'$_vers\',/" setup.py
+
+ PIP_CONFIG_FILE=/dev/null pip install --root="$pkgdir" \
+ --quiet \
+ --isolated \
+ --ignore-installed \
+ --disable-pip-version-check \
+ --no-python-version-warning \
+ --no-compile \
+ --no-cache-dir \
+ --no-deps \
+ --no-binary=:all: \
+ .
+
+ local pdir=$(python -c "import site; print(site.getsitepackages()[0])")
+ cd "$pkgdir/$pdir"
+ rm -rf $_pkgname-*.dist-info
+ cd "$_pkgname"
+
+ sed -i "/\"version\":/s/\"[^\"]*\"$/\"$_vers\"/" _version.py
+
+ # Ignore failures on legacy python2 files ..
+ python -O -m compileall -qq . || true
}
# vim:set ts=2 sw=2 et: