From 414cfeed4d106fc6829e66e517e803bd6ee0d8ec Mon Sep 17 00:00:00 2001 From: Jake Petroules Date: Fri, 15 Aug 2025 10:47:56 -0700 Subject: [PATCH] Remove /INCREMENTAL:NO flag for llbuild-tool and libllbuild targets on Windows These were originally added 6 years ago in #475 to "Disable incremental linking so llbuild.ilk's don't conflict" because at the time the command line tool and library targets were given the same OUTPUT_NAME, which conflicted. In #1005 these targets were given distinct names, so the workaround should no longer be necessary. This helps unblock swiftlang/swift-build#757 because this flag is currently added without regard for the specific compiler driver in use, so the flag might not work based on whether clang-cl.exe or cl.exe vs clang.exe (where it would require a -Xlinker prefix), is used. --- products/libllbuild/CMakeLists.txt | 4 ---- products/llbuild/CMakeLists.txt | 4 ---- 2 files changed, 8 deletions(-) diff --git a/products/libllbuild/CMakeLists.txt b/products/libllbuild/CMakeLists.txt index 9d6a5d52..a821478b 100644 --- a/products/libllbuild/CMakeLists.txt +++ b/products/libllbuild/CMakeLists.txt @@ -21,10 +21,6 @@ target_link_libraries(llbuild PRIVATE llvmSupport SQLite::SQLite3) -if(CMAKE_SYSTEM_NAME STREQUAL Windows) - set_target_properties(llbuild PROPERTIES LINK_FLAGS "/INCREMENTAL:NO") -endif() - if(NOT CMAKE_SYSTEM_NAME STREQUAL Windows) target_link_libraries(llbuild PRIVATE curses) diff --git a/products/llbuild/CMakeLists.txt b/products/llbuild/CMakeLists.txt index 95066cae..59cbfe5c 100644 --- a/products/llbuild/CMakeLists.txt +++ b/products/llbuild/CMakeLists.txt @@ -10,10 +10,6 @@ target_link_libraries(llbuild-tool PRIVATE llvmSupport SQLite::SQLite3) -if(CMAKE_SYSTEM_NAME STREQUAL Windows) - set_target_properties(llbuild-tool PROPERTIES LINK_FLAGS "/INCREMENTAL:NO") -endif() - set_target_properties(llbuild-tool PROPERTIES OUTPUT_NAME llbuild)