elf2rpl: Remove fixRoDataFlags.

This is covered by linker script.
This commit is contained in:
James Benton 2018-05-30 22:42:05 +01:00
parent ae70d3a4a9
commit 0ef7dcfa32

View File

@ -563,23 +563,6 @@ fixFileHeader(ElfFile &file)
}
/**
* .rodate requires W flag.
*/
static bool
fixRoDataFlags(ElfFile &file)
{
for (auto &section : file.sections) {
if (section->header.type == elf::SHT_PROGBITS &&
!(section->header.flags & elf::SHF_EXECINSTR)) {
section->header.flags |= elf::SHF_WRITE;
}
}
return true;
}
/**
* Relocate a section to a new address.
*/
@ -955,11 +938,6 @@ int main(int argc, char **argv)
return -1;
}
if (!fixRoDataFlags(elf)) {
fmt::print("ERROR: fixRoDataFlags failed.\n");
return -1;
}
if (!deflateSections(elf)) {
fmt::print("ERROR: deflateSections failed.\n");
return -1;