diff options
author | Brad King <brad.king@kitware.com> | 2006-02-09 18:14:57 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2006-02-09 18:14:57 (GMT) |
commit | c90b8d0537ff398f0ceb85c681d64f46893f1faf (patch) | |
tree | 7ea3c9bc22b04d41c1a441200ca861b8d608b364 /Modules/CheckCXXSourceCompiles.cmake | |
parent | ef88c8cbc83e8d66a3e3f6c72eb50724b9cec010 (diff) | |
download | CMake-c90b8d0537ff398f0ceb85c681d64f46893f1faf.zip CMake-c90b8d0537ff398f0ceb85c681d64f46893f1faf.tar.gz CMake-c90b8d0537ff398f0ceb85c681d64f46893f1faf.tar.bz2 |
ENH: Patch from Alexander Neundorf to improve behavior.
Diffstat (limited to 'Modules/CheckCXXSourceCompiles.cmake')
-rw-r--r-- | Modules/CheckCXXSourceCompiles.cmake | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Modules/CheckCXXSourceCompiles.cmake b/Modules/CheckCXXSourceCompiles.cmake index 871208e..8f6e12b 100644 --- a/Modules/CheckCXXSourceCompiles.cmake +++ b/Modules/CheckCXXSourceCompiles.cmake @@ -15,10 +15,14 @@ MACRO(CHECK_CXX_SOURCE_COMPILES SOURCE VAR) IF(CMAKE_REQUIRED_LIBRARIES) SET(CHECK_CXX_SOURCE_COMPILES_ADD_LIBRARIES "-DLINK_LIBRARIES:STRING=${CMAKE_REQUIRED_LIBRARIES}") + ELSE(CMAKE_REQUIRED_LIBRARIES) + SET(CHECK_CXX_SOURCE_COMPILES_ADD_LIBRARIES) ENDIF(CMAKE_REQUIRED_LIBRARIES) IF(CMAKE_REQUIRED_INCLUDES) SET(CHECK_CXX_SOURCE_COMPILES_ADD_INCLUDES "-DINCLUDE_DIRECTORIES:STRING=${CMAKE_REQUIRED_INCLUDES}") + ELSE(CMAKE_REQUIRED_INCLUDES) + SET(CHECK_CXX_SOURCE_COMPILES_ADD_INCLUDES) ENDIF(CMAKE_REQUIRED_INCLUDES) FILE(WRITE "${CMAKE_BINARY_DIR}/CMakeFiles/CMakeTmp/src.cxx" "${SOURCE}") |