From 477fb26c1ef458b6b552c7ac42bd0f18a483770f Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Fri, 18 Jun 2010 17:38:21 -0400 Subject: Centralize LD_LIBRARY_PATH logic with new SET_TEST_PATH macro. Add ${SHARED_LIB_STAGING_DIR_RELEASE} to LD_LIBRARY_PATH for executing tests: otherwise Debug-build tests can't find (e.g.) the aprutil DLL, for which we don't build/package a debug variant. Leverage discovery that a CMake macro can accept a target variable name argument for LL_TEST_COMMAND macro. --- indra/cmake/LLSharedLibs.cmake | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'indra/cmake/LLSharedLibs.cmake') diff --git a/indra/cmake/LLSharedLibs.cmake b/indra/cmake/LLSharedLibs.cmake index 6f602680f4..b32a46b736 100644 --- a/indra/cmake/LLSharedLibs.cmake +++ b/indra/cmake/LLSharedLibs.cmake @@ -5,7 +5,7 @@ macro(ll_deploy_sharedlibs_command target_exe) get_filename_component(OUTPUT_PATH ${TARGET_LOCATION} PATH) if(DARWIN) - set(SEARCH_DIRS "${SHARED_LIB_STAGING_DIR}/${CMAKE_CFG_INTDIR}/Resources") + SET_TEST_LIST(SEARCH_DIRS) get_target_property(IS_BUNDLE ${target_exe} MACOSX_BUNDLE) if(IS_BUNDLE) # If its a bundle the exe is not in the target location, this should find it. @@ -15,9 +15,10 @@ macro(ll_deploy_sharedlibs_command target_exe) set(OUTPUT_PATH ${OUTPUT_PATH}/../Resources) endif(IS_BUNDLE) elseif(WINDOWS) - set(SEARCH_DIRS "${SHARED_LIB_STAGING_DIR}/${CMAKE_CFG_INTDIR}" "$ENV{SystemRoot}/system32") + SET_TEST_LIST(SEARCH_DIRS) + LIST(APPEND SEARCH_DIRS "$ENV{SystemRoot}/system32") elseif(LINUX) - set(SEARCH_DIRS "${SHARED_LIB_STAGING_DIR}") + SET_TEST_LIST(SEARCH_DIRS) set(OUTPUT_PATH ${OUTPUT_PATH}/lib) endif(DARWIN) -- cgit v1.2.3