efi-rpm-macros/0008-Add-efi_has_alt_arch-0-or-1.patch
Peter Jones 0f7061b948 Add %{efi_has_alt_arch}
Signed-off-by: Peter Jones <pjones@redhat.com>
2018-05-02 10:12:47 -04:00

31 lines
699 B
Diff

From a4358f78316160cf29e177daedf9562e6a0505f2 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Wed, 2 May 2018 10:09:19 -0400
Subject: [PATCH 8/8] Add %{efi_has_alt_arch} ("0" or "1")
Signed-off-by: Peter Jones <pjones@redhat.com>
---
macros.efi.in | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/macros.efi.in b/macros.efi.in
index c61b3972f2d..66139a257d5 100644
--- a/macros.efi.in
+++ b/macros.efi.in
@@ -80,3 +80,12 @@ end
local arch = rpm.expand("%{efi_alt_arch}")
print(string.upper(arch))
}
+
+%efi_has_alt_arch %{lua:
+ local arch = rpm.expand("%{efi_alt_arch}")
+ if arch == "" then
+ print("0")
+ else
+ print("1")
+ end
+}
--
2.14.3