Re: Migrating to LLVM binutils tools (ar, nm, addr2line, etc.)

From: Ed Maste <emaste_at_freebsd.org>
Date: Wed, 04 Aug 2021 01:09:40 UTC
On Mon, 2 Aug 2021 at 09:11, Shawn Webb <shawn.webb@hardenedbsd.org> wrote:
>
> For most cases, when elftc-ar fails, it does not set the exitcode to
> non-zero. This tricks the ports tree to continue to build a port where
> elftc-ar actually errored.

Thanks for the notice - I didn't see this email until now, but saw the
related discussion on HardenedBSD's IRC channel this morning.

Note that FreeBSD ar is different from ELF Tool Chain's ar; the latter
is a fork of FreeBSDs, and there are some distinct bug fixes or
improvements in each version that are not present in the other. Here
FreeBSD's ar is buggy, and llvm-ar, GNU ar, and ELF Tool Chain's ar
all return a non-zero exit code.

Code review with fix for FreeBSD's ar: https://reviews.freebsd.org/D31402
Exp-run request: https://bugs.freebsd.org/257599