[lld] [llvm] [LLD] Add support for two special OpenBSD sections (PR #97122)

John Ericson via llvm-commits llvm-commits at lists.llvm.org
Sun Jun 30 17:01:42 PDT 2024


Ericson2314 wrote:

@MaskRay After testing that my cross compiled binary still runs, I:

- Removed the section-coalescing parts of the first two commits.

- Added a new commit which:

  - Gated the `PT_`-assignments under a `config->osabi == ELFOSABI_OPENBSD` check

   - Modified LLVM to set `ELFOSABI_OPENBSD` for OpenBSD targets just like it does `ELFOSABI_FREEBSD` for FreeBSD ones

I am reasonably happy with this. Per the 3rd commits message, without weighing in on the degree to which it is possible/reasonable for upstream to track something as fast-moving as OpenBSD, the `config->osabi == ELFOSABI_OPENBSD` adds a stronger "firewall" between OpenBSD and everything else.

https://github.com/llvm/llvm-project/pull/97122


More information about the llvm-commits mailing list