diff options
author | Julien Nabet <serval2412@yahoo.fr> | 2016-11-27 19:39:41 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2016-12-05 09:16:01 +0000 |
commit | c5c7c011120b95bc782f200f1c46984d1e413e5d (patch) | |
tree | d4467fae5c91537b4e96707f15a14271383acae4 | |
parent | e1dcbd0f7f6bacafcbdb6e74d29af2151120bc6f (diff) |
tdf#101603: fix lgnpath for MacOs in LibreLogo
Change-Id: I280b6cd02a98037a71701a6a7a540c87de22d07f
Reviewed-on: https://gerrit.libreoffice.org/31268
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
(cherry picked from commit ab3b5b0dfb0c92aa5e94a0f417950724c694ac57)
Reviewed-on: https://gerrit.libreoffice.org/31270
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r-- | librelogo/source/LibreLogo/LibreLogo.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/librelogo/source/LibreLogo/LibreLogo.py b/librelogo/source/LibreLogo/LibreLogo.py index b7077e107668..7885ab9bb66d 100644 --- a/librelogo/source/LibreLogo/LibreLogo.py +++ b/librelogo/source/LibreLogo/LibreLogo.py @@ -21,8 +21,12 @@ urebootstrap = os.environ["URE_BOOTSTRAP"] if "vnd.sun.star.pathname" in urebootstrap: __lngpath__ = re.sub(r"^vnd.sun.star.pathname:(.*)program(/|\\)fundamental([.]ini|rc)$", "\\1", urebootstrap) else: - __lngpath__ = unohelper.fileUrlToSystemPath(re.sub("program/(fundamental.ini|fundamentalrc)$", "", urebootstrap)) -__lngpath__ = __lngpath__ + "share/Scripts/python/LibreLogo/".replace("/", os.sep) + # A way to know if we use MacOs + if "Resources" in urebootstrap: + __lngpath__ = unohelper.fileUrlToSystemPath(re.sub("fundamentalrc$", "", urebootstrap)) + else: + __lngpath__ = unohelper.fileUrlToSystemPath(re.sub("program/(fundamental.ini|fundamentalrc)$", "share", urebootstrap)) +__lngpath__ = __lngpath__ + "/Scripts/python/LibreLogo/".replace("/", os.sep) __translang__ = "am|ca|cs|de|dk|el|en|eo|es|et|fr|hu|it|ja|nl|no|pl|pt|ru|se|sl" # FIXME supported languages for language guessing, expand this list, according to the localizations __lng__ = {} __docs__ = {} |