- Accumulate environment variables, to be used later to run some command in proper environment.
This commit is contained in:
mpa 2013-10-29 08:32:59 +00:00
parent 5bd4251de9
commit ae1e664d2a
6 changed files with 27 additions and 3 deletions

View File

@ -240,6 +240,12 @@ MARK_AS_ADVANCED(SALOME_INSTALL_PYTHON SALOME_INSTALL_PYTHON_SHARED)
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
# ========

View File

@ -46,6 +46,9 @@ SET_AND_CHECK(SMESH_INCLUDE_DIRS "${SMESH_ROOT_DIR_EXP}/@SALOME_INSTALL_HEADERS@
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:

View File

@ -20,4 +20,8 @@
SALOME_FIND_PACKAGE_AND_DETECT_CONFLICTS(CGNS CGNS_INCLUDE_DIRS 1)
MARK_AS_ADVANCED(CGNS_INCLUDE_DIRS CGNS_LIBRARIES)
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()

View File

@ -29,3 +29,7 @@ SALOME_FIND_PACKAGE(SalomeSMESH SalomeSMESH CONFIG)
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()

View File

@ -20,4 +20,8 @@
SALOME_FIND_PACKAGE_AND_DETECT_CONFLICTS(TBB TBB_INCLUDE_DIRS 2)
MARK_AS_ADVANCED(TBB_INCLUDE_DIRS TBB_LIBRARIES)
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()

View File

@ -20,4 +20,7 @@
SALOME_FIND_PACKAGE_AND_DETECT_CONFLICTS(f2c f2c_INCLUDE_DIRS 0)
MARK_AS_ADVANCED(F2C_INCLUDE_DIRS F2C_LIBRARIES F2C_GENERATOR)
IF(F2C_FOUND)
SALOME_ACCUMULATE_HEADERS(F2C_INCLUDE_DIRS)
SALOME_ACCUMULATE_ENVIRONMENT(LD_LIBRARY_PATH ${F2C_LIBRARIES})
ENDIF()