From: vsr Date: Wed, 2 Nov 2011 13:22:55 +0000 (+0000) Subject: Fix make distcheck error X-Git-Tag: V6_4_0b1~14 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=0553338fc0f4755f62b17569ddef0dfa5931be99;p=modules%2Fsmesh.git Fix make distcheck error --- diff --git a/doc/docutils/Makefile.am b/doc/docutils/Makefile.am index eeec2fbf9..ce019ed0c 100644 --- a/doc/docutils/Makefile.am +++ b/doc/docutils/Makefile.am @@ -38,9 +38,17 @@ SPHINXBUILD = sphinx-build PAPEROPT_a4 = -D latex_paper_size=a4 ALLSPHINXOPTS = -d doctrees $(PAPEROPT_a4) $(SPHINXOPTS) $(SOURCEDIR) +if SMESH_ENABLE_GUI +SPHINX_PYTHONPATH = $(prefix)/lib/python$(PYTHON_VERSION)/site-packages/salome:$(prefix)/lib64/python$(PYTHON_VERSION)/site-packages/salome:$(GUI_ROOT_DIR)/lib/salome:$(GUI_ROOT_DIR)/lib/python$(PYTHON_VERSION)/site-packages/salome:$(GUI_ROOT_DIR)/lib64/python$(PYTHON_VERSION)/site-packages/salome:$(KERNEL_ROOT_DIR)/bin/salome:$(KERNEL_ROOT_DIR)/lib/python$(PYTHON_VERSION)/site-packages/salome:$(KERNEL_ROOT_DIR)/lib64/python$(PYTHON_VERSION)/site-packages/salome:$(OMNIORB_ROOT)/lib/python$(PYTHON_VERSION)/site-packages:$(OMNIORB_ROOT)/lib64/python$(PYTHON_VERSION)/site-packages +else !SMESH_ENABLE_GUI SPHINX_PYTHONPATH = $(prefix)/lib/python$(PYTHON_VERSION)/site-packages/salome:$(prefix)/lib64/python$(PYTHON_VERSION)/site-packages/salome:$(KERNEL_ROOT_DIR)/bin/salome:$(KERNEL_ROOT_DIR)/lib/python$(PYTHON_VERSION)/site-packages/salome:$(KERNEL_ROOT_DIR)/lib64/python$(PYTHON_VERSION)/site-packages/salome:$(OMNIORB_ROOT)/lib/python$(PYTHON_VERSION)/site-packages:$(OMNIORB_ROOT)/lib64/python$(PYTHON_VERSION)/site-packages +endif +if SMESH_ENABLE_GUI +SPHINX_LD_LIBRARY_PATH = $(GUI_ROOT_DIR)/lib/salome:$(KERNEL_ROOT_DIR)/lib/salome:$(OMNIORB_ROOT)/lib +else !SMESH_ENABLE_GUI SPHINX_LD_LIBRARY_PATH = $(KERNEL_ROOT_DIR)/lib/salome:$(OMNIORB_ROOT)/lib +endif .PHONY: latex diff --git a/src/SMESH_PY/smeshstudytools.py b/src/SMESH_PY/smeshstudytools.py index ed21fd317..1f9cdd5b5 100644 --- a/src/SMESH_PY/smeshstudytools.py +++ b/src/SMESH_PY/smeshstudytools.py @@ -27,7 +27,10 @@ import salome SMESH = None # SMESH module is loaded only when needed from salome.kernel.studyedit import getStudyEditor -from salome.gui import helper +try: + from salome.gui import helper +except ImportError: + pass class SMeshStudyTools: """