2012-02-23 12:52:26 +08:00
|
|
|
pkgname=libpinyin
|
2017-08-30 20:48:49 +08:00
|
|
|
pkgver=2.1.0
|
2016-08-21 01:19:17 +08:00
|
|
|
pkgrel=1
|
2016-12-16 09:59:10 +08:00
|
|
|
_modelver=14
|
2012-02-23 12:52:26 +08:00
|
|
|
pkgdesc="Library to deal with pinyin."
|
2014-04-19 07:00:32 +08:00
|
|
|
arch=('x86_64')
|
2012-02-23 12:52:26 +08:00
|
|
|
url="https://github.com/libpinyin/libpinyin"
|
|
|
|
license=('GPL')
|
2017-08-30 20:48:49 +08:00
|
|
|
depends=('kyotocabinet' 'glib2')
|
|
|
|
makedepends=('gnome-common')
|
|
|
|
source=("$pkgname-$pkgver.tar.gz::https://github.com/$pkgname/$pkgname/archive/$pkgver.tar.gz"
|
|
|
|
"$pkgname-model$_modelver.text.tar.gz::http://downloads.sourceforge.net/libpinyin/model$_modelver.text.tar.gz")
|
|
|
|
noextract=("$pkgname-model$_modelver.text.tar.gz")
|
|
|
|
sha256sums=('d6ce0da926cb3485fa4b2e3805d49674a96a55e0cde9d31d57afb2626cbc32c6'
|
2016-12-16 09:59:10 +08:00
|
|
|
'185f0f175a90bcfc55cf3cf6ceff8d447a6269492c0ca1a1fc0748ea2c181363')
|
2012-02-23 12:52:26 +08:00
|
|
|
|
2017-08-30 20:48:49 +08:00
|
|
|
prepare() {
|
|
|
|
cd $pkgname-$pkgver
|
2016-12-16 09:59:10 +08:00
|
|
|
|
2017-08-30 20:48:49 +08:00
|
|
|
ln -s "$srcdir"/$pkgname-model$_modelver.text.tar.gz data/model$_modelver.text.tar.gz
|
|
|
|
sed -i "/wget.*model$_modelver\.text\.tar\.gz/ d" data/Makefile.am
|
|
|
|
}
|
2016-12-16 09:59:10 +08:00
|
|
|
|
2017-08-30 20:48:49 +08:00
|
|
|
build() {
|
|
|
|
cd $pkgname-$pkgver
|
|
|
|
./autogen.sh --prefix=/usr --with-dbm=KyotoCabinet --enable-libzhuyin
|
|
|
|
make
|
2012-02-23 12:52:26 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
package() {
|
2017-08-30 20:48:49 +08:00
|
|
|
cd $pkgname-$pkgver
|
|
|
|
make DESTDIR="$pkgdir" install
|
2012-02-23 12:52:26 +08:00
|
|
|
}
|