mirror of
https://github.com/pspdev/pspsdk.git
synced 2025-10-03 16:51:27 +00:00
psp-prxgen: remove PC16 relocations
It apparently appeared with binutils 2.18+. It appears when compiling an assembly file containing a branch to a global name, but looks useless (branches are relative to current position, and I do not see how the symbol could "move"). This relocation made the PSP not load the modules using it.
This commit is contained in:
@@ -419,7 +419,8 @@ int remove_weak_relocs(struct ElfSection *pReloc, struct ElfSection *pSymbol, st
|
||||
}
|
||||
}
|
||||
|
||||
if(LH(pSymData[iSymbol].st_shndx) == 0)
|
||||
/* Remove PC16 relocations (unsupported by PSP, and useless) */
|
||||
if(LH(pSymData[iSymbol].st_shndx) == 0 || ELF32_R_TYPE(LW(pInRel->r_info)) == R_MIPS_PC16)
|
||||
{
|
||||
if(g_verbose)
|
||||
{
|
||||
|
Reference in New Issue
Block a user