Skip to content

Missing llvm-readelf command #153275

Description

@rruuaanng

The latest LLVM release supports the llvm-readelf command, but it is not present in

const LLVM_TOOLS: &[&str] = &[
"llvm-cov", // used to generate coverage report
"llvm-nm", // used to inspect binaries; it shows symbol names, their sizes and visibility
"llvm-objcopy", // used to transform ELFs into binary format which flashing tools consume
.

Please let me know if my suggestion has any issues, thanks!

ref:
https://github.com/llvm/llvm-project/releases/tag/llvmorg-22.1.0

dep:
rust-embedded/cargo-binutils#175

Activity

  1. added
    needs-triageThis issue may need triage. Remove when done. See docs forge.rust-lang.org/release/issue-triaging
    on Mar 2, 2026
  2. bjorn3 commented on Mar 2, 2026

    @bjorn3
    Member

    llvm-readelf is an alias to llvm-readobj with just a slightly different cli. You should be able to use llvm-readobj: https://llvm.org/docs/CommandGuide/llvm-readobj.html#differences-to-llvm-readelf On Unix systems you can force it into readelf compat mode by setting arg0 to "readelf". I believe we can't use symlinks inside components, so we did have to duplicate the executable if we want. FWIW we don't include every tool LLVM provides, but just those that people said they actually need.

  3. added
    C-discussionCategory: Discussion or questions that doesn't represent real issues.
    and removed
    needs-triageThis issue may need triage. Remove when done. See docs forge.rust-lang.org/release/issue-triaging
    on Mar 2, 2026
  4. rruuaanng commented on Mar 5, 2026

    @rruuaanng
    Author

    You're right. It seems that this doesn't require upstream support. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-discussionCategory: Discussion or questions that doesn't represent real issues.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions