diff options
author | Dhaby Xiloj <slack.dhabyx@gmail.com> | 2017-02-10 19:10:21 +0700 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2017-02-10 19:10:21 +0700 |
commit | 5c24d410d086bde26dc3af6e1cf1fecdee199c2a (patch) | |
tree | e15520be88702eb70a56e0ff7e77f8f4b2cdae92 /office/hunspell-es/hunspell-es.SlackBuild | |
parent | a406cf485f22a721593a431b05a8c96bf908fd6c (diff) |
office/hunspell-es: Updated for version 2.2 + new maintainer.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'office/hunspell-es/hunspell-es.SlackBuild')
-rw-r--r-- | office/hunspell-es/hunspell-es.SlackBuild | 49 |
1 files changed, 43 insertions, 6 deletions
diff --git a/office/hunspell-es/hunspell-es.SlackBuild b/office/hunspell-es/hunspell-es.SlackBuild index 04080d26bbd1b..a80bc5dc48c3f 100644 --- a/office/hunspell-es/hunspell-es.SlackBuild +++ b/office/hunspell-es/hunspell-es.SlackBuild @@ -2,7 +2,8 @@ # Slackware build script for hunspell-es -# Copyright 2014, Pablo Santamaria (pablosantamaria@gmail.com) +# Copyright 2017 Dhaby Xiloj <slack.dhabyx@gmail.com> +# Copyright 2014-2017 Pablo Santamaria (pablosantamaria@gmail.com) # All rights reserved. # # Redistribution and use of this script, with or without modification, is @@ -25,7 +26,7 @@ # Based on the Arch PKGBUILD PRGNAM=hunspell-es -VERSION=${VERSION:-7.1} +VERSION=${VERSION:-2.2} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} ARCH="noarch" @@ -35,6 +36,10 @@ TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM OUTPUT=${OUTPUT:-/tmp} +# Getting all localizations available +LOCALIZATIONS=*.oxt +LOCALIZATIONS=$(echo $LOCALIZATIONS | sed -e 's/es_ANY.oxt//g' | sed -e 's/.oxt//g') + set -e rm -rf $PKG @@ -45,21 +50,53 @@ mkdir -p $PRGNAM-$VERSION cd $PRGNAM-$VERSION for file in $CWD/*.oxt ; do - unzip -B $file + LANG=en_US.utf8 bsdtar -xf $file done +# Putting everything in proper place install -dm755 $PKG/usr/share/hunspell install -m644 es_*.dic es_*.aff $PKG/usr/share/hunspell +install -Dm644 hyph_es_ANY.dic $PKG/usr/share/hyphen/hyph_es_ANY.dic +install -dm755 $PKG/usr/share/mythes +install -m644 th_es_ES_v2.* $PKG/usr/share/mythes +# Symlinks for ditcs install -dm755 $PKG/usr/share/myspell/dicts pushd $PKG/usr/share/myspell/dicts -for file in $PKGDIR/usr/share/hunspell/*; do + for file in $PKG/usr/share/hunspell/*; do ln -sv ../../hunspell/$(basename $file) . -done + done +popd + +# Hypernation symlinks +pushd $PKG/usr/share/hyphen/ + echo $LOCALIZATIONS + for lang in $LOCALIZATIONS; do + ln -sv hyph_es_ANY.dic hyph_${lang}.dic + done +popd + +# Thesaurus symlinks +pushd $PKG/usr/share/mythes/ + for lang in $(echo $LOCALIZATIONS | sed -e 's/es_ES//g'); do + ln -sv th_es_ES_v2.idx th_${lang}_v2.idx + ln -sv th_es_ES_v2.dat th_${lang}_v2.dat + done +popd + +# myspell symlinks +install -dm755 $PKG/usr/share/myspell/dicts +pushd $PKG/usr/share/myspell/dicts + for file in $PKG/usr/share/hyphen/*; do + ln -sv ../../hyphen/$(basename $file) . + done + for file in $PKG/usr/share/mythes/*; do + ln -sv ../../mythes/$(basename $file) . + done popd mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION -install -m644 README.txt $PKG/usr/doc/$PRGNAM-$VERSION +install -m644 README* COPYING* $PKG/usr/doc/$PRGNAM-$VERSION cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild mkdir -p $PKG/install |