Accepting request 148930 from home:michael-chang:branches:Base:System
Sync from SLE 11 SP3 - put 32-bit grub2 modules to /usr/lib/grub2 - put 64-bit grub2 modules to /usr/lib64/grub2 (x86_64-efi) - put grub.efi to /usr/lib64/efi(x86_64) or /usr/lib/efi(i586) OBS-URL: https://build.opensuse.org/request/show/148930 OBS-URL: https://build.opensuse.org/package/show/Base:System/grub2?expand=0&rev=9
This commit is contained in:
parent
34c65f9278
commit
5c92e57976
@ -1,3 +1,10 @@
|
||||
-------------------------------------------------------------------
|
||||
Fri Jan 18 08:57:48 UTC 2013 - mchang@suse.com
|
||||
|
||||
- put 32-bit grub2 modules to /usr/lib/grub2
|
||||
- put 64-bit grub2 modules to /usr/lib64/grub2 (x86_64-efi)
|
||||
- put grub.efi to /usr/lib64/efi(x86_64) or /usr/lib/efi(i586)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Jan 18 07:39:18 UTC 2013 - mchang@suse.com
|
||||
|
||||
|
46
grub2.spec
46
grub2.spec
@ -51,6 +51,13 @@ BuildRequires: guile
|
||||
# Modules always contain just 32-bit code
|
||||
%define _libdir %{_exec_prefix}/lib
|
||||
|
||||
%ifarch x86_64
|
||||
# x86_64-efi is 64-bit code, though ..
|
||||
%define efi_libdir %{_exec_prefix}/lib64
|
||||
%else
|
||||
%define efi_libdir %{_libdir}
|
||||
%endif
|
||||
|
||||
%ifarch ppc ppc64
|
||||
%define grubcpu powerpc
|
||||
%define platform ieee1275
|
||||
@ -274,6 +281,7 @@ export CFLAGS CXXFLAGS FFLAGS
|
||||
%configure \
|
||||
TARGET_LDFLAGS=-static \
|
||||
--target=%{_target_platform} \
|
||||
--libdir=%{efi_libdir} \
|
||||
--with-platform=efi \
|
||||
--program-transform-name=s,grub,%{name},
|
||||
make %{?_smp_mflags}
|
||||
@ -338,8 +346,8 @@ make %{?_smp_mflags}
|
||||
cd grub-efi-%{version}
|
||||
make DESTDIR=$RPM_BUILD_ROOT install
|
||||
|
||||
install -m 755 -d $RPM_BUILD_ROOT/boot/efi/EFI/%{efidir}/
|
||||
install -m 755 grub.efi $RPM_BUILD_ROOT/boot/efi/EFI/%{efidir}/grub.efi
|
||||
install -m 755 -d $RPM_BUILD_ROOT%{efi_libdir}/efi
|
||||
install -m 755 grub.efi $RPM_BUILD_ROOT%{efi_libdir}/efi/grub.efi
|
||||
|
||||
cd ..
|
||||
%endif
|
||||
@ -362,7 +370,14 @@ install -d $RPM_BUILD_ROOT/boot/%{name}
|
||||
touch $RPM_BUILD_ROOT/boot/%{name}/grub.cfg
|
||||
|
||||
# Remove devel files
|
||||
%ifarch x86_64
|
||||
%if ! 0%{?only_efi:1}
|
||||
rm $RPM_BUILD_ROOT/%{_libdir}/%{name}/*/*.h
|
||||
%endif
|
||||
rm $RPM_BUILD_ROOT/%{efi_libdir}/%{name}/*/*.h
|
||||
%else
|
||||
rm $RPM_BUILD_ROOT/%{_libdir}/%{name}/*/*.h
|
||||
%endif
|
||||
%if 0%{?suse_version} >= 1140
|
||||
rm $RPM_BUILD_ROOT%{_datadir}/%{name}/*.h
|
||||
%endif
|
||||
@ -569,7 +584,6 @@ fi
|
||||
%{_bindir}/%{name}-mkstandalone
|
||||
%{_bindir}/%{name}-mount
|
||||
%{_bindir}/%{name}-script-check
|
||||
%dir %{_libdir}/%{name}
|
||||
%dir %{_datadir}/%{name}
|
||||
%if 0%{?suse_version} >= 1140
|
||||
%{_datadir}/%{name}/*.pf2
|
||||
@ -581,6 +595,7 @@ fi
|
||||
%if ! 0%{?only_efi:1}
|
||||
%files %{grubarch}
|
||||
%defattr(-,root,root,-)
|
||||
%dir %{_libdir}/%{name}
|
||||
%dir %{_libdir}/%{name}/%{grubarch}
|
||||
%ifnarch ppc ppc64
|
||||
%{_libdir}/%{name}/%{grubarch}/*.image
|
||||
@ -610,19 +625,18 @@ fi
|
||||
|
||||
%files %{grubefiarch}
|
||||
%defattr(-,root,root,-)
|
||||
%dir /boot/efi
|
||||
%dir /boot/efi/EFI
|
||||
%dir /boot/efi/EFI/%{efidir}
|
||||
%attr(0755,root,root)/boot/efi/EFI/%{efidir}/grub.efi
|
||||
%dir %{_libdir}/%{name}/%{grubefiarch}
|
||||
%{_libdir}/%{name}/%{grubefiarch}/*.img
|
||||
%{_libdir}/%{name}/%{grubefiarch}/*.lst
|
||||
%{_libdir}/%{name}/%{grubefiarch}/*.mod
|
||||
%{_libdir}/%{name}/%{grubefiarch}/*.module
|
||||
%{_libdir}/%{name}/%{grubefiarch}/gdb_grub2
|
||||
%{_libdir}/%{name}/%{grubefiarch}/gmodule.pl
|
||||
%{_libdir}/%{name}/%{grubefiarch}/kernel.exec
|
||||
%{_libdir}/%{name}/%{grubefiarch}/modinfo.sh
|
||||
%dir %{efi_libdir}/efi
|
||||
%dir %{efi_libdir}/%{name}
|
||||
%dir %{efi_libdir}/%{name}/%{grubefiarch}
|
||||
%{efi_libdir}/efi/grub.efi
|
||||
%{efi_libdir}/%{name}/%{grubefiarch}/*.img
|
||||
%{efi_libdir}/%{name}/%{grubefiarch}/*.lst
|
||||
%{efi_libdir}/%{name}/%{grubefiarch}/*.mod
|
||||
%{efi_libdir}/%{name}/%{grubefiarch}/*.module
|
||||
%{efi_libdir}/%{name}/%{grubefiarch}/gdb_grub2
|
||||
%{efi_libdir}/%{name}/%{grubefiarch}/gmodule.pl
|
||||
%{efi_libdir}/%{name}/%{grubefiarch}/kernel.exec
|
||||
%{efi_libdir}/%{name}/%{grubefiarch}/modinfo.sh
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
|
Loading…
Reference in New Issue
Block a user