From 0bb329b0bf89119dd6224a729664c89d54fa3e0b Mon Sep 17 00:00:00 2001 From: Callum Farmer Date: Mon, 19 Jun 2023 14:38:54 +0100 Subject: [PATCH] Merge .plt into .text ld writes .plt immediately after .text which corrupts the alignment of .reloc Signed-off-by: Callum Farmer --- gnuefi/elf_aarch64_efi.lds | 1 + gnuefi/elf_arm_efi.lds | 1 + gnuefi/elf_ia32_efi.lds | 1 + gnuefi/elf_ia64_efi.lds | 1 + gnuefi/elf_loongarch64_efi.lds | 1 + gnuefi/elf_mips64el_efi.lds | 1 + gnuefi/elf_riscv64_efi.lds | 1 + gnuefi/elf_x86_64_efi.lds | 1 + 8 files changed, 8 insertions(+) diff --git a/gnuefi/elf_aarch64_efi.lds b/gnuefi/elf_aarch64_efi.lds index d8a632b..65b584d 100644 --- a/gnuefi/elf_aarch64_efi.lds +++ b/gnuefi/elf_aarch64_efi.lds @@ -17,6 +17,7 @@ SECTIONS *(.text) *(.text.*) *(.gnu.linkonce.t.*) + *(.plt) . = ALIGN(16); } _etext = .; diff --git a/gnuefi/elf_arm_efi.lds b/gnuefi/elf_arm_efi.lds index ecc0a37..3bfbac3 100644 --- a/gnuefi/elf_arm_efi.lds +++ b/gnuefi/elf_arm_efi.lds @@ -9,6 +9,7 @@ SECTIONS *(.text) *(.text.*) *(.gnu.linkonce.t.*) + *(.plt) . = ALIGN(16); } _etext = .; diff --git a/gnuefi/elf_ia32_efi.lds b/gnuefi/elf_ia32_efi.lds index 3f6c7d5..1361454 100644 --- a/gnuefi/elf_ia32_efi.lds +++ b/gnuefi/elf_ia32_efi.lds @@ -17,6 +17,7 @@ SECTIONS *(.text) *(.text.*) *(.gnu.linkonce.t.*) + *(.plt) . = ALIGN(16); } _etext = .; diff --git a/gnuefi/elf_ia64_efi.lds b/gnuefi/elf_ia64_efi.lds index 989abb7..eb8a7ad 100644 --- a/gnuefi/elf_ia64_efi.lds +++ b/gnuefi/elf_ia64_efi.lds @@ -17,6 +17,7 @@ SECTIONS *(.text) *(.text.*) *(.gnu.linkonce.t.*) + *(.plt) . = ALIGN(16); } _etext = .; diff --git a/gnuefi/elf_loongarch64_efi.lds b/gnuefi/elf_loongarch64_efi.lds index 3c2a4f8..d9de3bd 100644 --- a/gnuefi/elf_loongarch64_efi.lds +++ b/gnuefi/elf_loongarch64_efi.lds @@ -9,6 +9,7 @@ SECTIONS *(.text) *(.text.*) *(.gnu.linkonce.t.*) + *(.plt) . = ALIGN(16); } _etext = .; diff --git a/gnuefi/elf_mips64el_efi.lds b/gnuefi/elf_mips64el_efi.lds index ed78b4d..a0d1a5b 100644 --- a/gnuefi/elf_mips64el_efi.lds +++ b/gnuefi/elf_mips64el_efi.lds @@ -9,6 +9,7 @@ SECTIONS *(.text) *(.text.*) *(.gnu.linkonce.t.*) + *(.plt) . = ALIGN(16); } _etext = .; diff --git a/gnuefi/elf_riscv64_efi.lds b/gnuefi/elf_riscv64_efi.lds index eefe7dd..c5b10bf 100644 --- a/gnuefi/elf_riscv64_efi.lds +++ b/gnuefi/elf_riscv64_efi.lds @@ -11,6 +11,7 @@ SECTIONS { *(.text) *(.text.*) *(.gnu.linkonce.t.*) + *(.plt) . = ALIGN(16); } _etext = .; diff --git a/gnuefi/elf_x86_64_efi.lds b/gnuefi/elf_x86_64_efi.lds index c10e749..e9f395e 100644 --- a/gnuefi/elf_x86_64_efi.lds +++ b/gnuefi/elf_x86_64_efi.lds @@ -19,6 +19,7 @@ SECTIONS *(.text) *(.text.*) *(.gnu.linkonce.t.*) + *(.plt) . = ALIGN(16); } _etext = .;