From: Clarisse GENRAULT - DEN/DANS/DM2S/STMF/LGLS - 2012/10/01 Date: Wed, 30 Oct 2019 09:33:20 +0000 (+0100) Subject: Update CMakeList X-Git-Tag: V9_4_0rc1~3 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=c0cee5003965b64812634bc5e7fde9f455c666a2;p=modules%2Fgui.git Update CMakeList --- diff --git a/tools/CMakeLists.txt b/tools/CMakeLists.txt index 502ff86c2..a8fd75747 100644 --- a/tools/CMakeLists.txt +++ b/tools/CMakeLists.txt @@ -18,6 +18,7 @@ # ADD_SUBDIRECTORY(dlgfactory) +ADD_SUBDIRECTORY(CurvePlot) ## # Python-based packages, part 1 (generic) diff --git a/tools/CurvePlot/CMakeLists.txt b/tools/CurvePlot/CMakeLists.txt index 45c12f8f1..718b71b6d 100644 --- a/tools/CurvePlot/CMakeLists.txt +++ b/tools/CurvePlot/CMakeLists.txt @@ -66,15 +66,21 @@ IF(NOT SALOME_CURVEPLOT_STANDALONE) MESSAGE(FATAL_ERROR "We absolutely need a Salome KERNEL, please define KERNEL_ROOT_DIR or turn option SALOME_CURVEPLOT_STANDALONE to ON!") ENDIF( EXISTS ${KERNEL_ROOT_DIR} ) - # Find SALOME GUI (needed for the C++ part - PyUtils) # ============== SET(GUI_ROOT_DIR $ENV{GUI_ROOT_DIR} CACHE PATH "Path to the Salome GUI") - IF(EXISTS ${GUI_ROOT_DIR}) - LIST(APPEND CMAKE_MODULE_PATH "${GUI_ROOT_DIR}/adm_local/cmake_files") - FIND_PACKAGE(SalomeGUI) - ELSE(EXISTS ${GUI_ROOT_DIR}) - MESSAGE(FATAL_ERROR "We absolutely need a Salome GUI, please define GUI_ROOT_DIR or turn option SALOME_CURVEPLOT_STANDALONE to ON!") - ENDIF(EXISTS ${GUI_ROOT_DIR}) + # Are we compiled being into GUI/tools directory or have we been extracted somewhere else? + IF(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/../../src/Session/SALOME_Session.hxx") # we are in GUI + LIST(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/../../adm_local/cmake_files") + # Re-define GUI_INCLUDE_DIRS + SET(GUI_INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/../PyInterp/src) + ELSE() + IF(EXISTS ${GUI_ROOT_DIR}) + LIST(APPEND CMAKE_MODULE_PATH "${GUI_ROOT_DIR}/adm_local/cmake_files") + FIND_PACKAGE(SalomeGUI) + ELSE() + MESSAGE(FATAL_ERROR "We absolutely need a Salome GUI, please define GUI_ROOT_DIR or turn option SALOME_CURVEPLOT_STANDALONE to ON!") + ENDIF() + ENDIF() # Platform setup # ==============