summaryrefslogtreecommitdiff
path: root/functions/l10n.sh
diff options
context:
space:
mode:
Diffstat (limited to 'functions/l10n.sh')
-rwxr-xr-xfunctions/l10n.sh21
1 files changed, 15 insertions, 6 deletions
diff --git a/functions/l10n.sh b/functions/l10n.sh
index dfb22cb57..a1125ec44 100755
--- a/functions/l10n.sh
+++ b/functions/l10n.sh
@@ -7,9 +7,18 @@
# This is free software, and you are welcome to redistribute it
# under certain conditions; see COPYING for details.
-# gettext domain (.mo file name)
-export TEXTDOMAIN=live-helper
-# locale dir for gettext codes
-export TEXTDOMAINDIR=/usr/share/locale
-# load gettext functions
-. gettext.sh
+if [ -x "$(which gettext.sh 2>/dev/null)" ]
+then
+ LH_L10N="enabled"
+
+ # gettext domain (.mo file name)
+ export TEXTDOMAIN="live-helper"
+
+ # locale dir for gettext codes
+ export TEXTDOMAINDIR="/usr/share/locale"
+
+ # load gettext functions
+ . gettext.sh
+else
+ LH_L10N="disabled"
+fi