[Slackbuilds-users] Dictionary localization of openoffice.org slackbuild

Halim Issa yallaone at gmail.com
Sat Sep 23 11:05:15 UTC 2006


While openoffice.org comes with quite a few dictionaries, it for instance
misses the Scandinavian languages, while it installs several dictionaries
that only non-native speakers of those languages use (Italian, Hungarian).
I've added a small part to openoffice.org.SlackBuild to include local
dictionaries while removing all but the English (US and UK) dictionaries in
the final installation.

I realize this goes against the concept of providing non-patched packages,
 but at the same time a change _is_ needed to add for instance Norwegian
 dicts, and at the same time I have little use for Italian, Spanish etc, and
 thus took those out.

Adding the patch below - the actual dictionaries-file is 1.3MB so it's not

diff -Naur openoffice.org.SlackBuild.SBo 

--- openoffice.org.SlackBuild.SBo       2006-09-08 17:30:43.000000000 +0200
+++ openoffice.org.SlackBuild.gfj       2006-09-23 12:18:31.000000000 +0200
@@ -33,6 +33,7 @@

 # Require the script to exit if any command fails
 set -e
@@ -97,6 +98,18 @@

+# Add localized dictionaries and remove other dictionaries
+( if [ -f $CWD/$LOCALIZATION.tgz ]; then
+    echo "Localizing for $LOCALIZATION..."
+    cd $PKG/opt/openoffice.org2.0/share/dict/ooo
+    mv README_en_GB.txt keep_README_en_GB.txt
+    rm -f README* INSTALL_de.txt de_* hu_* it_* nl_* sw_* th_* hyph_d*
hyph_i* hyph_n* hyph_r*
+    mv keep_README_en_GB.txt README_en_GB.txt
+    mv dictionary.lst dictionary.lst.orig
+    tar xvf $CWD/$LOCALIZATION.tgz
+  fi
 mkdir -p $PKG/install
 cat $CWD/slack-desc > $PKG/install/slack-desc

The norwegian-2.0.8.tgz file contains:
-r--r--r-- root/root       800 2006-09-23 11:41:06 dictionary.lst
-rw-r--r-- root/root    186678 2006-05-30 13:23:23 hyph_nb_NO.dic
-rw-r--r-- root/root    186678 2006-05-30 13:23:23 hyph_nn_NO.dic
-rw-r--r-- root/root     16898 2006-05-30 13:23:21 nb_NO.aff
-rw-r--r-- root/root   2119161 2006-05-30 13:23:21 nb_NO.dic
-rw-r--r-- root/root     13502 2006-05-30 13:23:22 nn_NO.aff
-rw-r--r-- root/root   1548984 2006-05-30 13:23:22 nn_NO.dic
-rw-r--r-- root/root    136676 2006-05-30 17:15:07 th_nb_NO_v2.dat
-rw-r--r-- root/root     44209 2006-05-30 17:15:07 th_nb_NO_v2.idx

(Norwegian dictionaries consist of both nb and nn, as stupid little Norway of 
4 million inhabitants has two  (actually three) different official 
languages - our tax dollars at work...)

More information about the Slackbuilds-users mailing list