From: John Mandereau Date: Tue, 22 Apr 2008 11:51:41 +0000 (+0200) Subject: Don't print warning for lp-book use outside Lily docs X-Git-Tag: release/2.11.45-1~20^2~2 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=8a846c41a0f1c5256025f07adcfafeb45c93b8f6;p=lilypond.git Don't print warning for lp-book use outside Lily docs --- diff --git a/python/langdefs.py b/python/langdefs.py index d8bd17c286..80a1c7f244 100644 --- a/python/langdefs.py +++ b/python/langdefs.py @@ -7,6 +7,7 @@ Documentation i18n module import re import sys +import os def lang_file_name (p, langext, ext): if langext != '': @@ -66,7 +67,6 @@ else: try: import gettext - import os translation = {} for l in LANGUAGES: @@ -76,5 +76,6 @@ else: [l.code]) translation[l.code] = t.gettext except: - sys.stderr.write ('langdefs.py: warning: lilypond-doc gettext domain not found.\n') + if os.environ.has_key ('LYDOC_LOCALEDIR'): + sys.stderr.write ('langdefs.py: warning: lilypond-doc gettext domain not found.\n') translation = dict ([(l.code, lambda x: x) for l in LANGUAGES])