diff options
author | Antoine Bolvy | 2017-01-10 19:23:13 -0500 |
---|---|---|
committer | Antoine Bolvy | 2017-01-10 19:23:13 -0500 |
commit | c175a763ab7693c593783887b1c6faaf479bd3d3 (patch) | |
tree | 88c80a569400321a622e881ff74cde7bc02722c2 | |
download | aur-c175a763ab7693c593783887b1c6faaf479bd3d3.tar.gz |
Initial release
-rw-r--r-- | .SRCINFO | 18 | ||||
-rw-r--r-- | PKGBUILD | 33 | ||||
-rw-r--r-- | libpostal-git.install | 18 |
3 files changed, 69 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..62d9ab17ceb4 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,18 @@ +pkgbase = libpostal-git + pkgdesc = A C library for parsing/normalizing street addresses around the world. Powered by statistical NLP and open geo data. (git version) + pkgver = v0.3.3.r0.g577f26e4 + pkgrel = 1 + url = https://github.com/openvenues/libpostal + install = libpostal-git.install + arch = any + license = MIT + makedepends = git + depends = curl + depends = snappy + provides = libpostal + conflicts = libpostal + source = git://github.com/openvenues/libpostal.git + md5sums = SKIP + +pkgname = libpostal-git + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..802ab351a738 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,33 @@ +# Maintainer: Antoine Bolvy <antoine.bolvy@gmail.com> + +pkgname="libpostal-git" +pkgrel=1 +pkgver=v0.3.3.r0.g577f26e4 +pkgdesc="A C library for parsing/normalizing street addresses around the world. Powered by statistical NLP and open geo data. (git version)" +arch=("any") +url="https://github.com/openvenues/${pkgname%-git}" +license=('MIT') +makedepends=('git') +depends=('curl' 'snappy') +provides=("${pkgname%-git}") +conflicts=("${pkgname%-git}") +source=("git://github.com/openvenues/${pkgname%-git}.git") +md5sums=('SKIP') +install="${pkgname}.install" + +pkgver() { + cd "${pkgname%-git}" + git describe --long --tags 2>/dev/null | sed 's/\([^-]*-g\)/r\1/;s/-/./g' +} + +build() { + cd "${pkgname%-git}" + ./bootstrap.sh + ./configure --disable-data-download --prefix=/usr --datadir=/usr/local/share + make +} + +package() { + ls -r + make -C "${pkgname%-git}" DESTDIR="${pkgdir}" install +} diff --git a/libpostal-git.install b/libpostal-git.install new file mode 100644 index 000000000000..d9a8fcb35861 --- /dev/null +++ b/libpostal-git.install @@ -0,0 +1,18 @@ +post_install() { + echo ":: You need to download libpostal's trained data to " + echo " /usr/local/share/libpostal prior using this library." + echo " This can be done with the libpostal_data command, e.g.:" + echo " libpostal_data download all /usr/local/share/libpostal" +} + +post_upgrade() { + echo ":: You might want to update libpostal's trained data." + echo " This can be done with the libpostal_data command, e.g.:" + echo " libpostal_data download all /usr/local/share/libpostal" +} + +post_remove() { + echo ":: You might still have libpostal's trained data located in" + echo " /usr/local/share/libpostal (usually manually downloaded)" + echo " You should be able to safely remove this directory." +} |