Skip to content

Conversation

compnerd
Copy link
Member

@compnerd compnerd commented Aug 7, 2025

Because llbuild is the executable, we cannot have another target with the name llbuild which is the library target. As such, the library is named libllbuild. This changes the output name of the library to liblibllbuild. This was being overridden which caused some trouble for builds which attempted to skirt the dependencies. Rename the output to the proper name.

@compnerd
Copy link
Member Author

compnerd commented Aug 7, 2025

CC: @drexin

@compnerd
Copy link
Member Author

compnerd commented Aug 7, 2025

@swift-ci please test

@compnerd
Copy link
Member Author

compnerd commented Aug 7, 2025

@swift-ci please test

@owenv
Copy link
Contributor

owenv commented Aug 7, 2025

The llbuild executable is rarely used compared to the library, I think we should rename that to something like llbuild-exec or llbuild-tool before renaming the library

@jakepetroules
Copy link
Contributor

I agree, that's probably the lower risk approach.

@compnerd
Copy link
Member Author

compnerd commented Aug 7, 2025

Works for me; I'll rename the executable.

@compnerd
Copy link
Member Author

compnerd commented Aug 7, 2025

@swift-ci please test

@compnerd
Copy link
Member Author

compnerd commented Aug 7, 2025

@swift-ci please test

Because `llbuild` is the executable, we cannot have another target with the name `llbuild` which is the library target. As such, the library is named `libllbuild`. This changes the output name of the library to `liblibllbuild`. This was being overridden which caused some trouble for builds which attempted to skirt the dependencies. As the tool is generally unused, prefer to rename the tool target to `llbuild-tool`, and use `OUTPUT_NAME` to retain the output name. This allows us to have the `libllbuild.a` name for the new `llbuild` target.
@compnerd
Copy link
Member Author

compnerd commented Aug 8, 2025

@swift-ci please test

@compnerd
Copy link
Member Author

compnerd commented Aug 9, 2025

@swift-ci please smoke test

@compnerd
Copy link
Member Author

compnerd commented Aug 9, 2025

@swift-ci please smoke test Linux platform

@compnerd
Copy link
Member Author

compnerd commented Aug 9, 2025

@swift-ci please smoke test macOS platform

@compnerd
Copy link
Member Author

compnerd commented Aug 9, 2025

@swift-ci please smoke test

@compnerd compnerd merged commit 5891ce0 into swiftlang:main Aug 10, 2025
6 checks passed
@compnerd compnerd deleted the names branch August 10, 2025 17:21
jakepetroules added a commit to jakepetroules/swift-llbuild that referenced this pull request Aug 30, 2025
…n Windows These were originally added 6 years ago in swiftlang#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 swiftlang#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.
jakepetroules added a commit that referenced this pull request Sep 2, 2025
…n 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.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants