doc: Document minimum versions for Xcode CLT and MSVC
What changed, and why it matters
This commit only updates documentation and build error messages to state the minimum supported versions of Apple's Xcode Command Line Tools (16.2) and Microsoft's Visual C++ compiler (18.3). It does not change any executable code, cryptographic logic, network behavior, or security-sensitive functionality. There is no security issue here.
No security action required. This is a routine documentation/maintenance change.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The diff removes three CMake variables that pointed to compiler documentation and replaces them with a single reference to doc/dependencies.md#compiler. It updates the C++ feature-detection error message in CheckCXXFeatures.cmake accordingly. It also adds minimum-version requirements to doc/build-osx.md and doc/dependencies.md. No code paths, compiler flags, or runtime behavior are modified.
Changed components
doc/build-osx.mddoc/dependencies.mdCMakeLists.txtcmake/module/CheckCXXFeatures.cmakeInspect captured patch +10 / −15
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 36644bd2..9dec916d 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -80,9 +80,6 @@ if(CMAKE_VERSION VERSION_LESS 4.2 AND CMAKE_SYSTEM_NAME STREQUAL "Darwin" AND NO
set(CMAKE_INSTALL_NAME_TOOL "${CMAKE_COMMAND} -E true")
endif()
enable_language(CXX)
-set(MIN_CLANG_DOCS "doc/dependencies.md#compiler")
-set(MIN_GCC_DOCS "doc/dependencies.md#compiler")
-set(MIN_MSVC_DOCS "doc/build-windows-msvc.md")
set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
@@ -201,11 +198,7 @@ string(APPEND CMAKE_CXX_COMPILE_OBJECT " ${APPEND_CPPFLAGS} ${APPEND_CXXFLAGS}")
string(APPEND CMAKE_CXX_CREATE_SHARED_LIBRARY " ${APPEND_LDFLAGS}")
string(APPEND CMAKE_CXX_LINK_EXECUTABLE " ${APPEND_LDFLAGS}")
-#=============================
-# C++ Feature Detection
-#=============================
-# In case the compiler is not GCC, Clang or MSVC this provides extra checks
-# which verify that some features are available in the standard library.
+# Check required C++ toolchain features early.
include(CheckCXXFeatures)
check_cxx_features()
diff --git a/cmake/module/CheckCXXFeatures.cmake b/cmake/module/CheckCXXFeatures.cmake
index b3760a7e..fde630e3 100644
--- a/cmake/module/CheckCXXFeatures.cmake
+++ b/cmake/module/CheckCXXFeatures.cmake
@@ -4,7 +4,7 @@
include_guard(GLOBAL)
-#Checks for C++ features required to compile Bitcoin Core.
+# Checks for C++ features required to compile Bitcoin Core.
include(CheckCXXSourceCompiles)
@@ -33,10 +33,8 @@ function(check_cxx_features)
"Compiler lacks Class Template Argument Deduction (CTAD) for aggregates.\n"
"This C++ feature is required for src/util/overloaded.h.\n"
"You are probably using an old compiler version\n"
- "The recommended compiler versions can be checked in:\n"
- " - GCC -> ${MIN_GCC_DOCS}\n"
- " - Clang -> ${MIN_CLANG_DOCS}\n"
- " - MSVC -> ${MIN_MSVC_DOCS}\n"
+ "The recommended compiler versions can be checked in\n"
+ "doc/dependencies.md#compiler.\n"
)
endif()
diff --git a/doc/build-osx.md b/doc/build-osx.md
index 669185c0..a6a2d3be 100644
--- a/doc/build-osx.md
+++ b/doc/build-osx.md
@@ -16,7 +16,9 @@ macOS comes with a built-in Terminal located in:
### 1. Xcode Command Line Tools
The Xcode Command Line Tools are a collection of build tools for macOS.
-These tools must be installed in order to build Bitcoin Core from source.
+Version 16.2 (or higher) of these tools must be
+[installed](https://developer.apple.com/documentation/xcode/installing-the-command-line-tools)
+in order to build Bitcoin Core from source.
To install, run the following command from your terminal:
diff --git a/doc/dependencies.md b/doc/dependencies.md
index aac4bb90..5e1a1948 100644
--- a/doc/dependencies.md
+++ b/doc/dependencies.md
@@ -8,10 +8,12 @@ them using [depends](/depends/README.md).
Bitcoin Core requires one of the following compilers.
-| Dependency | Minimum required |
+| Toolchain | Minimum required |
| --- | --- |
| [Clang](https://clang.llvm.org) | [17.0](https://github.com/bitcoin/bitcoin/pull/33555) |
| [GCC](https://gcc.gnu.org) | [12.1](https://github.com/bitcoin/bitcoin/pull/33842) |
+| [Xcode CLT](/doc/build-osx.md) | [16.2](https://github.com/bitcoin/bitcoin/pull/33932) |
+| [MSVC](/doc/build-windows-msvc.md) | [18.3](https://github.com/bitcoin/bitcoin/pull/33861) |
## Required
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.