summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 4858cf13c5573115c63a3d3ae06c5a74320aa0ac (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
# Maintainer: Dringsim <dringsim@qq.com>

pkgname=rime-dieghv
pkgver=0.0.0.20190211
_commit=1709bb786a144de7be2229755011fde9034457de
pkgrel=2
pkgdesc="Rime schema for Teochew dialect"
arch=('x86_64')
url="https://github.com/kahaani/dieghv"
license=('GPL3')
# dependency for reverse lookup
depends=('rime-luna-pinyin')
makedepends=('librime' 'rime-prelude' 'rime-essay')
source=("$url/archive/$_commit/dieghv-$_commit.tar.gz")
md5sums=('756386d338eb71b64a0691d0136ba9bb')

prepare() {
  cd dieghv-$_commit
  # Link essentials
  for _f in $(pacman -Qql rime-prelude rime-essay | grep -v "/$"); do ln -sf $_f; done
 cp ./60/*.schema.yaml .
 cp ./mtr/*.schema.yaml .
}

build(){
  cd dieghv-$_commit
  for _s in $(ls *.schema.yaml); do rime_deployer --compile $_s; done
}

package() {
  cd dieghv-$_commit
  find . -type l -delete
  rm build/*.txt
  install -Dm644 *.yaml -t "$pkgdir"/usr/share/rime-data/
  install -Dm644 build/* -t "$pkgdir"/usr/share/rime-data/build/
  #install -Dm644 opencc/* -t "$pkgdir"/usr/share/rime-data/opencc/
}