]>
Commit | Line | Data |
---|---|---|
69539fe3 JP |
1 | From 52943009b7dce4a0ebb5943092d47e6e33625401 Mon Sep 17 00:00:00 2001 |
2 | From: Rui Ueyama <ruiu@bluewhale.systems> | |
3 | Date: Sun, 19 Jun 2022 11:28:37 +0800 | |
4 | Subject: [PATCH] [ELF] Handle R_ARM_MOVT_PREL and R_ARM_PREL31 as | |
5 | non-address-taking relocations | |
6 | ||
7 | This is an attempt to fix https://github.com/rui314/mold/issues/545 though | |
8 | I don't know if this is a correct fix. | |
9 | --- | |
10 | elf/arch-arm32.cc | 2 +- | |
11 | 1 file changed, 1 insertion(+), 1 deletion(-) | |
12 | ||
13 | diff --git a/elf/arch-arm32.cc b/elf/arch-arm32.cc | |
14 | index 65a9dede..1b94e931 100644 | |
15 | --- a/elf/arch-arm32.cc | |
16 | +++ b/elf/arch-arm32.cc | |
17 | @@ -427,7 +427,7 @@ void InputSection<E>::scan_relocations(Context<E> &ctx) { | |
18 | case R_ARM_PREL31: { | |
19 | Action table[][4] = { | |
20 | // Absolute Local Imported data Imported code | |
21 | - { ERROR, NONE, ERROR, ERROR }, // DSO | |
22 | + { ERROR, NONE, ERROR, PLT }, // DSO | |
23 | { ERROR, NONE, COPYREL, PLT }, // PIE | |
24 | { NONE, NONE, COPYREL, PLT }, // PDE | |
25 | }; |