archrelease: copy trunk to extra-x86_64
[arch-packages.git] / hspell / trunk / PKGBUILD
blob62ce744539d7c13dac83c1312ab830abdbc3cdab
1 # Maintainer: Tobias Powalowski <tpowa@archlinux.org>
3 pkgbase=hspell
4 pkgname=('hspell' 'hunspell-he')
5 pkgver=1.4
6 pkgrel=4
7 arch=('x86_64')
8 license=('GPL')
9 url="http://www.ivrix.org.il/projects/spell-checker/"
10 makedepends=('glibc' 'zlib' 'perl' 'hunspell' 'gawk' 'qt6-webengine')
11 options=('!makeflags')
12 source=(http://hspell.ivrix.org.il/${pkgname}-${pkgver}.tar.gz{,.sig})
13 sha256sums=('7310f5d58740d21d6d215c1179658602ef7da97a816bc1497c8764be97aabea3'
14             'SKIP')
15 validpgpkeys=('996512CD85DC510BD45EAD46415E26D84D4E37DB')
17 build() {
18   cd ${pkgname}-${pkgver}
19   export PERLLIB="$PWD"
20   ./configure --prefix=/usr --mandir=/usr/share/man \
21       --enable-linginfo --enable-fatverb --enable-shared
22   make 
23   make hunspell
26 package_hspell() {
28   pkgdesc="Hebrew spell-checker"
29   depends=('glibc' 'zlib' 'perl')
31   cd ${pkgname}-${pkgver}
32   make DESTDIR="${pkgdir}" install
34   rm -f "${pkgdir}"/usr/lib/libhspell.a
37 package_hunspell-he() {
39   pkgdesc="Hebrew hunspell dictionary"
40   
41   cd ${pkgbase}-${pkgver}
43   install -dm755 "$pkgdir"/usr/share/hunspell
44   install -m644 he.dic "$pkgdir"/usr/share/hunspell/he_IL.dic
45   install -m644 he.aff "$pkgdir"/usr/share/hunspell/he_IL.aff
47   # the symlinks
48   install -dm755 "$pkgdir"/usr/share/myspell/dicts
49   pushd "$pkgdir"/usr/share/myspell/dicts
50     for file in "$pkgdir"/usr/share/hunspell/*; do
51       ln -sv /usr/share/hunspell/$(basename $file) .
52     done
53   popd
55 # Install webengine dictionaries   
56   install -d "$pkgdir"/usr/share/qt{,6}/qtwebengine_dictionaries/
57   for _file in "$pkgdir"/usr/share/hunspell/*.dic; do
58   _filename=$(basename $_file)
59     /usr/lib/qt6/qwebengine_convert_dict $_file "$pkgdir"/usr/share/qt6/qtwebengine_dictionaries/${_filename/\.dic/\.bdic}
60   ln -rs "$pkgdir"/usr/share/qt6/qtwebengine_dictionaries/${_filename/\.dic/\.bdic} "$pkgdir"/usr/share/qt/qtwebengine_dictionaries/
61   done