summaryrefslogtreecommitdiff
path: root/utils/google-benchmark/cmake/CXXFeatureCheck.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'utils/google-benchmark/cmake/CXXFeatureCheck.cmake')
-rw-r--r--utils/google-benchmark/cmake/CXXFeatureCheck.cmake4
1 files changed, 3 insertions, 1 deletions
diff --git a/utils/google-benchmark/cmake/CXXFeatureCheck.cmake b/utils/google-benchmark/cmake/CXXFeatureCheck.cmake
index 3059024dc..b106f32b6 100644
--- a/utils/google-benchmark/cmake/CXXFeatureCheck.cmake
+++ b/utils/google-benchmark/cmake/CXXFeatureCheck.cmake
@@ -26,7 +26,9 @@ function(cxx_feature_check FILE)
endif()
message("-- Performing Test ${FEATURE}")
try_run(RUN_${FEATURE} COMPILE_${FEATURE}
- ${CMAKE_BINARY_DIR} ${CMAKE_CURRENT_SOURCE_DIR}/cmake/${FILE}.cpp)
+ ${CMAKE_BINARY_DIR} ${CMAKE_CURRENT_SOURCE_DIR}/cmake/${FILE}.cpp
+ CMAKE_FLAGS ${BENCHMARK_CXX_LINKER_FLAGS}
+ LINK_LIBRARIES ${BENCHMARK_CXX_LIBRARIES})
if(RUN_${FEATURE} EQUAL 0)
message("-- Performing Test ${FEATURE} -- success")
set(HAVE_${VAR} 1 CACHE INTERNAL "Feature test for ${FILE}" PARENT_SCOPE)