[shim/f18] Fix file path to match whichever distro it's compiled in.

Peter Jones pjones at fedoraproject.org
Mon Aug 13 15:49:14 UTC 2012


commit bc4b8b9c44f22f34f51385bcf1f8722306a09e98
Author: Peter Jones <pjones at redhat.com>
Date:   Mon Aug 13 11:45:54 2012 -0400

    Fix file path to match whichever distro it's compiled in.
    
    We use a different directory for RHEL and Fedora.

 shim.spec |   12 ++++++++++--
 1 files changed, 10 insertions(+), 2 deletions(-)
---
diff --git a/shim.spec b/shim.spec
index 0369c40..97db01b 100644
--- a/shim.spec
+++ b/shim.spec
@@ -27,6 +27,14 @@ Patch0: shim-fedora.diff
 # is useless
 %global debug_package %{nil}
 
+# Figure out the right file path to use
+%if 0%{?rhel}
+%global efidir redhat
+%endif
+%if 0%{?fedora}
+%global efidir fedora
+%endif
+
 %description
 Initial UEFI bootloader that handles chaining to a trusted full bootloader
 under secure boot environments.
@@ -42,11 +50,11 @@ make %{?_smp_mflags}
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -m 0755 -D shim.efi $RPM_BUILD_ROOT/boot/efi/EFI/redhat/shim.efi
+install -m 0755 -D shim.efi $RPM_BUILD_ROOT/boot/efi/EFI/%{efidir}/shim.efi
 
 %files
 %doc
-/boot/efi/EFI/redhat/shim.efi
+/boot/efi/EFI/%{efidir}/shim.efi
 
 
 %changelog


More information about the scm-commits mailing list