summaryrefslogtreecommitdiffstats
path: root/Source/Checks
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2019-12-04 19:18:14 (GMT)
committerKitware Robot <kwrobot@kitware.com>2019-12-04 19:19:21 (GMT)
commit816aa0740aa2e6f8b15e84c5b9bb95f7b2629847 (patch)
treee15478a514a5d940c87090ed32819d9d43f6817b /Source/Checks
parentf55593a607782dd1ea7fa3f2c1cedca7a05c5ae4 (diff)
parentee28580c33cbc7100b60d86ca4bc1702bde14930 (diff)
downloadCMake-816aa0740aa2e6f8b15e84c5b9bb95f7b2629847.zip
CMake-816aa0740aa2e6f8b15e84c5b9bb95f7b2629847.tar.gz
CMake-816aa0740aa2e6f8b15e84c5b9bb95f7b2629847.tar.bz2
Merge topic 'feature-test-fix'
ee28580c33 C++ feature checks: Ignore linker warnings Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !4089
Diffstat (limited to 'Source/Checks')
-rw-r--r--Source/Checks/cm_cxx_features.cmake2
1 files changed, 2 insertions, 0 deletions
diff --git a/Source/Checks/cm_cxx_features.cmake b/Source/Checks/cm_cxx_features.cmake
index de8a77a..3b00dfb 100644
--- a/Source/Checks/cm_cxx_features.cmake
+++ b/Source/Checks/cm_cxx_features.cmake
@@ -30,6 +30,8 @@ function(cm_check_cxx_feature name)
string(REGEX REPLACE "[^\n]*warning:[^\n]*sprintf\\(\\) is often misused, please use snprintf[^\n]*" "" check_output "${check_output}")
# Filter out xcodebuild warnings.
string(REGEX REPLACE "[^\n]* xcodebuild\\[[0-9]*:[0-9]*\\] warning: [^\n]*" "" check_output "${check_output}")
+ # Filter out ld warnings.
+ string(REGEX REPLACE "[^\n]*ld: warning: [^\n]*" "" check_output "${check_output}")
# If using the feature causes warnings, treat it as broken/unavailable.
if(check_output MATCHES "(^|[ :])[Ww][Aa][Rr][Nn][Ii][Nn][Gg]")
set(CMake_HAVE_CXX_${FEATURE} OFF CACHE INTERNAL "TRY_COMPILE" FORCE)