fwupd/0001-Revert-Require-gnu-efi-3.0.18-or-later.patch
Richard Hughes 30a3b93cc5
Rebase to get new hardware support
Resolves: #RHEL-125778
2026-01-12 13:39:19 +00:00

46 lines
1.5 KiB
Diff

From 856cde012b6ee114b8ce44e090651adbc6c6ddf8 Mon Sep 17 00:00:00 2001
From: Richard Hughes <richard@hughsie.com>
Date: Mon, 12 Jan 2026 12:07:40 +0000
Subject: [PATCH] Revert "Require gnu-efi 3.0.18 or later"
This reverts commit 26c6ec5c1e7765fb5dc6a4df511ab21ee6c6e67a.
---
efi/meson.build | 6 ++++++
meson.build | 3 ++-
2 files changed, 8 insertions(+), 1 deletion(-)
diff --git a/efi/meson.build b/efi/meson.build
index a034bc2..af4bfa3 100644
--- a/efi/meson.build
+++ b/efi/meson.build
@@ -45,6 +45,12 @@ if efi_libdir == ''
endif
endif
+have_gnu_efi = gnu_efi_path_arch != '' and efi_libdir != ''
+
+if not have_gnu_efi and not gnuefi.found()
+ error('gnu-efi headers were not found')
+endif
+
# The name we need to look for on this arch and OS: elf_x86_64_fbsd_efi.lds
lds_os = ''
if host_cpu == 'x86_64' and host_machine.system() == 'freebsd'
diff --git a/meson.build b/meson.build
index d632aaa..7052105 100644
--- a/meson.build
+++ b/meson.build
@@ -13,7 +13,8 @@ cc_ld = find_program(cc.get_linker_id())
objcopy = find_program('objcopy')
objcopy_version = run_command(objcopy, '--version', check: true).stdout().split('\n')[0].split(' ')[-1]
-gnuefi = dependency('gnu-efi', version: '>= 3.0.18')
+# pkgconfig introduced in 3.0.18, allows compiling against older
+gnuefi = dependency('gnu-efi', required: false)
prefix = get_option('prefix')
libdir = join_paths(prefix, get_option('libdir'))
libexecdir = join_paths(prefix, get_option('libexecdir'))
--
2.52.0