On 5/8/25 18:17, Brooks Davis wrote:
On Thu, May 08, 2025 at 07:47:22PM +0000, Kyle Evans wrote:
The branch main has been updated by kevans:

URL: 
https://cgit.FreeBSD.org/src/commit/?id=78661696e639836c9c41313020308f132057189a

commit 78661696e639836c9c41313020308f132057189a
Author:     Kyle Evans <kev...@freebsd.org>
AuthorDate: 2025-05-08 19:47:16 +0000
Commit:     Kyle Evans <kev...@freebsd.org>
CommitDate: 2025-05-08 19:47:16 +0000

     loader: i386: use -z nostart-stop-gc for bfd as well
binutils 2.37 seems to have added the knob, so let's just use that
     version here (it's not clear if GC'ing start/stop symbols was actually
     made the default at the time, and it didn't seem worth it to dig much
     further).  This fixes misbehavior when built with more recent binutils,
     as we do rely on linker sets for loader commands that we use.

Do we need the version guards any more?  Even FreeBSD 12 has LLVM 13 and
binutils 2.37 is about to turn 4.

-- Brooks

Yeah, probably not. Jessica raised a valid point in the review that I had overlooked, though. Based on Simon's feedback, I did light investigation to determine where the options were introduced and just slapped it on for at least that, assuming it later became the default.

Apparently it did not become the default, so it's not clear how Simon's build was different. OTOH, I'm not sure if that really changes anything (except that the mystery isn't fully solved)- if it's possible to configure such a bfd, IMO it doesn't hurt to use it since these sections/symbols being retained is critical.

I don't see any reason not to drop the version bits. Ubuntu 22.04 seems to have binutils 2.38, so that's good at least -- I wasn't sure if the timing on 2.37 was right for that (or even what Ubuntu's policy is there).

Thanks,

Kyle Evans

Reply via email to