Created
January 18, 2018 16:44
-
-
Save akhenakh/4fcff56f37a023f9f3bfd628f60c18fc to your computer and use it in GitHub Desktop.
s2 geometry arch AUR pkg
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Maintainer: Fabrice aneche <akh@nobugware.com> | |
pkgname=s2geometry-git | |
pkgver=r136 | |
pkgrel=1 | |
pkgdesc="Computational geometry and spatial indexing on the sphere" | |
arch=('i686' 'x86_64') | |
url="https://s2geometry.io/" | |
license=('APACHE2') | |
depends=('openssl-1.0' 'gflags' 'google-glog' 'python') | |
makedepends=('git' 'cmake') | |
source=("git+https://github.com/google/s2geometry.git") | |
sha256sums=('SKIP') | |
pkgver() { | |
cd "$srcdir/s2geometry" | |
printf "r%s" "$(git rev-list --count HEAD)" | |
} | |
build() { | |
cd "$srcdir/s2geometry" | |
mkdir -p build | |
cd build | |
cmake -DCMAKE_INSTALL_PREFIX=/usr -DOPENSSL_INCLUDE_DIR="/usr/include/openssl-1.0" -DOPENSSL_SSL_LIBRARY="/usr/lib/openssl-1.0/libssl.so" -DOPENSSL_CRYPTO_LIBRARY="/usr/lib/openssl-1.0/libcrypto.so" .. | |
make | |
} | |
package() { | |
cd "$srcdir/s2geometry/build" | |
make DESTDIR="$pkgdir/" install | |
SITE_PACKAGE=`python -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())"` | |
mkdir -p "$pkgdir/$SITE_PACKAGE" | |
install -m 644 python/pywraps2.py "$pkgdir/$SITE_PACKAGE/pywraps2.py" | |
install -m 644 python/_pywraps2.so "$pkgdir/$SITE_PACKAGE/_pywraps2.so" | |
rm $pkgdir/usr/share/python/pywraps2.py | |
rm $pkgdir/usr/share/python/_pywraps2.so | |
rmdir $pkgdir/usr/share/python | |
rmdir $pkgdir/usr/share | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment