Re: Fixing Elf##_Versym
[email protected] (Christos Zoulas) Tue, 11 Nov 2025 15:22:03 -0000 (UTC)
| Newsgroups | gmane.os.netbsd.devel.toolchain |
|---|---|
| Message-ID | <[email protected]> |
In article <[email protected]>, Joseph Koshy <[email protected]> wrote: >Hello tech-toolchain, > >Many ELF toolkits define an Elf##_Versym to be a 16-bit unsigned >quantity: > > /* Solaris, FreeBSD, Elfutils, Elftoolchain, maybe others. */ > typedef Elf32_Half Elf32_Versym; > typedef Elf64_Half Elf64_Versym; > >NetBSD however defines it as a struct with a sole 16-bit unsigned >member: > > /* NetBSD: <sys/exec_elf.h> */ > typedef struct { > Elf32_Half vs_vers; > } Elf32_Versym; > typedef Elf32_Versym Elf64_Versym; > >I would like to align NetBSD's definitions with those in the >other toolkits, so that it becomes easier to port ELF-handling >code to NetBSD. > >Would anyone have objections to the below patch? Per my >understanding, the patch does not change runtime behavior. I am fine with the change, it reduces diff in rtld with FreeBSD too. christos