mirror of
https://github.com/wiiu-env/wut.git
synced 2025-01-08 19:20:42 +01:00
- added missing gcc_except_table section
- added ignore of paddings in elf2rpl
This commit is contained in:
parent
4981b49563
commit
be3bcba701
@ -193,6 +193,7 @@ SECTIONS {
|
|||||||
/* Required compiler trash */
|
/* Required compiler trash */
|
||||||
.fixup ALIGN(32) : { *(.fixup*) }
|
.fixup ALIGN(32) : { *(.fixup*) }
|
||||||
.got ALIGN(32) : { *(.got*) }
|
.got ALIGN(32) : { *(.got*) }
|
||||||
|
.gcc_except_table ALIGN(32) : { *(.gcc_except_table*) }
|
||||||
.hash ALIGN(32) : { *(.hash) }
|
.hash ALIGN(32) : { *(.hash) }
|
||||||
.dynsym ALIGN(32) : { *(.dynsym) }
|
.dynsym ALIGN(32) : { *(.dynsym) }
|
||||||
|
|
||||||
|
@ -238,6 +238,9 @@ read(ElfFile &file, const std::string &filename)
|
|||||||
case elf::R_PPC_RELATIVE:
|
case elf::R_PPC_RELATIVE:
|
||||||
*ptr = byte_swap(addr);
|
*ptr = byte_swap(addr);
|
||||||
break;
|
break;
|
||||||
|
case elf::R_PPC_NONE:
|
||||||
|
// ignore padding
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
std::cout << "Unexpected relocation type in .rela.dyn section" << std::endl;
|
std::cout << "Unexpected relocation type in .rela.dyn section" << std::endl;
|
||||||
return false;
|
return false;
|
||||||
@ -484,6 +487,12 @@ read(ElfFile &file, const std::string &filename)
|
|||||||
auto symbol = getSectionSymbol(symSection, index);
|
auto symbol = getSectionSymbol(symSection, index);
|
||||||
auto addr = symbol->value + rela.addend;
|
auto addr = symbol->value + rela.addend;
|
||||||
|
|
||||||
|
if(type == elf::R_PPC_NONE)
|
||||||
|
{
|
||||||
|
// ignore padding
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
if(index == 0)
|
if(index == 0)
|
||||||
{
|
{
|
||||||
auto addend = static_cast<uint32_t>(rela.addend);
|
auto addend = static_cast<uint32_t>(rela.addend);
|
||||||
|
Loading…
Reference in New Issue
Block a user