pokeemerald
pokeemerald copied to clipboard
gbafix: Don't pad ELF files
If option -p is specified and the target file is an ELF, it will pad the ELF file. This shouldn't happen, as objcopy will pad it anyways.
A potential fix would be to ignore -p when the input is an ELF file, and possibly output a warning if this is the case.
Another possibility could be to just not use -p
with ELF files
Assuming sh_offset
gets set to something non-zero, this seems to have been fixed in 2019: https://github.com/pret/pokeemerald/blame/master/tools/gbafix/gbafix.c#L297?