From: asl Date: Thu, 4 Mar 2010 09:20:04 +0000 (+0000) Subject: SUIT_ENABLE_PYTHON should be defined only if Python Console is used X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=abf4e510d644dc523d81909de7c02f22cf3c33e1;p=modules%2Fgui.git SUIT_ENABLE_PYTHON should be defined only if Python Console is used --- diff --git a/configure.ac b/configure.ac index a666c53d5..2e7bc0c5b 100644 --- a/configure.ac +++ b/configure.ac @@ -573,6 +573,11 @@ AM_CONDITIONAL(ENABLE_SALOMEOBJECT, [test "$DISABLE_SALOMEOBJECT" = no]) AM_CONDITIONAL(ENABLE_QXGRAPHVIEWER, [test "$DISABLE_QXGRAPHVIEWER" = no]) AM_CONDITIONAL(ENABLE_TESTRECORDER, [test "$ENABLE_TESTRECORDER" = yes]) +if test "$DISABLE_PYCONSOLE" = "no" ; then + AC_DEFINE(SUIT_ENABLE_PYTHON) +fi + + echo echo --------------------------------------------- echo generating Makefiles and configure files diff --git a/src/SUITApp/Makefile.am b/src/SUITApp/Makefile.am index 5c1f44e36..90658bad8 100644 --- a/src/SUITApp/Makefile.am +++ b/src/SUITApp/Makefile.am @@ -29,13 +29,18 @@ include $(top_srcdir)/adm_local/unix/make_common_starter.am lib_LTLIBRARIES = libSUITApp.la salomeinclude_HEADERS = \ - SUITApp_Application.h \ - SUITApp_init_python.hxx + SUITApp_Application.h +if ENABLE_PYCONSOLE + salomeinclude_HEADERS += SUITApp_init_python.hxx +endif dist_libSUITApp_la_SOURCES = \ SUITApp.cxx \ - SUITApp_Application.cxx \ - SUITApp_init_python.cxx + SUITApp_Application.cxx + +if ENABLE_PYCONSOLE + dist_libSUITApp_la_SOURCES += SUITApp_init_python.cxx +endif MOC_FILES = \ SUITApp_Application_moc.cxx @@ -62,7 +67,6 @@ libSUITApp_la_LIBADD = ../Qtx/libqtx.la ../SUIT/libsuit.la ../Style/libSalomeS if ENABLE_PYCONSOLE libSUITApp_la_LDFLAGS += -Xlinker -export-dynamic $(PYTHON_LIBS) -AM_CPPFLAGS+=-DSUIT_ENABLE_PYTHON endif # Executable diff --git a/src/SUITApp/SUITApp.cxx b/src/SUITApp/SUITApp.cxx index 604eff9c5..4fcc6dc35 100644 --- a/src/SUITApp/SUITApp.cxx +++ b/src/SUITApp/SUITApp.cxx @@ -32,7 +32,7 @@ // or make sure Python is initialized in main() in any case // Otherwise, application based on light SALOME and using Python // are unlikely to work properly. -#define SUIT_ENABLE_PYTHON +//#define SUIT_ENABLE_PYTHON #include #endif