This allows us to include a version and we already use PURL for other things, so might as well remove the pypi special case. Normalize the names, since that is required for PURLs.
36 lines
975 B
Bash
36 lines
975 B
Bash
# Maintainer: Christoph Reiter <reiter.christoph@gmail.com>
|
|
|
|
_realname=installer
|
|
pkgname="python-${_realname}"
|
|
pkgver=0.7.0
|
|
pkgrel=2
|
|
pkgdesc="A low-level library for installing from a Python wheel distribution"
|
|
arch=('any')
|
|
url='https://github.com/pypa/installer'
|
|
msys2_references=(
|
|
"purl: pkg:pypi/installer"
|
|
)
|
|
license=('spdx:MIT')
|
|
depends=("python")
|
|
makedepends=(
|
|
"python-flit-core"
|
|
)
|
|
source=("${_realname}-$pkgver.tar.gz"::"https://pypi.org/packages/source/${_realname::1}/${_realname}/${_realname}-${pkgver}.tar.gz")
|
|
sha256sums=('a26d3e3116289bb08216e0d0f7d925fcef0b0194eedfa0c944bcaaa106c4b631')
|
|
|
|
build() {
|
|
cd "${srcdir}/${_realname}-${pkgver}"
|
|
|
|
python -m flit_core.wheel
|
|
}
|
|
|
|
package() {
|
|
cd "${srcdir}/${_realname}-${pkgver}"
|
|
|
|
PYTHONPATH="${srcdir}/${_realname}-${pkgver}/src" \
|
|
python -m installer --destdir="${pkgdir}" dist/*.whl
|
|
|
|
# remove windows entrypoint scripts executables
|
|
rm "$pkgdir"/usr/lib/python*/site-packages/installer/_scripts/*.exe
|
|
}
|