From 30ed0c5efd6c25c59312d760c5fe9df2b716e97e Mon Sep 17 00:00:00 2001 From: Steve Downey Date: Sun, 2 Aug 2026 15:06:42 -0400 Subject: [PATCH] build: sync infra to 749c558 for CMake 4.4 and libc++ _FORTIFY_SOURCE Picks up three upstream infra commits, both of which fix CI breakage: - enable-experimental-import-std.cmake gains the CMake 4.4.0 gate. The CMAKE_EXPERIMENTAL_CXX_IMPORT_STD UUID changes with each CMake release, so after the recent bump from 4.3.4 to 4.4.0 the 4.3.0 branch no longer matched and `import std` builds stopped enabling the feature. - llvm-libc++-toolchain.cmake appends -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=0 alongside -stdlib=libc++. Both vendored files match bemanproject/infra at the pinned hash exactly; the upstream range touches only these two files, so nothing else needed syncing. --- infra/.beman_submodule | 2 +- infra/cmake/enable-experimental-import-std.cmake | 6 +++++- infra/cmake/llvm-libc++-toolchain.cmake | 5 ++++- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/infra/.beman_submodule b/infra/.beman_submodule index 628b5d0..26f1dbf 100644 --- a/infra/.beman_submodule +++ b/infra/.beman_submodule @@ -1,3 +1,3 @@ [beman_submodule] remote=https://github.com/bemanproject/infra.git -commit_hash=7b66b858d7f48428fca936184aef2bd246ccc81a +commit_hash=749c5588afe37daaa290b659d439cd7cd473ad1b diff --git a/infra/cmake/enable-experimental-import-std.cmake b/infra/cmake/enable-experimental-import-std.cmake index e41a5f7..3c6d688 100644 --- a/infra/cmake/enable-experimental-import-std.cmake +++ b/infra/cmake/enable-experimental-import-std.cmake @@ -1,5 +1,9 @@ # SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception -if(CMAKE_VERSION VERSION_GREATER_EQUAL "4.3.0") +if(CMAKE_VERSION VERSION_GREATER_EQUAL "4.4.0") + set(CMAKE_EXPERIMENTAL_CXX_IMPORT_STD + "f35a9ac6-8463-4d38-8eec-5d6008153e7d" + ) +elseif(CMAKE_VERSION VERSION_GREATER_EQUAL "4.3.0") set(CMAKE_EXPERIMENTAL_CXX_IMPORT_STD "451f2fe2-a8a2-47c3-bc32-94786d8fc91b" ) diff --git a/infra/cmake/llvm-libc++-toolchain.cmake b/infra/cmake/llvm-libc++-toolchain.cmake index eabf363..aac8502 100644 --- a/infra/cmake/llvm-libc++-toolchain.cmake +++ b/infra/cmake/llvm-libc++-toolchain.cmake @@ -16,5 +16,8 @@ include(${CMAKE_CURRENT_LIST_DIR}/llvm-toolchain.cmake) if(NOT CMAKE_CXX_FLAGS MATCHES "-stdlib=libc\\+\\+") - string(APPEND CMAKE_CXX_FLAGS " -stdlib=libc++") + string( + APPEND CMAKE_CXX_FLAGS + " -stdlib=libc++ -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=0" + ) endif()