diff --git a/ChangeLog b/ChangeLog index e8e40a8..454e7e2 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,14 @@ +2015-10-29 Mark Hatle + Kyle McMartin + Jakub Jelinek + Julian Brown + + * testsuite/ifunc.h: Fix missing # + * src/arch-arm.c (arm_prelink_conflict_rela): Add missing hunk + that implemented R_ARM_IRELATIVE, and ifunc conflicts. + + See: https://bugzilla.redhat.com/show_bug.cgi?id=1009601 + 2015-10-29 Mark Hatle * prelink.h: Define SHT_MIPS_ABIFLAGS if not set * prelink.c: OK to skip SHT_MIPS_ABIFLAGS diff --git a/src/arch-arm.c b/src/arch-arm.c index c8febcd..eec7c57 100644 --- a/src/arch-arm.c +++ b/src/arch-arm.c @@ -536,15 +536,16 @@ arm_prelink_conflict_rela (DSO *dso, struct prelink_info *info, if (conflict == NULL) { - if (info->curtls == NULL) - return 0; - switch (GELF_R_TYPE (rela->r_info)) { /* Even local DTPMOD and TPOFF relocs need conflicts. */ case R_ARM_TLS_DTPMOD32: case R_ARM_TLS_TPOFF32: + if (info->curtls == NULL || info->dso == dso) + return 0; break; + /* Similarly IRELATIVE relocations always need conflicts. */ + case R_ARM_IRELATIVE: /* Likewise TLS_DESC. */ case R_ARM_TLS_DESC: break; @@ -553,12 +554,8 @@ arm_prelink_conflict_rela (DSO *dso, struct prelink_info *info, } value = 0; } - else if (conflict->ifunc) - { - error (0, 0, "%s: STT_GNU_IFUNC not handled on ARM yet", - dso->filename); - return 1; - } + else if (info->dso == dso && !conflict->ifunc) + return 0; else { /* DTPOFF32 wants to see only real conflicts, not lookups diff --git a/testsuite/ifunc.h b/testsuite/ifunc.h index 8507f19..78ad86b 100644 --- a/testsuite/ifunc.h +++ b/testsuite/ifunc.h @@ -51,7 +51,7 @@ asm (".text\n" \ "\t.align 4\n" \ "2:\t.long " fn "@GOTOFF\n" \ "3:\t.long _GLOBAL_OFFSET_TABLE_-1b\n" -elif defined __arm__ +#elif defined __arm__ # ifdef __thumb__ # define PIPE_OFFSET "4" # else