summaryrefslogtreecommitdiffstats
path: root/Modules/CheckLinkerFlag.cmake
diff options
context:
space:
mode:
authorRobert Maynard <robert.maynard@kitware.com>2020-09-14 17:17:42 (GMT)
committerRobert Maynard <robert.maynard@kitware.com>2020-09-23 16:28:37 (GMT)
commit10ae907de07c26820a765c6a516d1f4baa46161d (patch)
tree51550bfe24aa14db9bec91efc1e45a1d841fb939 /Modules/CheckLinkerFlag.cmake
parentf5c928f73cdb35b4cc0ea052f663071ec590624e (diff)
downloadCMake-10ae907de07c26820a765c6a516d1f4baa46161d.zip
CMake-10ae907de07c26820a765c6a516d1f4baa46161d.tar.gz
CMake-10ae907de07c26820a765c6a516d1f4baa46161d.tar.bz2
CheckSoureCompiles: Add a unified way to check if a source compiles
Diffstat (limited to 'Modules/CheckLinkerFlag.cmake')
-rw-r--r--Modules/CheckLinkerFlag.cmake4
1 files changed, 2 insertions, 2 deletions
diff --git a/Modules/CheckLinkerFlag.cmake b/Modules/CheckLinkerFlag.cmake
index cd7301f..051e0bc 100644
--- a/Modules/CheckLinkerFlag.cmake
+++ b/Modules/CheckLinkerFlag.cmake
@@ -51,7 +51,7 @@ function(CHECK_LINKER_FLAG _lang _flag _var)
return()
endif()
- include (Check${_lang}SourceCompiles)
+ include (CheckSourceCompiles)
set(CMAKE_REQUIRED_LINK_OPTIONS "${_flag}")
@@ -74,7 +74,7 @@ function(CHECK_LINKER_FLAG _lang _flag _var)
endif()
check_compiler_flag_common_patterns(_common_patterns)
- cmake_language (CALL check_${_lang}_source_compiles "${_source}" ${_var} ${_common_patterns})
+ check_source_compiles(${_lang} "${_source}" ${_var} ${_common_patterns})
foreach(v IN LISTS _locale_vars)
set(ENV{${v}} ${_locale_vars_saved_${v}})