*.efi.lds: Merge all rela sections into one

Objcopy sometimes generates .rela.plt and .rela.data
sections for which their names are longer than the 8
characters limit of PE32

Signed-off-by: Callum Farmer <gmbr3@opensuse.org>
This commit is contained in:
Callum Farmer 2023-02-21 11:57:17 +00:00
parent 593e13937c
commit eea6d31a22
7 changed files with 41 additions and 26 deletions

View File

@ -55,10 +55,14 @@ SECTIONS
_bss_end = .;
}
.rela.dyn : { *(.rela.dyn) }
.rela.plt : { *(.rela.plt) }
.rela.got : { *(.rela.got) }
.rela.data : { *(.rela.data) *(.rela.data*) }
.rela :
{
*(.rela.text*)
*(.rela.data*)
*(.rela.got)
*(.rela.plt)
*(.rela.stab)
}
. = ALIGN(512);
_edata = .;
_data_size = . - _data;

View File

@ -41,10 +41,14 @@ SECTIONS
_bss_end = .;
}
.rel.dyn : { *(.rel.dyn) }
.rel.plt : { *(.rel.plt) }
.rel.got : { *(.rel.got) }
.rel.data : { *(.rel.data) *(.rel.data*) }
.rel :
{
*(.rel.text*)
*(.rel.data*)
*(.rel.got)
*(.rel.plt)
*(.rel.stab)
}
_edata = .;
_data_size = . - _etext;

View File

@ -55,9 +55,11 @@ SECTIONS
. = ALIGN(4096);
.rel :
{
*(.rel.data)
*(.rel.data.*)
*(.rel.text*)
*(.rel.sdata*)
*(.rel.data*)
*(.rel.got)
*(.rel.plt)
*(.rel.stab)
*(.data.rel.ro.local)
*(.data.rel.local)

View File

@ -52,10 +52,11 @@ SECTIONS
. = ALIGN(4096);
.rela :
{
*(.rela.text)
*(.rela.text*)
*(.rela.sdata*)
*(.rela.data*)
*(.rela.sdata)
*(.rela.got)
*(.rela.plt)
*(.rela.gnu.linkonce.d*)
*(.rela.stab)
*(.rela.ctors)

View File

@ -41,10 +41,14 @@ SECTIONS
_bss_end = .;
}
.rel.dyn : { *(.rel.dyn) }
.rel.plt : { *(.rel.plt) }
.rel.got : { *(.rel.got) }
.rel.data : { *(.rel.data) *(.rel.data*) }
.rel :
{
*(.rel.text*)
*(.rel.data*)
*(.rel.got)
*(.rel.plt)
*(.rel.stab)
}
_edata = .;
_data_size = . - _etext;

View File

@ -44,16 +44,14 @@ SECTIONS {
_bss_end = .;
}
.rela.text :
{ *(.rela.text) *(.rela.text*) }
.rela.dyn :
{ *(.rela.dyn) }
.rela.plt :
{ *(.rela.plt) }
.rela.got :
{ *(.rela.got) }
.rela.data :
{ *(.rela.data) *(.rela.data*) }
.rela :
{
*(.rela.text*)
*(.rela.data*)
*(.rela.got)
*(.rela.plt)
*(.rela.stab)
}
. = ALIGN(512);
_edata = .;
_data_size = . - _data;

View File

@ -57,8 +57,10 @@ SECTIONS
. = ALIGN(4096);
.rela :
{
*(.rela.text*)
*(.rela.data*)
*(.rela.got)
*(.rela.plt)
*(.rela.stab)
}
. = ALIGN(4096);