summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMark Blakeney2022-10-10 09:52:48 +1000
committerMark Blakeney2022-10-10 09:52:48 +1000
commitd2739b9db88e136d4881fa27e6b172a1ffd1a92c (patch)
tree0336e822bd3dcb6324ebded708f5442886852e99
parent882e4784ddacfed71437741c9a19abec5a64aacc (diff)
downloadaur-d2739b9db88e136d4881fa27e6b172a1ffd1a92c.tar.gz
Simplify PKGBUILD
-rw-r--r--.SRCINFO5
-rw-r--r--.gitignore2
-rw-r--r--PKGBUILD33
3 files changed, 13 insertions, 27 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 10fbc5b4e3a8..823079bc966a 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -5,11 +5,12 @@ pkgbase = gnucash-asx-fetch
url = https://github.com/bulletmark/gnucash-asx-fetch
arch = any
license = GPL3
- makedepends = python-pip
+ makedepends = python-setuptools
+ makedepends = python-build
+ makedepends = python-installer
makedepends = python-wheel
depends = python>=3.6
source = gnucash-asx-fetch-1.5.tar.gz::https://github.com/bulletmark/gnucash-asx-fetch/archive/1.5.tar.gz
sha1sums = 8db2ae38705ffc6935382006eb3c383493bd5492
pkgname = gnucash-asx-fetch
-
diff --git a/.gitignore b/.gitignore
index 6dd39bbd03b8..3c084c24bc7b 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,4 +1,4 @@
pkg/
src/
-*.tar
+*.tar*
*.[gx]z
diff --git a/PKGBUILD b/PKGBUILD
index bb4c06d069d8..dd1449ae270e 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -4,36 +4,21 @@ pkgver=1.5
pkgrel=1
pkgdesc="Utility to fetch and add current ASX prices to one or more gnucash XML files"
url="https://github.com/bulletmark/$pkgname"
-license=("GPL3")
-arch=("any")
+license=(GPL3)
+arch=(any)
depends=("python>=3.6")
-makedepends=("python-pip" "python-wheel")
+makedepends=(python-setuptools python-build python-installer python-wheel)
source=("$pkgname-$pkgver.tar.gz::$url/archive/$pkgver.tar.gz")
sha1sums=('8db2ae38705ffc6935382006eb3c383493bd5492')
-package() {
+build() {
cd "$srcdir/$pkgname-$pkgver"
+ python -m build --wheel --no-isolation
+}
- PIP_CONFIG_FILE=/dev/null pip install \
- --root="$pkgdir" \
- --isolated \
- --ignore-installed \
- --no-deps \
- --disable-pip-version-check \
- --no-python-version-warning \
- --no-warn-script-location \
- --no-cache-dir \
- --no-compile \
- --progress-bar=off \
- --root-user-action=ignore \
- .
-
- local pdir=$(python -c "import site; print(site.getsitepackages()[0])")
- local _pkgname="${pkgname//-/_}"
- cd "$pkgdir/$pdir"
- rm -f $_pkgname-*.dist-info/direct_url.json
- sed -i "/\/direct_url.json,/d" $_pkgname-*.dist-info/RECORD
- python -O -m compileall -q .
+package() {
+ cd "$srcdir/$pkgname-$pkgver"
+ python -m installer --destdir="$pkgdir" dist/*.whl
}
# vim:set ts=2 sw=2 et: