aboutsummaryrefslogtreecommitdiffstats
path: root/testing/hfst/APKBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'testing/hfst/APKBUILD')
-rw-r--r--testing/hfst/APKBUILD72
1 files changed, 34 insertions, 38 deletions
diff --git a/testing/hfst/APKBUILD b/testing/hfst/APKBUILD
index 03feba521ea..625c91c8479 100644
--- a/testing/hfst/APKBUILD
+++ b/testing/hfst/APKBUILD
@@ -2,29 +2,25 @@
# Contributor: Frankie Robertson <frankie@robertson.name>
# Maintainer:
pkgname=hfst
-pkgver=3.9.1
-pkgrel=0
+pkgver=3.16.0
+pkgrel=1
pkgdesc="Helsinki Finite-State Transducer Technology toolkit"
-url="http://www.ling.helsinki.fi/kieliteknologia/tutkimus/$pkgname/"
-arch="" # Fails to build
-license="LGPL-3.0"
-depends=""
-depends_dev=""
-makedepends="$depends_dev python2 bison python2-dev swig"
-install=""
-subpackages="$pkgname-dev $pkgname-doc py-$pkgname:py"
-source="https://downloads.sourceforge.net/$pkgname/$pkgname-$pkgver.tar.gz
- missing_unistd_include.patch"
-
-_builddir="$srcdir"/$pkgname-$pkgver
-prepare() {
- cd "$_builddir"
- default_prepare || return 1
- update_config_sub || return 1
-}
+url="https://hfst.github.io/"
+arch="all"
+license="LGPL-3.0-or-later"
+makedepends="
+ bison
+ icu-dev
+ py3-gpep517
+ py3-setuptools
+ py3-wheel
+ python3-dev
+ swig
+ "
+subpackages="$pkgname-dev $pkgname-doc py3-$pkgname:py3 $pkgname-libs"
+source="https://github.com/hfst/hfst/releases/download/v$pkgver/hfst-$pkgver.tar.gz"
build() {
- cd "$_builddir"
./configure \
--build=$CBUILD \
--host=$CHOST \
@@ -36,30 +32,30 @@ build() {
--without-foma \
--enable-lexc \
--enable-all-tools \
- || return 1
- make -j1 || return 1
+ --disable-static \
+ PYTHON=python3
+ make
+
+ cd python
+ gpep517 build-wheel \
+ --wheel-dir .dist \
+ --output-fd 3 3>&1 >&2
}
package() {
- cd "$_builddir"
- make DESTDIR="$pkgdir" install || return 1
+ make DESTDIR="$pkgdir" install
- cd python || return 1
- python2 setup.py install \
- --prefix=/usr --root="$pkgdir" || return 1
+ cd python
+ python3 -m installer -d "$pkgdir" .dist/*.whl
}
-py() {
- pkgdesc="$pkgdesc (python bindings)"
- depends="python2"
+py3() {
+ pkgdesc="$pkgdesc (python3 bindings)"
+ depends="python3"
- mkdir -p "$subpkgdir"/usr/lib/
- cp -r "$pkgdir"/usr/lib/python2* "$subpkgdir"/usr/lib/
+ amove usr/lib/python3*
}
-md5sums="3d7a54b6ce67d180545d599b7d9fa7c9 hfst-3.9.1.tar.gz
-4aef69581668aa22cf1e93cbd6493030 missing_unistd_include.patch"
-sha256sums="fa55eab71d86ffebe75ed28476d76cb6bcde51dbc73064a8ef1db7112d2985ec hfst-3.9.1.tar.gz
-158d633416a482308f420c6d9e3c8648f96238fc7209d70055e629a0ff978b80 missing_unistd_include.patch"
-sha512sums="2d0d4acd132cb4a41c4a1f259b2556ac3ce352158ad88ea2312d056e1942dd2d5d0968e86ee62e00aca36fb757371657d0466132ae3576b70962f5313357df44 hfst-3.9.1.tar.gz
-0bfc63709dbefaaa4084bf78d169283a58ab4ee586e800446f5d92ee179d4c84959802f54e72ffa5366c49a2a30883deb54c562c9dcace21662d5cbdd06789d6 missing_unistd_include.patch"
+sha512sums="
+7c12b8641cd22f1c550c26741d5f46e8a9e1fbd3f9a8b462ce500e38ddac9641e33c59fe3d3474de5499217896fc056605da5fc9bd564fbac254c9949a80f36b hfst-3.16.0.tar.gz
+"