- Accumulate environment variables, to be used later to run some command in proper environment.
This commit is contained in:
mpa 2013-10-29 08:07:30 +00:00
parent 483bcee37f
commit b998652209
4 changed files with 19 additions and 2 deletions

View File

@ -50,7 +50,7 @@ ELSE(EXISTS ${KERNEL_ROOT_DIR})
ENDIF(EXISTS ${KERNEL_ROOT_DIR})
IF(SALOME_LIGHT_ONLY)
MESSAGE(FATAL_ERROR "GEOM module can't be built in Light mode (whiout CORBA)")
MESSAGE(FATAL_ERROR "GEOM module can't be built in Light mode (without CORBA)")
ENDIF()
# Platform setup
@ -197,6 +197,12 @@ MARK_AS_ADVANCED(SALOME_INSTALL_PYTHON SALOME_INSTALL_PYTHON_SHARED)
MARK_AS_ADVANCED(SALOME_GEOM_INSTALL_RES_DATA SALOME_GEOM_INSTALL_RES_SCRIPTS SALOME_GEOM_INSTALL_PLUGINS)
MARK_AS_ADVANCED(SALOME_INSTALL_AMCONFIG_LOCAL SALOME_INSTALL_DOC)
# Accumulate environment variables for GEOM 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
# ========
ADD_SUBDIRECTORY(idl)

View File

@ -46,6 +46,9 @@ SET_AND_CHECK(GEOM_INCLUDE_DIRS "${GEOM_ROOT_DIR_EXP}/@SALOME_INSTALL_HEADERS@")
SET(GEOM_INCLUDE_DIRS "${GEOM_INCLUDE_DIRS};@_SalomeGEOM_EXTRA_HEADERS@")
SET(GEOM_DEFINITIONS "@KERNEL_DEFINITIONS@")
# Package specific environment variables
@_SalomeGEOM_EXTRA_ENV_FULL@
#### Now the specificities
# Options exported by the package:

View File

@ -29,3 +29,7 @@ SALOME_FIND_PACKAGE(SalomeGEOM SalomeGEOM CONFIG)
IF(NOT SalomeGEOM_FIND_QUIETLY)
MESSAGE(STATUS "Found Salome GEOM: ${GEOM_ROOT_DIR}")
ENDIF()
FOREACH(_res ${SalomeGEOM_EXTRA_ENV})
SALOME_ACCUMULATE_ENVIRONMENT(${_res} "${SalomeGEOM_EXTRA_ENV_${_res}}")
ENDFOREACH()

View File

@ -19,9 +19,13 @@
# Author: Adrien Bruneton
#
# OpenCV detection dor Salome
# OpenCV detection for Salome
#
# !! Please read the generic detection procedure in SalomeMacros.cmake !!
#
SALOME_FIND_PACKAGE_AND_DETECT_CONFLICTS(OpenCV OpenCV_DIR 2)
#MARK_AS_ADVANCED()
IF(OpenCV_FOUND)
SALOME_ACCUMULATE_ENVIRONMENT(LD_LIBRARY_PATH ${OpenCV_LIBRARIES})
ENDIF()