Re: elf2ecoff endianness bugs
Izumi Tsutsui <[email protected]> Sun, 11 Jan 2026 18:06:07 +0900
| Newsgroups | gmane.os.netbsd.ports.mips.devel |
|---|---|
| Message-ID | <[email protected]> |
> Hello, > > elf2ecoff isn't generating valid symbol tables. It's both byte swapping > when it shouldn't (same host and target endianness) and not swapping when > it should. > > For example, my crosstool objdump doesn't like an elf2ecoff'd sgimips > kernel generated on amd64: > > $ mipseb--netbsd-objdump -x netbsd.ecoff > /dev/null > mipseb--netbsd-objdump: failed to read symbol table from: netbsd.ecoff > mipseb--netbsd-objdump: error message was: file truncated > > Same goes for an hpcmips (mipsel) kernel generated on amd64: > $ mipsel--netbsd-objdump -x netbsd.ecoff > /dev/null > mipsel--netbsd-objdump: netbsd.ecoff: bad value > > The attached patch makes objdump able to read the ecoff symbol tables again. Commited. https://mail-index.netbsd.org/source-changes/2026/01/11/msg160144.html Also fixed harmless ones: https://mail-index.netbsd.org/source-changes/2026/01/11/msg160145.html https://mail-index.netbsd.org/source-changes/2026/01/11/msg160146.html Thanks, --- Izumi Tsutsui