summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2022-09-26 17:51:29 -0400
committerBrad King <brad.king@kitware.com>2022-09-26 17:51:29 -0400
commit4b2e765025e90a4ed3ab437c194cced9cd9872ae (patch)
tree89234c99e03cbdcb449c47423c512e31ebaf7e0a /CMakeLists.txt
parenteb6e2ef7f61de1dd4ff6ec39e886d5fa8cf9aea7 (diff)
downloadcmake-4b2e765025e90a4ed3ab437c194cced9cd9872ae.tar.gz
Drop try_run macro from CMake's own build
Since commit 9199f7c627 (Disable arch-specific try_run in CMake itself, 2009-12-14, v2.8.2~567) we've abused an undocumented debugging feature to override the builtin `try_run` command in CMake's own build with a wrapper macro. However, we've also long discouraged use of this feature by other projects. The purpose of the original change is outdated and of limited use anyway, so just drop it.
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt11
1 files changed, 0 insertions, 11 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index a4f533d993..2b9eb2d569 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -60,17 +60,6 @@ else()
set(USE_LGPL "")
endif()
-if("${CMake_SOURCE_DIR}" STREQUAL "${CMAKE_SOURCE_DIR}")
- # Disallow architecture-specific try_run. It may not run on the host.
- macro(TRY_RUN)
- if(CMAKE_TRY_COMPILE_OSX_ARCHITECTURES)
- message(FATAL_ERROR "TRY_RUN not allowed with CMAKE_TRY_COMPILE_OSX_ARCHITECTURES=[${CMAKE_TRY_COMPILE_OSX_ARCHITECTURES}]")
- else()
- _TRY_RUN(${ARGV})
- endif()
- endmacro()
-endif()
-
# Use most-recent available language dialects with GNU and Clang
if(NOT DEFINED CMAKE_C_STANDARD AND NOT CMake_NO_C_STANDARD)
include(${CMake_SOURCE_DIR}/Source/Checks/cm_c11_thread_local.cmake)