Page MenuHomeFreeBSD

llvm-strings(1): Install as strings when WITH_LLVM_BINUTILS=YES
ClosedPublic

Authored by me_cameronkatri.com on Sep 23 2021, 12:25 AM.
Tags
None
Referenced Files
F102641371: D32065.diff
Fri, Nov 15, 5:37 AM
Unknown Object (File)
Thu, Oct 31, 1:10 PM
Unknown Object (File)
Oct 10 2024, 9:01 AM
Unknown Object (File)
Oct 2 2024, 5:30 AM
Unknown Object (File)
Sep 24 2024, 9:39 AM
Unknown Object (File)
Sep 24 2024, 9:39 AM
Unknown Object (File)
Sep 24 2024, 9:38 AM
Unknown Object (File)
Sep 24 2024, 9:38 AM
Subscribers

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 42779
Build 39667: arc lint + arc unit

Event Timeline

me_cameronkatri.com created this revision.

Other than the minor issue I noted this seems reasonable to me. @emaste what do you think?

usr.bin/Makefile
265

This should probably be unconditional. @emaste pointed out that strings is sometimes used when people don't expect a full toolchain.

Install strings if despite WITHOUT_TOOLCHAIN

My argument for sticking with ELF Tool Chain strings is that we install it unconditionally and it gets used outside of traditional toolchain applications (e.g., it may be installed on more constrained embedded systems). In contrast to tools like nm, objcopy or even readelf where we need support for different formats (LLVM IR or different symbol tables, say) I think ELF Tool Chain strings is fully functional. Have you noticed anything missing from it, or is this just for consistency with the other tools?

On my laptop ELF Tool Chain strings is 16KB and depends on 103K libelf.so.2 while llvm-strings12 (from pkgs) is 30K and depends on 87MB libLLVM-12.so.

I updated this so it will install ELF Tool Chain strings, unless WITH_LLVM_BINUTILS is set, in which case llvm-strings will be installed as strings. It shouldn't change the current behavior of installing strings regardless of whether the toolchain was built (which I completely understand).

If WITHOUT_TOOLCHAIN is not set then llvm-strings will be built and installed anyways so I see no issue with installing it as strings too.

This revision is now accepted and ready to land.Apr 5 2023, 7:54 PM