From 3980808abf4599ce601fd39ea70bc1f4385172af Mon Sep 17 00:00:00 2001 From: Michael D Kinney Date: Thu, 2 Oct 2025 15:57:50 -0700 Subject: [PATCH] BaseTools/Scripts: KEEP .prmexportdescriptor data sections Update GCC linker script to always keep .prmexportdescriptor sections and merge them into the .data section. The .prmexportdescriptor section is only used by PRM modules for the PRM Export Descriptor Structure that must be kept in the final image to support adding the PRM Export Descriptor Structure and its associated PRM Handlers APIs to a PE/COFF DLL Export section. Signed-off-by: Michael D Kinney --- BaseTools/Scripts/GccBase.lds | 1 + 1 file changed, 1 insertion(+) diff --git a/BaseTools/Scripts/GccBase.lds b/BaseTools/Scripts/GccBase.lds index 8d6c29d7b6..3d2a97ddeb 100644 --- a/BaseTools/Scripts/GccBase.lds +++ b/BaseTools/Scripts/GccBase.lds @@ -52,6 +52,7 @@ SECTIONS { .data ALIGN(ALIGNOF(.text)) : ALIGN(CONSTANT(COMMONPAGESIZE)) { *(.data .data.* .gnu.linkonce.d.*) *(.bss .bss.*) + KEEP(*(.prmexportdescriptor)) } :data .eh_frame ALIGN(CONSTANT(COMMONPAGESIZE)) : {