From d454935ec65152f7cbe5e34983da2d0139d838b9 Mon Sep 17 00:00:00 2001 From: mintsuki Date: Thu, 21 Apr 2022 15:44:26 +0200 Subject: [PATCH] efi: Update linker scripts for new reduced-gnu-efi --- common/linker_uefi32.ld.in | 6 ++++++ common/linker_uefi64.ld.in | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/common/linker_uefi32.ld.in b/common/linker_uefi32.ld.in index 863c3ad1..efb51fde 100644 --- a/common/linker_uefi32.ld.in +++ b/common/linker_uefi32.ld.in @@ -22,19 +22,25 @@ SECTIONS __text_start = .; __text_size = __text_end - __text_start; + __text_sizev = __text_endv - __text_start; *(.text .text.*) + __text_endv = .; . = ALIGN(0x1000); __text_end = .; __reloc_start = .; __reloc_size = __reloc_end - __reloc_start; + __reloc_sizev = __reloc_endv - __reloc_start; *(.reloc) + __reloc_endv = .; . = ALIGN(0x1000); __reloc_end = .; __sbat_start = .; __sbat_size = __sbat_end - __sbat_start; + __sbat_sizev = __sbat_endv - __sbat_start; *(.sbat) + __sbat_endv = .; . = ALIGN(0x1000); __sbat_end = .; diff --git a/common/linker_uefi64.ld.in b/common/linker_uefi64.ld.in index 36a6d5c3..ee520dec 100644 --- a/common/linker_uefi64.ld.in +++ b/common/linker_uefi64.ld.in @@ -22,19 +22,25 @@ SECTIONS __text_start = .; __text_size = __text_end - __text_start; + __text_sizev = __text_endv - __text_start; *(.text .text.*) + __text_endv = .; . = ALIGN(0x1000); __text_end = .; __reloc_start = .; __reloc_size = __reloc_end - __reloc_start; + __reloc_sizev = __reloc_endv - __reloc_start; *(.reloc) + __reloc_endv = .; . = ALIGN(0x1000); __reloc_end = .; __sbat_start = .; __sbat_size = __sbat_end - __sbat_start; + __sbat_sizev = __sbat_endv - __sbat_start; *(.sbat) + __sbat_endv = .; . = ALIGN(0x1000); __sbat_end = .;