Repository navigation
Add install-name-tool to llvm repo - #790
Merged
Merged
Conversation
alopezz
requested review from
dzbarsky,
fmeum,
helly25,
jsharpe and
rrbutani
as code owners
June 30, 2026 12:25
dzbarsky
enabled auto-merge (squash)
June 30, 2026 12:34
dzbarsky
approved these changes
Jun 30, 2026
gh-worker-dd-mergequeue-cf854d Bot
pushed a commit
to DataDog/datadog-agent
that referenced
this pull request
Jul 6, 2026
### What does this PR do? It moves bazel usage of host `install_name_tool` to [llvm's version](https://llvm.org/docs/CommandGuide/llvm-install-name-tool.html) of it and replaces ad-hoc rpath removal logic with a single command. ### Motivation Mainly for the benefit of being able to use `--delete_all_rpaths` (#52964 (comment)), simplifying recently implemented logic (#52964) to manually do that. Of course, it also adds improved hermeticity is an extra bonus, though considering that we won't ever get all the tools needed for rpath patching hermetically (i.e. we'll always need `codesign` at least), and that these are tools that are pretty much guaranteed to be installed on macos systems, that might not be such a big deal. ### Describe how you validated your changes Local testing and green CI build (including health check). ### Additional Notes This leverages the llvm toolchain we already had set up, which exposes the tool thanks to bazel-contrib/toolchains_llvm#790. There's still possible cleanup to do and too many places where we're rewriting rpaths, but that will require follow-up targeted work. Co-authored-by: alex.lopez <alex.lopez@datadoghq.com>
gh-worker-dd-mergequeue-cf854d Bot
pushed a commit
to DataDog/datadog-agent
that referenced
this pull request
Oct 5, 2026
### What does this PR do? Bump the `toolchains_llvm` Bazel module from `1.8.0` to `1.11.1`. Remove the `archive_override` that temporarily pinned it to an intermediate commit (bazel-contrib/toolchains_llvm#790), now shipped in the `1.11.0` release. ### Motivation The dependency was pinned to a specific commit via `archive_override` instead of a tagged release, bypassing BCR version resolution, because bazel-contrib/toolchains_llvm#790 had not shipped in a release yet. That PR adds the `install-name-tool` filegroup our macOS rpath-rewriting toolchain (`//bazel/toolchains/rpath_rewriter`) depends on, shipped starting with `1.9.0`. ### Describe how you validated your changes Verified `@llvm_toolchain_llvm//:install-name-tool` and the `//bazel/toolchains/rpath_rewriter` toolchain wiring still resolve and build for `macos_arm64` under `1.11.1`. Diffed the dependency's git history between `1.8.0` and `1.11.1` against our LLVM-adjacent Bazel code and found no other local workaround made redundant by it. Co-authored-by: regis.desgroppes <regis.desgroppes@datadoghq.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #606.
This makes llvm-install-name-tool available under
<name>_llvm//:install-name-tool, making it available as a (hermetic) replacement for host install-name-tool.