PKGBUILDs/extra/python-protobuf/PKGBUILD
BrainDamage af81df1c4a
added extra/python-protobuf (#2041)
added a note to protobuf package to keep both packages updated in lockstep

Co-authored-by: BrainDamage <braindamage@archlinux.org>
2024-07-02 18:32:28 -06:00

29 lines
904 B
Bash

# ALARM: BrainDamage <braindamage@archlinux.org>
# - use pypi tarball as source
# - use normal python toolchain to build
pkgname=python-protobuf
_basename=protobuf
pkgver=27.2
_ver=5
pkgrel=1
pkgdesc="Protocol Buffers - Google's data interchange format"
arch=('aarch64' 'armv7h')
url='https://developers.google.com/protocol-buffers/'
license=('BSD')
depends=('python' "protobuf=${pkgver}")
makedepends=('python-build' 'python-installer' 'python-wheel')
source=("https://files.pythonhosted.org/packages/source/${_basename::1}/${_basename}/${_basename}-${_ver}.${pkgver}.tar.gz")
sha256sums=('f3ecdef226b9af856075f28227ff2c90ce3a594d092c39bee5513573f25e2714')
build() {
cd "${_basename}-${_ver}.${pkgver}"
export PYTHONHASHSEED=0
python -m build --wheel --no-isolation
}
package() {
cd "${_basename}-${_ver}.${pkgver}"
python -m installer --compile-bytecode 1 --destdir="${pkgdir}" dist/*.whl
}