blob: b7d2c7ed4ad5c7625603cea7f32e8a70158ef12b (
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
|
# Maintainer: Yuanji <self@gimo.me>
pkgname=mecab-ipadic-neologd-git
_pkgname=mecab-ipadic-neologd
pkgver=r20200716
pkgrel=1
pkgdesc="Neologism dictionary for MeCab"
arch=('any')
url="https://github.com/neologd/mecab-ipadic-neologd"
license=('Apache')
depends=('mecab' 'mecab-ipadic')
source=("git+https://github.com/neologd/mecab-ipadic-neologd.git")
makedepends=('git')
sha512sums=('SKIP')
prepare() {
cd "$srcdir/${_pkgname}"
# change hardcoded mecab libexecdir.
sed -i 's!`${MECAB_PATH}-config --libexecdir`!${MECAB_DIC_DIR%/dic}!g' libexec/make-mecab-ipadic-neologd.sh
# `file` command can't work in fakeroot environment.
sed -i 's!xargs file!sed "s/$/:/"!' libexec/make-mecab-ipadic-neologd.sh
}
pkgver() {
cd "$srcdir/${_pkgname}"
printf "r%s" "$(git log -1 --format=%cd --date=format:%Y%m%d)"
}
package() {
cd "$srcdir/${_pkgname}"
./bin/install-mecab-ipadic-neologd -p "$pkgdir$(mecab-config --dicdir)/${_pkgname}" -n -u -y
}
|