diff options
author | Philipp Joram | 2023-05-16 12:45:49 +0300 |
---|---|---|
committer | Philipp Joram | 2023-05-16 12:45:49 +0300 |
commit | e0f7151735a9857c4fd5ddac4ca9d26c25a33a6d (patch) | |
tree | fd871a85c3d7943a58113ee01c763affc6400727 /PKGBUILD | |
parent | 31f8bfc6e363f4a64ad132df5ae3ea888e6fdd83 (diff) | |
download | aur-e0f7151735a9857c4fd5ddac4ca9d26c25a33a6d.tar.gz |
Update to version 1.8.1
The source package is no longer available on PyPI, install from the
provided wheel package instead.
Diffstat (limited to 'PKGBUILD')
-rw-r--r-- | PKGBUILD | 27 |
1 files changed, 13 insertions, 14 deletions
@@ -2,30 +2,29 @@ pkgname='python-dacite' _name=${pkgname#python-} -pkgver=1.8.0 +pkgver=1.8.1 pkgrel=1 pkgdesc="Simplify creation of data classes (PEP 557) from dictionaries." url="https://github.com/konradhalas/dacite" arch=('any') license=('MIT') depends=('python') -makedepends=('python-setuptools') -source=("https://files.pythonhosted.org/packages/source/${_name::1}/$_name/$_name-$pkgver.tar.gz" - "LICENSE" # License file is not included in PyPI tarball. +makedepends=('python-installer') +source=("https://files.pythonhosted.org/packages/py3/${_name::1}/$_name/${_name//-/_}-$pkgver-py3-none-any.whl" ) -sha512sums=('7e9ebf7da56aa8e65d5a5f0576a0e268344ee40459bdcde2560d17e90d4b73f660ce9dbec3ab5377100f42a21ad8698019b5b6f4fa03ddcd959af5ebb261b465' - 'e6962f48291088edaf156bcb8c3be115e3695c5f90c367e2a60f6061ce8f9be42472be6b4d20b8ecdd610c7143935b9b8e838e2e9236a07c8f706b69fddfa2a7') - -build() { - cd "${_name}-${pkgver}" - python setup.py build -} +sha512sums=('747c8566b5ea6d68234fe8715d0a926ac9a916693e824841ee00338a3e1fbaac0632567b03f20cd6425a18facb434b9f3671a47a1f8d6d2a78aed8767d0d7f3f' + ) +noextract=("${_name}-${pkgver}-py3-none-any.whl") package() { - cd "${_name}-${pkgver}" - python setup.py install --root="$pkgdir" --optimize=1 + # Source package is not available on PyPI; use provided wheel package instead. + python -m installer --destdir="$pkgdir" "${srcdir}/${_name}-${pkgver}-py3-none-any.whl" - install -Dm644 "${srcdir}/LICENSE" "$pkgdir/usr/share/licenses/$pkgname/LICENSE" + # Symlink license file (cf. PKGBUILD for python-black) + local site_packages=$(python -c "import site; print(site.getsitepackages()[0])") + install -d "${pkgdir}/usr/share/licenses/${pkgname}" + ln -s "${site_packages}/${_name}-${pkgver}.dist-info/LICENSE" \ + "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" } # vim:set ts=2 sw=2 et: |