blob: 7e586f953f3830190875a1f51dc9994805b2ae10 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
pkgname=papis-zotero
pkgver=0.2
pkgrel=2
pkgdesc='Zotero remote server for papis'
arch=('any')
url='https://github.com/papis/papis-zotero'
license=('GPL')
depends=('python' 'papis')
makedepends=(python-build python-installer python-wheel python-hatchling)
source=("https://github.com/papis/${pkgname}/archive/v${pkgver}.tar.gz")
sha256sums=('9da67265180c320950ddf662500316e2e6de178876a30a93fc2dc8a5b7335015')
_dirname="${pkgname}-${pkgver}"
_basename="${pkgname}"
build() {
cd "${srcdir}/${_dirname}"
export PYTHONHASHSEED=0
python -m build --wheel --no-isolation
}
package() {
cd "${srcdir}/${_dirname}"
find dist -name '*.whl' \
-exec python -m installer --compile-bytecode 1 --destdir="${pkgdir}" {} \;
# not necessary for every package, but for those who it is, it'd generate conflict with others otherwise
rm -rf "${pkgdir}/$(python -c 'import site; print(site.getsitepackages()[0])')/tests/"
find . -maxdepth 1 -iname 'README*' \
-exec install -Dvm 644 -t "${pkgdir}/usr/share/doc/${_basename}" {} +
find . -maxdepth 1 -iname 'LICENSE*' \
-exec install -Dvm 644 -t "${pkgdir}/usr/share/licenses/${_basename}" {} +
}
|