summaryrefslogtreecommitdiff
path: root/community/libpinyin/PKGBUILD
blob: 2243af6c038fba74adc820052d5496bf391683e0 (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
# $Id: PKGBUILD 88087 2013-04-11 09:30:02Z fyan $
# Maintainer: Felix Yan <felixonmars@gmail.com>
# Contributor: Yangtse <yangtsesu@gmail.com> 
# Contributor: WU Jun <quark at lihdd dot net>

pkgname=libpinyin
pkgver=0.9.0
pkgrel=1
pkgdesc="Library to deal with pinyin"
arch=('i686' 'x86_64' 'mips64el')
url="https://github.com/libpinyin/libpinyin"
license=('GPL')
depends=('db' 'glib2')
options=(!libtool)
source=("https://github.com/libpinyin/libpinyin/archive/${pkgver}.tar.gz"
        "http://downloads.sourceforge.net/libpinyin/model5.text.tar.gz")
noextract=("model5.text.tar.gz")

build() {
  cd "${srcdir}/${pkgname}-${pkgver}"

  cp "${srcdir}/model5.text.tar.gz" "${srcdir}/${pkgname}-${pkgver}/data/"
  sed -i '/wget.*model5\.text\.tar\.gz/ d' ${srcdir}/${pkgname}-${pkgver}/data/Makefile.am

  aclocal && libtoolize --force && autoheader && automake -a && autoconf
  ./configure --prefix=/usr && make
}

package() {
  cd "${srcdir}/libpinyin-$pkgver"
  make DESTDIR="${pkgdir}" install
}
md5sums=('e2237be88c6b9f1ed4f7c6e75a1738b4'
         'a83812e2d3be5695be54f95d9d7a3aa0')