This is an automated email from the ASF dual-hosted git repository. raulcd pushed a commit to branch maint-26.0.x in repository https://gitbox.apache.org/repos/asf/arrow.git
commit 8d08fb841a57f19a6e7579acc69f09f52da3aeda Author: Nic Crane <[email protected]> AuthorDate: Tue Oct 27 14:42:42 2026 +0000 GH-55267: [C++][R] Arrow 26.0.0 fails to build on CRAN macOS builders: bundled simdjson C++20 concepts don't compile with the macOS 11 SDK (#55273) ### Rationale for this change CRAN failures on 26.0.0 release due to regex not catching incompatible MacOSX11.sdk version ### What changes are included in this PR? Make regex more permissive ### Are these changes tested? No ### Are there any user-facing changes? No **PR code and description written by:** - [x] Human - [x] AI **Reviewed before submission by:** - [x] Human - [x] AI - [ ] Not reviewed * GitHub Issue: #55267 Authored-by: Nic Crane <[email protected]> Signed-off-by: Nic Crane <[email protected]> --- cpp/cmake_modules/ThirdpartyToolchain.cmake | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/cpp/cmake_modules/ThirdpartyToolchain.cmake b/cpp/cmake_modules/ThirdpartyToolchain.cmake index db4482f737..368a26efcf 100644 --- a/cpp/cmake_modules/ThirdpartyToolchain.cmake +++ b/cpp/cmake_modules/ThirdpartyToolchain.cmake @@ -2878,10 +2878,19 @@ function(build_simdjson) target_compile_definitions(simdjson PUBLIC SIMDJSON_EXCEPTIONS=0) - # The macOS 11.3 SDK has incomplete C++20 concepts support, which prevents - # simdjson headers from compiling. Disable simdjson concepts for this SDK. - if(CMAKE_OSX_SYSROOT AND CMAKE_OSX_SYSROOT MATCHES "MacOSX11\\.3\\.sdk$") - message(STATUS "Disabling simdjson concepts for macOS SDK 11.3") + # macOS SDKs before 13.3 ship a libc++ without <ranges> and with incomplete + # <concepts>, but simdjson enables its C++20 concepts API from the compiler's + # __cpp_concepts alone, so its headers fail to compile against those SDKs + # (GH-55267). Disable simdjson concepts for them. Arrow doesn't use that part + # of the simdjson API. simdjson considers these SDKs unsupported and won't fix + # this upstream, see https://github.com/simdjson/simdjson/issues/2787. + # + # The SDK directory name may omit the minor version ("MacOSX11.sdk" on CRAN, + # "MacOSX11.3.sdk" in our as-cran CI job), so match both forms. This treats + # "MacOSX13.sdk" as too old, which is harmless. + if(CMAKE_OSX_SYSROOT AND CMAKE_OSX_SYSROOT MATCHES + "MacOSX(1[0-2](\\.[0-9]+)?|13(\\.[0-2])?)\\.sdk$") + message(STATUS "Disabling simdjson concepts for macOS SDK older than 13.3") target_compile_definitions(simdjson PUBLIC SIMDJSON_CONCEPT_DISABLED=1) endif()
