- Accumulate environment variables, to be used later to run some command in proper environment.
MARK_AS_ADVANCED(SALOME_INSTALL_AMCONFIG_LOCAL SALOME_INSTALL_DOC)
MARK_AS_ADVANCED(SALOME_SMESH_INSTALL_RES_DATA SALOME_SMESH_INSTALL_PLUGINS)
+# Accumulate environment variables for SMESH module
+SALOME_ACCUMULATE_ENVIRONMENT(PYTHONPATH ${CMAKE_INSTALL_PREFIX}/${SALOME_INSTALL_BINS}
+ ${CMAKE_INSTALL_PREFIX}/${SALOME_INSTALL_PYTHON}
+ ${CMAKE_INSTALL_PREFIX}/${SALOME_INSTALL_PYTHON_SHARED})
+SALOME_ACCUMULATE_ENVIRONMENT(LD_LIBRARY_PATH ${CMAKE_INSTALL_PREFIX}/${SALOME_INSTALL_LIBS})
+
# Sources
# ========
SET(SMESH_INCLUDE_DIRS "${SMESH_INCLUDE_DIRS};@_SalomeSMESH_EXTRA_HEADERS@")
SET(SMESH_DEFINITIONS "@GEOM_DEFINITIONS@")
+# Package specific environment variables
+@_SalomeSMESH_EXTRA_ENV_FULL@
+
#### Now the specificities
# Options exported by the package:
SALOME_FIND_PACKAGE_AND_DETECT_CONFLICTS(CGNS CGNS_INCLUDE_DIRS 1)
MARK_AS_ADVANCED(CGNS_INCLUDE_DIRS CGNS_LIBRARIES)
-SALOME_ACCUMULATE_HEADERS(CGNS_INCLUDE_DIRS)
+IF(CGNS_FOUND)
+ SALOME_ACCUMULATE_HEADERS(CGNS_INCLUDE_DIRS)
+ SALOME_ACCUMULATE_ENVIRONMENT(PATH ${CGNS_ROOT_DIR}/bin)
+ SALOME_ACCUMULATE_ENVIRONMENT(LD_LIBRARY_PATH ${CGNS_ROOT_DIR}/lib)
+ENDIF()
\ No newline at end of file
IF(NOT SalomeSMESH_FIND_QUIETLY)
MESSAGE(STATUS "Found Salome SMESH: ${SMESH_ROOT_DIR}")
ENDIF()
+
+FOREACH(_res ${SalomeSMESH_EXTRA_ENV})
+ SALOME_ACCUMULATE_ENVIRONMENT(${_res} "${SalomeSMESH_EXTRA_ENV_${_res}}")
+ENDFOREACH()
\ No newline at end of file
SALOME_FIND_PACKAGE_AND_DETECT_CONFLICTS(TBB TBB_INCLUDE_DIRS 2)
MARK_AS_ADVANCED(TBB_INCLUDE_DIRS TBB_LIBRARIES)
-SALOME_ACCUMULATE_HEADERS(TBB_INCLUDE_DIRS)
+IF(TBB_FOUND)
+ SALOME_ACCUMULATE_HEADERS(TBB_INCLUDE_DIRS)
+ SALOME_ACCUMULATE_ENVIRONMENT(PATH ${TBB_ROOT_DIR}/bin/intel64/cc4.1.0_libc2.4_kernel2.6.16.21)
+ SALOME_ACCUMULATE_ENVIRONMENT(LD_LIBRARY_PATH ${TBB_LIBRARIES})
+ENDIF()
\ No newline at end of file
SALOME_FIND_PACKAGE_AND_DETECT_CONFLICTS(f2c f2c_INCLUDE_DIRS 0)
MARK_AS_ADVANCED(F2C_INCLUDE_DIRS F2C_LIBRARIES F2C_GENERATOR)
-SALOME_ACCUMULATE_HEADERS(F2C_INCLUDE_DIRS)
\ No newline at end of file
+IF(F2C_FOUND)
+ SALOME_ACCUMULATE_HEADERS(F2C_INCLUDE_DIRS)
+ SALOME_ACCUMULATE_ENVIRONMENT(LD_LIBRARY_PATH ${F2C_LIBRARIES})
+ENDIF()
\ No newline at end of file