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