mirror of
https://github.com/google/benchmark.git
synced 2025-01-14 05:40:14 +08:00
add debug option for enabling more output for failed cxxfeaturechecks (#1467)
fixes #1466
This commit is contained in:
parent
4366d66385
commit
77d1e74d29
@ -17,6 +17,8 @@ if(__cxx_feature_check)
|
|||||||
endif()
|
endif()
|
||||||
set(__cxx_feature_check INCLUDED)
|
set(__cxx_feature_check INCLUDED)
|
||||||
|
|
||||||
|
option(CXXFEATURECHECK_DEBUG OFF)
|
||||||
|
|
||||||
function(cxx_feature_check FILE)
|
function(cxx_feature_check FILE)
|
||||||
string(TOLOWER ${FILE} FILE)
|
string(TOLOWER ${FILE} FILE)
|
||||||
string(TOUPPER ${FILE} VAR)
|
string(TOUPPER ${FILE} VAR)
|
||||||
@ -64,7 +66,11 @@ function(cxx_feature_check FILE)
|
|||||||
add_definitions(-DHAVE_${VAR})
|
add_definitions(-DHAVE_${VAR})
|
||||||
else()
|
else()
|
||||||
if(NOT COMPILE_${FEATURE})
|
if(NOT COMPILE_${FEATURE})
|
||||||
message(STATUS "Performing Test ${FEATURE} -- failed to compile: ${COMPILE_OUTPUT_VAR}")
|
if(CXXFEATURECHECK_DEBUG)
|
||||||
|
message(STATUS "Performing Test ${FEATURE} -- failed to compile: ${COMPILE_OUTPUT_VAR}")
|
||||||
|
else()
|
||||||
|
message(STATUS "Performing Test ${FEATURE} -- failed to compile")
|
||||||
|
endif()
|
||||||
else()
|
else()
|
||||||
message(STATUS "Performing Test ${FEATURE} -- compiled but failed to run")
|
message(STATUS "Performing Test ${FEATURE} -- compiled but failed to run")
|
||||||
endif()
|
endif()
|
||||||
|
Loading…
Reference in New Issue
Block a user