~alpine/aports

testing/libpostal: fix building on non-x86 platforms v1 PROPOSED

Export patchset (mbox)
How do I use this?

Copy & paste the following snippet into your terminal to import this patchset into git:

curl -s https://lists.alpinelinux.org/~alpine/aports/%3C20190907204705.1900-1-bribbers%40disroot.org%3E/mbox | git am -3
Learn more about email & git

[PATCH] testing/libpostal: fix building on non-x86 platforms Export this patch

Bart Ribbers
---
 testing/libpostal/APKBUILD | 13 ++++++++++---
 1 file changed, 10 insertions(+), 3 deletions(-)

diff --git a/testing/libpostal/APKBUILD b/testing/libpostal/APKBUILD
index ae57cb2d5c..b94bdda822 100644
--- a/testing/libpostal/APKBUILD
+++ b/testing/libpostal/APKBUILD
@@ -5,7 +5,7 @@ pkgver=1.0.0
 pkgrel=0
 pkgdesc="A C library for parsing/normalizing street addresses around the world"
 url="https://github.com/openvenues/libpostal"
-arch="x86_64 x86"
+arch="all"
 license="MIT"
 makedepends="autoconf automake libtool"
 subpackages="$pkgname-static $pkgname-dev"
@@ -18,11 +18,18 @@ prepare() {
 	./bootstrap.sh
 }
 
-build() {
+build() {	
+	case "$CARCH" in
+		x86|x86_64) sse2="--enable-sse2" ;;
+		*) sse2="--disable-sse2";;
+	esac
+
 	./configure \
 		--prefix=/usr \
 		--datadir=/usr/local/share \
-		--disable-data-download
+		--disable-data-download \
+		$sse2
+
 	make
 }
 
-- 
2.23.0
View this thread in the archives