Accepting request 1043980 from Base:System

Automatic submission by obs-autosubmit

OBS-URL: https://build.opensuse.org/request/show/1043980
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/gnu-efi?expand=0&rev=36
This commit is contained in:
Dominique Leuenberger 2022-12-21 15:06:27 +00:00 committed by Git OBS Bridge
commit 07df783260
6 changed files with 41 additions and 161 deletions

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:b73b643a0d5697d1f396d7431448e886dd805668789578e3e1a28277c9528435
size 159295

BIN
gnu-efi-3.0.15.tar.bz2 (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -1,69 +0,0 @@
diff --git a/gnuefi/crt0-efi-aarch64.S b/gnuefi/crt0-efi-aarch64.S
index d50e78d..f1c0155 100644
--- a/gnuefi/crt0-efi-aarch64.S
+++ b/gnuefi/crt0-efi-aarch64.S
@@ -128,3 +128,5 @@ _start:
0: ldp x29, x30, [sp], #32
ret
+
+ .section .note.GNU-stack,"",%progbits
diff --git a/gnuefi/crt0-efi-arm.S b/gnuefi/crt0-efi-arm.S
index e7e5905..731eda6 100644
--- a/gnuefi/crt0-efi-arm.S
+++ b/gnuefi/crt0-efi-arm.S
@@ -143,3 +143,5 @@ _start:
.L_DYNAMIC:
.word _DYNAMIC - .
+
+ .section .note.GNU-stack,"",%progbits
diff --git a/gnuefi/crt0-efi-ia32.S b/gnuefi/crt0-efi-ia32.S
index b1c9610..72b06a7 100644
--- a/gnuefi/crt0-efi-ia32.S
+++ b/gnuefi/crt0-efi-ia32.S
@@ -75,3 +75,5 @@ dummy: .long 0
.long 12 // Block Size (2*4+2*2), must be aligned by 32 Bits
.word (IMAGE_REL_ABSOLUTE<<12) + 0 // reloc for dummy
.word (IMAGE_REL_ABSOLUTE<<12) + 0 // reloc for dummy
+
+ .section .note.GNU-stack,"",@progbits
diff --git a/gnuefi/crt0-efi-ia64.S b/gnuefi/crt0-efi-ia64.S
index cd00b8d..e80da96 100644
--- a/gnuefi/crt0-efi-ia64.S
+++ b/gnuefi/crt0-efi-ia64.S
@@ -85,3 +85,5 @@ _start_plabel:
data4 12 // Block Size (2*4+2*2), must be aligned by 32 Bits
data2 (IMAGE_REL_BASED_DIR64<<12) + 0 // reloc for plabel's entry point
data2 (IMAGE_REL_BASED_DIR64<<12) + 8 // reloc for plabel's global pointer
+
+ .section .note.GNU-stack,"",@progbits
diff --git a/gnuefi/crt0-efi-mips64el.S b/gnuefi/crt0-efi-mips64el.S
index 6d26f66..527f5ce 100644
--- a/gnuefi/crt0-efi-mips64el.S
+++ b/gnuefi/crt0-efi-mips64el.S
@@ -186,3 +186,5 @@ _pc:
.end _start
.set pop
+
+ .section .note.GNU-stack,"",@progbits
diff --git a/gnuefi/crt0-efi-riscv64.S b/gnuefi/crt0-efi-riscv64.S
index 1bc536b..363f280 100644
--- a/gnuefi/crt0-efi-riscv64.S
+++ b/gnuefi/crt0-efi-riscv64.S
@@ -134,3 +134,5 @@ _start:
ld ra, 16(sp)
0: addi sp, sp, 24
ret
+
+ .section .note.GNU-stack,"",@progbits
diff --git a/gnuefi/crt0-efi-x86_64.S b/gnuefi/crt0-efi-x86_64.S
index 20bbaee..d8ea85e 100644
--- a/gnuefi/crt0-efi-x86_64.S
+++ b/gnuefi/crt0-efi-x86_64.S
@@ -75,3 +75,4 @@ label1:
.word (IMAGE_REL_ABSOLUTE<<12) + 0 // reloc for dummy
.word (IMAGE_REL_ABSOLUTE<<12) + 0 // reloc for dummy
+ .section .note.GNU-stack,"",@progbits

View File

@ -71,87 +71,26 @@ index 7be5902..fad1939 100644
. = ALIGN(4096);
.dynsym : { *(.dynsym) }
. = ALIGN(4096);
--
2.29.2
From 6014f854bd3a083f866a6379c34711bd294202a2 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Thu, 11 Mar 2021 10:08:41 -0500
Subject: [PATCH 2/2] arm/aarch64: include .sbat in section headers.
Signed-off-by: Peter Jones <pjones@redhat.com>
---
gnuefi/crt0-efi-aarch64.S | 14 +++++++++++++-
gnuefi/crt0-efi-arm.S | 16 +++++++++++++++-
2 files changed, 28 insertions(+), 2 deletions(-)
diff --git a/gnuefi/crt0-efi-aarch64.S b/gnuefi/crt0-efi-aarch64.S
index c300d89..9d4ffcd 100644
--- a/gnuefi/crt0-efi-aarch64.S
+++ b/gnuefi/crt0-efi-aarch64.S
@@ -31,7 +31,7 @@ pe_header:
.short 0
coff_header:
.short 0xaa64 // AArch64
- .short 2 // nr_sections
+ .short 3 // nr_sections
.long 0 // TimeDateStamp
.long 0 // PointerToSymbolTable
.long 0 // NumberOfSymbols
@@ -109,6 +109,18 @@ section_table:
.short 0 // NumberOfLineNumbers (0 for executables)
.long 0xc0000040 // Characteristics (section flags)
+ .ascii ".sbat\0\0\0"
+ .long _sbat_size // VirtualSize
+ .long _sbat - ImageBase // VirtualAddress
+ .long _sbat_size // SizeOfRawData
+ .long _sbat - ImageBase // PointerToRawData
--- a/gnuefi/elf_ia32_efi.lds
+++ b/gnuefi/elf_ia32_efi.lds
@@ -72,6 +72,16 @@ SECTIONS
*(.reloc)
}
. = ALIGN(4096);
+ .sbat :
+ {
+ _sbat = .;
+ *(.sbat)
+ *(.sbat.*)
+ }
+ _esbat = .;
+ _sbat_size = . - _sbat;
+
+ .long 0 // PointerToRelocations (0 for executables)
+ .long 0 // PointerToLineNumbers (0 for executables)
+ .short 0 // NumberOfRelocations (0 for executables)
+ .short 0 // NumberOfLineNumbers (0 for executables)
+ .long 0x40400040 // Characteristics (section flags)
+
.align 12
_start:
stp x29, x30, [sp, #-32]!
diff --git a/gnuefi/crt0-efi-arm.S b/gnuefi/crt0-efi-arm.S
index c5bb6d4..0189868 100644
--- a/gnuefi/crt0-efi-arm.S
+++ b/gnuefi/crt0-efi-arm.S
@@ -31,7 +31,7 @@ pe_header:
.short 0
coff_header:
.short 0x1c2 // Mixed ARM/Thumb
- .short 2 // nr_sections
+ .short 3 // nr_sections
.long 0 // TimeDateStamp
.long 0 // PointerToSymbolTable
.long 0 // NumberOfSymbols
@@ -122,6 +122,20 @@ section_table:
.short 0 // NumberOfLineNumbers (0 for executables)
.long 0xe0500020 // Characteristics (section flags)
+
+ .ascii ".sbat\0\0\0"
+ .long _sbat_size // VirtualSize
+ .long _sbat - ImageBase // VirtualAddress
+ .long _sbat_size // SizeOfRawData
+ .long _sbat - ImageBase // PointerToRawData
+
+ .long 0 // PointerToRelocations (0 for executables)
+ .long 0 // PointerToLineNumbers (0 for executables)
+ .short 0 // NumberOfRelocations (0 for executables)
+ .short 0 // NumberOfLineNumbers (0 for executables)
+ .long 0x40400040 // Characteristics (section flags)
+
+
_start:
stmfd sp!, {r0-r2, lr}
+ . = ALIGN(4096);
.dynsym : { *(.dynsym) }
. = ALIGN(4096);
.dynstr : { *(.dynstr) }
--
2.29.2

View File

@ -1,3 +1,16 @@
-------------------------------------------------------------------
Wed Oct 5 13:08:31 UTC 2022 - Callum Farmer <gmbr3@opensuse.org>
- Update to gnu-efi 3.0.15:
* */*.S: add non-executable GNU stack marking on ELF-linux
* lib/Makefile: add .o file dependency on libsubdirs targets
* Handle __mips64
- Remove gnu-efi-add-GNU-stack-section.patch: upstreamed
- Remove un-needed section from
gnu-efi-bsc1182057-support-sbat-section.patch now that we have
Binutils 2.38
- Extend gnu-efi-bsc1182057-support-sbat-section.patch for IA-32
-------------------------------------------------------------------
Tue May 3 13:35:13 UTC 2022 - Martin Liška <mliska@suse.cz>

View File

@ -17,16 +17,15 @@
Name: gnu-efi
Version: 3.0.14
Version: 3.0.15
Release: 0
Summary: Library for EFI Applications
License: BSD-3-Clause AND GPL-2.0-or-later
Group: Development/Libraries/Other
URL: https://sourceforge.net/projects/gnu-efi
Source: https://download.sourceforge.net/project/gnu-efi/gnu-efi-%{version}.tar.bz2
Source0: https://download.sourceforge.net/project/gnu-efi/gnu-efi-%{version}.tar.bz2
Source1: %{name}-rpmlintrc
Patch1: gnu-efi-bsc1182057-support-sbat-section.patch
Patch2: gnu-efi-add-GNU-stack-section.patch
Patch0: gnu-efi-bsc1182057-support-sbat-section.patch
BuildRequires: kernel-source
ExclusiveArch: ia64 %{ix86} x86_64 aarch64 %{arm} riscv64
@ -36,9 +35,7 @@ ARM-32, and ARM-64 platforms using the GNU toolchain and the EFI development
environment.
%prep
%setup -q
%patch1 -p1
%patch2 -p1
%autosetup -p1
%build
##########################