PKGBUILD 1.04 KB
Newer Older
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 35 36 37 38
# Contributions from Arch:
# Maintainer: Massimiliano Torromeo <massimiliano.torromeo@gmail.com>
# Contributor: frank AT apsu DOT be

pkgbase=libmaxminddb
pkgname=(libmaxminddb mmdblookup)
pkgver=1.3.2
pkgrel=1
pkgdesc="MaxMind GeoIP2 database - split package with library and utilities"
license=('Apache')
arch=('x86_64')
url="https://dev.maxmind.com/geoip/geoip2/downloadable/"
source=("https://github.com/maxmind/$pkgbase/releases/download/$pkgver/$pkgbase-$pkgver.tar.gz")
sha256sums=('e6f881aa6bd8cfa154a44d965450620df1f714c6dc9dd9971ad98f6e04f6c0f0')

build() {
	cd "$srcdir"/$pkgbase-$pkgver
	./configure --prefix=/usr
	make
}

package_libmaxminddb() {
	pkgdesc="MaxMindDB GeoIP2 database library"
	depends=('glibc')

	cd "$srcdir"/$pkgbase-$pkgver
	make PREFIX=/usr DESTDIR="$pkgdir" install
	rm -rf "$pkgdir"/usr/{bin,share/man/man1}
}

package_mmdblookup() {
	pkgdesc="MaxMindDB GeoIP2 lookup utility"
	depends=('libmaxminddb')

	cd "$srcdir"/$pkgbase-$pkgver
	make PREFIX=/usr DESTDIR="$pkgdir" install
	rm -rf "$pkgdir"/usr/{lib,include,share/man/man3}
}