summaryrefslogtreecommitdiffstats
path: root/Modules/CheckIncludeFileCXX.cmake
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2014-04-01 15:06:12 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2014-04-01 15:06:12 (GMT)
commitce9ffd6b23155588a2f8be880afd0fc7654808af (patch)
tree1b9dae11a0a96c004887d7ef4a7659a3ed11545d /Modules/CheckIncludeFileCXX.cmake
parent8617de566f637935793dc2c7bcf004a3b311c31e (diff)
parent83934757c942672d8bea79f11e51a184b168a212 (diff)
downloadCMake-ce9ffd6b23155588a2f8be880afd0fc7654808af.zip
CMake-ce9ffd6b23155588a2f8be880afd0fc7654808af.tar.gz
CMake-ce9ffd6b23155588a2f8be880afd0fc7654808af.tar.bz2
Merge topic 'find_package-check-quiet'
83934757 Find*: Make find_package(.. QUIET) affect Check* modules. 4c0cc9ab Check*.cmake : Add CMAKE_REQUIRED_QUIET flag.
Diffstat (limited to 'Modules/CheckIncludeFileCXX.cmake')
-rw-r--r--Modules/CheckIncludeFileCXX.cmake13
1 files changed, 10 insertions, 3 deletions
diff --git a/Modules/CheckIncludeFileCXX.cmake b/Modules/CheckIncludeFileCXX.cmake
index fa36a3f..39abeff 100644
--- a/Modules/CheckIncludeFileCXX.cmake
+++ b/Modules/CheckIncludeFileCXX.cmake
@@ -28,6 +28,7 @@
# CMAKE_REQUIRED_FLAGS = string of compile command line flags
# CMAKE_REQUIRED_DEFINITIONS = list of macros to define (-DFOO=bar)
# CMAKE_REQUIRED_INCLUDES = list of include directories
+# CMAKE_REQUIRED_QUIET = execute quietly without messages
#=============================================================================
# Copyright 2002-2009 Kitware, Inc.
@@ -53,7 +54,9 @@ macro(CHECK_INCLUDE_FILE_CXX INCLUDE VARIABLE)
set(CHECK_INCLUDE_FILE_VAR ${INCLUDE})
configure_file(${CMAKE_ROOT}/Modules/CheckIncludeFile.cxx.in
${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/CheckIncludeFile.cxx)
- message(STATUS "Looking for C++ include ${INCLUDE}")
+ if(NOT CMAKE_REQUIRED_QUIET)
+ message(STATUS "Looking for C++ include ${INCLUDE}")
+ endif()
if(${ARGC} EQUAL 3)
set(CMAKE_CXX_FLAGS_SAVE ${CMAKE_CXX_FLAGS})
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${ARGV2}")
@@ -73,14 +76,18 @@ macro(CHECK_INCLUDE_FILE_CXX INCLUDE VARIABLE)
endif()
if(${VARIABLE})
- message(STATUS "Looking for C++ include ${INCLUDE} - found")
+ if(NOT CMAKE_REQUIRED_QUIET)
+ message(STATUS "Looking for C++ include ${INCLUDE} - found")
+ endif()
set(${VARIABLE} 1 CACHE INTERNAL "Have include ${INCLUDE}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
"Determining if the include file ${INCLUDE} "
"exists passed with the following output:\n"
"${OUTPUT}\n\n")
else()
- message(STATUS "Looking for C++ include ${INCLUDE} - not found")
+ if(NOT CMAKE_REQUIRED_QUIET)
+ message(STATUS "Looking for C++ include ${INCLUDE} - not found")
+ endif()
set(${VARIABLE} "" CACHE INTERNAL "Have include ${INCLUDE}")
file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
"Determining if the include file ${INCLUDE} "