# Maintainer: Jan de Groot <jgc@archlinux.org>
# Contributor: Angel Velasquez <angvp@archlinux.org>

pkgname=python-geoip
pkgver=1.3.2
pkgrel=19
pkgdesc='Python bindings for the GeoIP IP-to-country resolver library'
arch=(x86_64 aarch64)
url='https://pypi.org/project/GeoIP/'
license=(LGPL-2.1-only)
depends=(
  python
  geoip
)
makedepends=(
  python-build
  python-installer
  python-setuptools
  python-wheel
)
source=("$pkgname-$pkgver.tar.gz::https://pypi.python.org/packages/source/G/GeoIP/GeoIP-$pkgver.tar.gz")
sha512sums=('313af794d839e83408b40573566fb55483c1ddd663a7919b54751bc9da85cf855f9eb17d8fdb641702740da5c5d79d79d3d7f15b82fa88092f780d0c667c4e7a')
b2sums=('1c2cd64f1a62062e7a6bde04fcdb98bbafd415693d7f5ec41613a386419084ee362d5dfe5c6bb614b82fa6db9444fa8a59d14203f7c753f14651410267435757')

build() {
  cd "GeoIP-$pkgver"

  python -m build --wheel --no-isolation
}

package() {
  cd "GeoIP-$pkgver"

  python -m installer --destdir="$pkgdir" dist/*.whl
}
# vim:set ts=2 sw=2 et:
