Skip to content

Two updates to tc_build/tools.py#322

Merged
msfjarvis merged 2 commits intoClangBuiltLinux:mainfrom
nathanchance:tc-build-tools-py-updates
Feb 27, 2026
Merged

Two updates to tc_build/tools.py#322
msfjarvis merged 2 commits intoClangBuiltLinux:mainfrom
nathanchance:tc-build-tools-py-updates

Conversation

@nathanchance
Copy link
Member

Fix tc_build/tools.py for multicall setups and update the LLVM tip of tree version used when a call to GitHub fails.

There are two minor problems with find_host_cc() when using a multicall
binary setup.

The first is calling .resolve() on a multicall binary, which breaks the
multicall setup because the symlink is how the multicall binary works in
the first place. Avoid calling .resolve() in the case of multicall
binaries.

The second is clang-<ver> is not present in a multicall setup, so a
versioned binary from elsewhere in PATH can be chosen before a multicall
binary because plain clang is checked after the versioned binaries.
Check if the first clang in PATH is a multicall binary and use it if so.
Otherwise, fallback to looking at versioned binaries first then the
unversioned clang so that newer versions of clang, such as those from
apt.llvm.org, are chosen first.

While in the area, use an else branch for the for loop that looks for
compilers, saving a couple lines and a cc check.

Signed-off-by: Nathan Chancellor <nathan@kernel.org>
Signed-off-by: Nathan Chancellor <nathan@kernel.org>
@msfjarvis msfjarvis merged commit 5f6c171 into ClangBuiltLinux:main Feb 27, 2026
8 checks passed
@nathanchance nathanchance deleted the tc-build-tools-py-updates branch March 2, 2026 02:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants