# Contributor: Bhushan Shah # Maintainer: Bart Ribbers pkgname=libphonenumber pkgver=8.13.17 pkgrel=1 pkgdesc="Library for parsing, formatting, and validating international phone numbers." url="https://github.com/google/libphonenumber" arch="all" license="Apache-2.0" depends_dev=" abseil-cpp-dev icu-dev protobuf-dev " makedepends="$depends_dev cmake gtest-dev ninja " checkdepends="icu-data-full" subpackages="$pkgname-static libgeocoding $pkgname-dev" source="https://github.com/google/libphonenumber/archive/v$pkgver/libphonenumber-v$pkgver.tar.gz system-abseil.patch c++17.patch " build() { cd cpp LDFLAGS="$LDFLAGS -Wl,--copy-dt-needed-entries" \ cmake -B build -G Ninja \ -DCMAKE_BUILD_TYPE=None \ -DCMAKE_INSTALL_PREFIX=/usr \ -DCMAKE_INSTALL_LIBDIR=lib \ -DREGENERATE_METADATA=OFF \ -DUSE_BOOST=OFF \ -DUSE_STDMUTEX=ON cmake --build build } check() { cd cpp ./build/libphonenumber_test } package() { cd cpp DESTDIR="$pkgdir" cmake --install build } libgeocoding() { amove usr/lib/libgeocoding.so.* } sha512sums=" b1ec99aa952558d2ba26d95d7c1bdfd8169f992b3190cc4236e1ce17e69db50ef2839b2840a9553541e09c7509b77c463a1036f84251844ec71bd5888ef78555 libphonenumber-v8.13.17.tar.gz 03c1eb32208a868bcacf92eb42b1f3f009bcc898fa6446594a3e79baadbef5fb53bbe829adfb7d0c8ebebdd37898c6686ff837320d258cd47ef5de7a6bf341bc system-abseil.patch a8fb8cf592f3bd8c6b7c3bd3771fdb83e39dec2e546f6071074dfc27857ab0d39523086455b8626d8f1c90069eddf61568d9fc698923c20cbf398bcc4bb9a3f8 c++17.patch "