aboutsummaryrefslogtreecommitdiffstats
path: root/testing/omorfi/APKBUILD
blob: 80393f1083b1d771f30ea068332d0bb06d706d8f (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
# Contributor: Frankie Robertson <frankie@robertson.name>
# Maintainer:
pkgname=omorfi
pkgver=20150326
pkgrel=0
pkgdesc="Open morphology for Finnish"
url="https://github.com/flammie/omorfi"
arch="noarch"
license="GPL3"
depends="hfst bash"
depends_dev=""
makedepends="$depends_dev autoconf automake libtool zip hfst-python3"
install=""
subpackages="ormofi-doc omorfi-utils omorfi-voikko omorfi-python3"
source="https://github.com/flammie/omorfi/archive/$pkgver.tar.gz"

_builddir="$srcdir/$pkgname-$pkgver"
prepare() {
	local i
	cd "$_builddir"
	for i in $source; do
		case $i in
		*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
		esac
	done
}

build() {
	cd "$_builddir"
	./autogen.sh
	./configure --prefix=/usr \
		|| return 1
	make || return 1
}

package() {
	cd "$_builddir"
	make DESTDIR="$pkgdir" install || return 1
	rm -f "$pkgdir"/usr/lib/*.la
	rm -rf "$pkgdir"/usr/share/pkgconfig
}

utils() {
	depends="bash"
	mkdir -p "$subpkgdir"/usr/
	cp -r "$pkgdir"/usr/bin "$subpkgdir"/usr/
}

voikko() {
	depends="voikko"
	mkdir -p "$subpkgdir"/usr/lib/
	cp -r "$pkgdir"/usr/lib/voikko "$subpkgdir"/usr/lib/
}

python3() {
	depends="python3"
	mkdir -p "$subpkgdir"/usr/lib/
	cp -r "$pkgdir"/usr/lib/python3* "$subpkgdir"/usr/lib/
}

md5sums="6a3e7b16c85e78c0ce0e5214c2e8db7d  20150326.tar.gz"
sha256sums="359d34c93ef07d5852d53774da3454ab649d8d22b8f22bb4a7910dbaae8db82f  20150326.tar.gz"
sha512sums="618884ec8909efa23a4f77df0a934056dee4a7d235285a108381d0c5ce62d941cc7ff55f788a1618e3257a7541193fd661e1c6c78a71606473c88d68cc73ea78  20150326.tar.gz"