Skip to content

Commit d1c75f2

Browse files
committed
Differentiation: make the build work without early-swift-driver
Windows does not have the early swift-driver. Disable CMP0157 for compatibility.
1 parent fdb2819 commit d1c75f2

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

Runtimes/Supplemental/Differentiation/CMakeLists.txt

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,13 @@
11
cmake_minimum_required(VERSION 3.29)
2+
# TODO before requiring CMake 4.1 or later
3+
# and/or enforcing CMP0195, please check/update
4+
# the implementation of `emit_swift_interface`
5+
# in `EmitSwiftInterface.cmake`
6+
# to ensure it keeps laying down nested swiftmodule folders
7+
8+
if(POLICY CMP0157 AND CMAKE_Swift_COMPILER_USE_OLD_DRIVER)
9+
cmake_policy(SET CMP0157 OLD)
10+
endif()
211

312
if($ENV{BUILD_NUMBER})
413
math(EXPR BUILD_NUMBER "$ENV{BUILD_NUMBER} % 65535")

0 commit comments

Comments
 (0)