INCLUDE(FindSUIT)
INCLUDE(FindTInspector)
-IF(${HAVE_SALOME})
+IF(HAVE_SALOME)
SET(CONFIGURATION_ROOT_DIR $ENV{CONFIGURATION_ROOT_DIR} CACHE PATH "Path to the Salome CMake configuration files")
IF(EXISTS ${CONFIGURATION_ROOT_DIR})
- LIST(APPEND CMAKE_MODULE_PATH "${CONFIGURATION_ROOT_DIR}/cmake")
+ SET(CMAKE_MODULE_PATH "${CONFIGURATION_ROOT_DIR}/cmake" ${CMAKE_MODULE_PATH})
INCLUDE(SalomeMacros)
INCLUDE(FindSalomeQt5)
ELSE()
ENDIF()
SET(KERNEL_ROOT_DIR $ENV{KERNEL_ROOT_DIR} CACHE PATH "Path to the Salome KERNEL")
IF(EXISTS ${KERNEL_ROOT_DIR})
- LIST(APPEND CMAKE_MODULE_PATH "${KERNEL_ROOT_DIR}/salome_adm/cmake_files")
FIND_PACKAGE(SalomeKERNEL REQUIRED)
ADD_DEFINITIONS(${KERNEL_DEFINITIONS})
INCLUDE_DIRECTORIES(${KERNEL_INCLUDE_DIRS})
ENDIF(EXISTS ${KERNEL_ROOT_DIR})
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}/salome_adm/cmake_files")
FIND_PACKAGE(SalomeGUI REQUIRED)
+ ELSE(EXISTS ${GUI_ROOT_DIR})
+ MESSAGE(FATAL_ERROR "We absolutely need a Salome GUI, please define GUI_ROOT_DIR")
ENDIF(EXISTS ${GUI_ROOT_DIR})
INCLUDE(SalomeSetupPlatform) # From CONFIGURATION
FIND_PACKAGE(SalomeOpenCASCADE REQUIRED)
-ELSE(${HAVE_SALOME})
+ELSE()
INCLUDE(SalomeMacros)
INCLUDE(FindSalomeQt5)
INCLUDE(FindPython)
INCLUDE(FindSalomeOpenCASCADE)
-ENDIF(${HAVE_SALOME})
+ENDIF()
# Common CMake macros
# ===================