HomeFreeBSD

devel/binutils: Setting sh_link for SHT_REL/SHT_RELA

Description

devel/binutils: Setting sh_link for SHT_REL/SHT_RELA

Import upstream commit 6b958fe36b7:

It's wrong to have an alloc reloc section trying to use a non-alloc
symbol table.

  • elf.c (assign_section_numbers <SHT_REL, SHT_RELA>): Correct

comment. Always set sh_link to .dynsym for alloc reloc
sections and to .symtab for non-alloc.

This also fixes strip when using llvm-strip, i.e. when base built with
WITH_LLVM_BINUTILS.

PR: 271061, see also: 270961, 270960
Reported by: Emanuel Haupt <ehaupt@FreeBSD.org>
Approved by: cy
Obtained from: Upstream commit 6b958fe36b7
MFH: 2022Q2

Details

Provenance
ehauptAuthored on Apr 25 2023, 2:05 PM
cyCommitted on Apr 25 2023, 2:15 PM
Parents
R11:9552d6c036c3: x11/xdpyinfo: Remove depend on libdmx
Branches
Unknown
Tags
Unknown