blob: 6c76099211976aed60943820837418ee23c46685 (
plain)
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
|
# Contributor: Eric Kidd <git@randomhacks.net>
# Maintainer: Holger Jaekel <holger.jaekel@gmx.de>
pkgname=geos
pkgver=3.8.1
pkgrel=1
pkgdesc="GEOS is a library providing OpenGIS and JTS spatial operations in C++."
url="https://trac.osgeo.org/geos/"
arch="all !s390x !mips !mips64"
license="LGPL-2.1-or-later"
makedepends="
swig
python3-dev
ruby-dev
"
subpackages="
py3-$pkgname:py3
ruby-$pkgname:ruby
$pkgname-dev
"
source="
http://download.osgeo.org/geos/geos-$pkgver.tar.bz2
10-configure-python3.patch
20-ruby27.patch
"
build() {
case "$CARCH" in
aarch64*|ppc64le) CXXFLAGS="$CXXFLAGS -ffp-contract=off" ;;
esac
# fix build on armhf and armv7 with info from
# https://trac.osgeo.org/geos/ticket/993
local inline="--enable-inline"
case "$CARCH" in
armhf|armv7) inline="--disable-inline" ;;
esac
./configure \
--build=$CBUILD \
--host=$CHOST \
--prefix=/usr \
--sysconfdir=/etc \
--mandir=/usr/share/man \
--localstatedir=/var \
$inline \
--enable-python \
--enable-ruby
make
}
check() {
make check
}
package() {
make DESTDIR="$pkgdir" install
find $pkgdir -name "*.a" -type f -delete
}
py3() {
pkgdesc="$pkgname Python3 bindings"
install -d "$subpkgdir"/usr/lib
mv "$pkgdir"/usr/lib/python* "$subpkgdir"/usr/lib/
}
ruby() {
pkgdesc="$pkgname Ruby bindings"
install -d "$subpkgdir"/usr/lib/ruby/vendor_ruby
mv "$pkgdir"/usr/local/lib/site_ruby/* "$subpkgdir"/usr/lib/ruby/vendor_ruby
rm -rf "${pkgdir:?}"/usr/local
}
sha512sums="1d8d8b3ece70eb388ea128f4135c7455899f01828223b23890ad3a2401e27104efce03987676794273a9b9d4907c0add2be381ff14b8420aaa9a858cc5941056 geos-3.8.1.tar.bz2
a76aceadb30c6a078ef9c671d8335647bd6b94094bd4bdda5958f0d50271552e8f1f7b4e9d4295986f4371a446071c3cc3a446ef520543e820bde83833fea18e 10-configure-python3.patch
964d9001e49ac3bec415c36cf3d536f4e959b800fd6770344eca6c58e9bc7bfa23c2722422ffb3677c231a00b5d758e6657ba13e9f8920eb530d71eaa03f989e 20-ruby27.patch"
|