From 577e214dc098dd8ab500a1bbb2c80578a4bd56fe Mon Sep 17 00:00:00 2001 From: mpa Date: Thu, 31 Oct 2013 07:50:39 +0000 Subject: [PATCH] CMake: Add for checking an argument that this is not a standard system path (starting with "/bin" and "/lib") --- salome_adm/cmake_files/SalomeMacros.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/salome_adm/cmake_files/SalomeMacros.cmake b/salome_adm/cmake_files/SalomeMacros.cmake index 658e3f688..38e29a210 100755 --- a/salome_adm/cmake_files/SalomeMacros.cmake +++ b/salome_adm/cmake_files/SalomeMacros.cmake @@ -680,10 +680,10 @@ MACRO(SALOME_ACCUMULATE_ENVIRONMENT envvar) IF(TARGET ${_item}) GET_TARGET_PROPERTY(_item ${_item} LOCATION) ENDIF() - GET_FILENAME_COMPONENT(_item ${_item} PATH) + GET_FILENAME_COMPONENT(_item ${_item} PATH) ENDIF() IF(EXISTS ${_item}) - STRING(REGEX MATCH "^/usr" _usr_find ${_item}) + STRING(REGEX MATCH "^(/usr|/lib|/bin)" _usr_find ${_item}) LIST(FIND _${PROJECT_NAME}_EXTRA_ENV_${envvar} ${_item} _res) IF(NOT _usr_find AND _res EQUAL -1) LIST(APPEND _${PROJECT_NAME}_EXTRA_ENV_${envvar} ${_item}) -- 2.39.2