summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorAlexander Neundorf <neundorf@kde.org>2007-08-28 14:52:07 (GMT)
committerAlexander Neundorf <neundorf@kde.org>2007-08-28 14:52:07 (GMT)
commitbd8b733d5e3df7ae584090d4558b1617489eae8b (patch)
treed8a23c852affd7c551142ef6d35f4221923d99c5 /Modules
parent61aa07b78c0adc726228ab93cb22e24882a6a8f9 (diff)
downloadCMake-bd8b733d5e3df7ae584090d4558b1617489eae8b.zip
CMake-bd8b733d5e3df7ae584090d4558b1617489eae8b.tar.gz
CMake-bd8b733d5e3df7ae584090d4558b1617489eae8b.tar.bz2
ENH: use the same CMAKE_SKIP_RPATH setting in CHECK_C/CXX_SOURCE_RUNS as in
the main project. I think it doesn't make sense if a project disables RPATH, uses CHECK_C_SOURCE_RUNS() to see if something is able to run, and this succeeds because it has been built with RPATH, but an executable built within the project won't be able to run since it has been built without RPATH. Alex
Diffstat (limited to 'Modules')
-rw-r--r--Modules/CheckCSourceRuns.cmake1
-rw-r--r--Modules/CheckCXXSourceRuns.cmake1
2 files changed, 2 insertions, 0 deletions
diff --git a/Modules/CheckCSourceRuns.cmake b/Modules/CheckCSourceRuns.cmake
index c54070a..c5455ae 100644
--- a/Modules/CheckCSourceRuns.cmake
+++ b/Modules/CheckCSourceRuns.cmake
@@ -37,6 +37,7 @@ MACRO(CHECK_C_SOURCE_RUNS SOURCE VAR)
${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/src.c
COMPILE_DEFINITIONS ${CMAKE_REQUIRED_DEFINITIONS}
CMAKE_FLAGS -DCOMPILE_DEFINITIONS:STRING=${MACRO_CHECK_FUNCTION_DEFINITIONS}
+ -DCMAKE_SKIP_RPATH:BOOL=${CMAKE_SKIP_RPATH}
"${CHECK_C_SOURCE_COMPILES_ADD_LIBRARIES}"
"${CHECK_C_SOURCE_COMPILES_ADD_INCLUDES}"
COMPILE_OUTPUT_VARIABLE OUTPUT)
diff --git a/Modules/CheckCXXSourceRuns.cmake b/Modules/CheckCXXSourceRuns.cmake
index 01d4c64..b0c9ba5 100644
--- a/Modules/CheckCXXSourceRuns.cmake
+++ b/Modules/CheckCXXSourceRuns.cmake
@@ -37,6 +37,7 @@ MACRO(CHECK_CXX_SOURCE_RUNS SOURCE VAR)
${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/src.cxx
COMPILE_DEFINITIONS ${CMAKE_REQUIRED_DEFINITIONS}
CMAKE_FLAGS -DCOMPILE_DEFINITIONS:STRING=${MACRO_CHECK_FUNCTION_DEFINITIONS}
+ -DCMAKE_SKIP_RPATH:BOOL=${CMAKE_SKIP_RPATH}
"${CHECK_CXX_SOURCE_COMPILES_ADD_LIBRARIES}"
"${CHECK_CXX_SOURCE_COMPILES_ADD_INCLUDES}"
COMPILE_OUTPUT_VARIABLE OUTPUT)