forked from pool/grub2
Accepting request 866469 from home:michael-chang:branches:Base:System
- Fix rpmlint 2.0 error for having arch specific path in noarch package aiming for compatibility with old package (bsc#1179044) * grub2.spec - Fix non POSIX sed argument which failed in sed from busybox (bsc#1181091) * grub2-check-default.sh OBS-URL: https://build.opensuse.org/request/show/866469 OBS-URL: https://build.opensuse.org/package/show/Base:System/grub2?expand=0&rev=368
This commit is contained in:
parent
49ce0ac7f1
commit
18241ef23c
@ -5,7 +5,7 @@ set -e
|
|||||||
fallback_entry () {
|
fallback_entry () {
|
||||||
|
|
||||||
local saved=$1
|
local saved=$1
|
||||||
local FALLBACK_MATCH=`echo $saved | sed -e '/>/!d' -e '/>/s/>.*$//'`
|
local FALLBACK_MATCH=`echo $saved | sed -e '/>/!d' -e '/>.*$/s///'`
|
||||||
|
|
||||||
if [ -n "$FALLBACK_MATCH" ]; then
|
if [ -n "$FALLBACK_MATCH" ]; then
|
||||||
for i in $MENU_ENTRIES; do
|
for i in $MENU_ENTRIES; do
|
||||||
@ -35,7 +35,7 @@ esac
|
|||||||
GRUB_EDITENV="/usr/bin/grub2-editenv"
|
GRUB_EDITENV="/usr/bin/grub2-editenv"
|
||||||
GRUB_SET_DEFAULT="/usr/sbin/grub2-set-default"
|
GRUB_SET_DEFAULT="/usr/sbin/grub2-set-default"
|
||||||
|
|
||||||
SAVED_ENTRY=`${GRUB_EDITENV} list | sed -ne "/^saved_entry=/{s@\"\(.*\)\"@\1@;t 1;s@'\(.*\)'@\1@;: 1;s@^[^=]\+=@@;p;b}"`
|
SAVED_ENTRY=`${GRUB_EDITENV} list | sed -ne "/^saved_entry=/s///p"`
|
||||||
|
|
||||||
debug_print "SAVED_ENTRY=$SAVED_ENTRY"
|
debug_print "SAVED_ENTRY=$SAVED_ENTRY"
|
||||||
|
|
||||||
@ -101,7 +101,7 @@ fi
|
|||||||
|
|
||||||
source /etc/os-release
|
source /etc/os-release
|
||||||
|
|
||||||
NEW_SAVED_ENTRY=`echo $SAVED_ENTRY | sed -ne "s/$NAME [0-9a-zA-Z_.-]\\+/$NAME $VERSION/pg"`
|
NEW_SAVED_ENTRY=`echo $SAVED_ENTRY | sed -ne "s/$NAME [0-9a-zA-Z_.-]\{1,\}/$NAME $VERSION/pg"`
|
||||||
|
|
||||||
debug_print "NEW_SAVED_ENTRY=$NEW_SAVED_ENTRY"
|
debug_print "NEW_SAVED_ENTRY=$NEW_SAVED_ENTRY"
|
||||||
|
|
||||||
|
@ -1,3 +1,12 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Jan 21 07:59:39 UTC 2021 - Michael Chang <mchang@suse.com>
|
||||||
|
|
||||||
|
- Fix rpmlint 2.0 error for having arch specific path in noarch package aiming
|
||||||
|
for compatibility with old package (bsc#1179044)
|
||||||
|
* grub2.spec
|
||||||
|
- Fix non POSIX sed argument which failed in sed from busybox (bsc#1181091)
|
||||||
|
* grub2-check-default.sh
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Mon Nov 2 06:42:04 UTC 2020 - Michael Chang <mchang@suse.com>
|
Mon Nov 2 06:42:04 UTC 2020 - Michael Chang <mchang@suse.com>
|
||||||
|
|
||||||
|
34
grub2.spec
34
grub2.spec
@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package grub2
|
# spec file for package grub2
|
||||||
#
|
#
|
||||||
# Copyright (c) 2020 SUSE LLC
|
# Copyright (c) 2021 SUSE LLC
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@ -458,6 +458,10 @@ Requires(post): perl-Bootloader >= 0.706
|
|||||||
%endif
|
%endif
|
||||||
Provides: %{name}-efi = %{version}-%{release}
|
Provides: %{name}-efi = %{version}-%{release}
|
||||||
Obsoletes: %{name}-efi < %{version}-%{release}
|
Obsoletes: %{name}-efi < %{version}-%{release}
|
||||||
|
%ifarch x86_64
|
||||||
|
Conflicts: python2-kiwi < 9.17.12
|
||||||
|
Conflicts: python3-kiwi < 9.17.12
|
||||||
|
%endif
|
||||||
|
|
||||||
%description %{grubefiarch}
|
%description %{grubefiarch}
|
||||||
The GRand Unified Bootloader (GRUB) is a highly configurable and customizable
|
The GRand Unified Bootloader (GRUB) is a highly configurable and customizable
|
||||||
@ -490,6 +494,7 @@ Group: System/Boot
|
|||||||
Provides: %{name}-xen = %{version}-%{release}
|
Provides: %{name}-xen = %{version}-%{release}
|
||||||
Obsoletes: %{name}-xen < %{version}-%{release}
|
Obsoletes: %{name}-xen < %{version}-%{release}
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
|
Conflicts: xen < 4.12.0_03
|
||||||
|
|
||||||
%description %{grubxenarch}
|
%description %{grubxenarch}
|
||||||
The GRand Unified Bootloader (GRUB) is a highly configurable and customizable
|
The GRand Unified Bootloader (GRUB) is a highly configurable and customizable
|
||||||
@ -842,14 +847,6 @@ cd ..
|
|||||||
cd build-xen
|
cd build-xen
|
||||||
%make_install
|
%make_install
|
||||||
install -m 644 grub.xen %{buildroot}/%{_datadir}/%{name}/%{grubxenarch}/.
|
install -m 644 grub.xen %{buildroot}/%{_datadir}/%{name}/%{grubxenarch}/.
|
||||||
# provide compatibility sym-link for VM definitions pointing to old location
|
|
||||||
install -d %{buildroot}%{_libdir}/%{name}/%{grubxenarch}
|
|
||||||
ln -srf %{buildroot}%{_datadir}/%{name}/%{grubxenarch}/grub.xen %{buildroot}%{_libdir}/%{name}/%{grubxenarch}/grub.xen
|
|
||||||
cat <<-EoM >%{buildroot}%{_libdir}/%{name}/%{grubxenarch}/DEPRECATED
|
|
||||||
This directory and its contents was moved to %{_datadir}/%{name}/%{grubxenarch}.
|
|
||||||
Individual symbolic links are provided for a smooth transition.
|
|
||||||
Please update your VM definition files to use the new location!
|
|
||||||
EoM
|
|
||||||
cd ..
|
cd ..
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
@ -867,16 +864,6 @@ install -m 644 grub-tpm.efi %{buildroot}/%{_datadir}/%{name}/%{grubefiarch}/.
|
|||||||
%define sysefidir %{sysefibasedir}/%{_target_cpu}
|
%define sysefidir %{sysefibasedir}/%{_target_cpu}
|
||||||
install -d %{buildroot}/%{sysefidir}
|
install -d %{buildroot}/%{sysefidir}
|
||||||
ln -sr %{buildroot}/%{_datadir}/%{name}/%{grubefiarch}/grub.efi %{buildroot}%{sysefidir}/grub.efi
|
ln -sr %{buildroot}/%{_datadir}/%{name}/%{grubefiarch}/grub.efi %{buildroot}%{sysefidir}/grub.efi
|
||||||
%ifarch x86_64
|
|
||||||
# provide compatibility sym-link for previous shim-install and the like
|
|
||||||
install -d %{buildroot}/usr/lib64/efi
|
|
||||||
ln -srf %{buildroot}/%{_datadir}/%{name}/%{grubefiarch}/grub.efi %{buildroot}/usr/lib64/efi/grub.efi
|
|
||||||
cat <<-EoM >%{buildroot}/usr/lib64/efi/DEPRECATED
|
|
||||||
This directory and its contents was moved to %{_datadir}/efi/x86_64.
|
|
||||||
Individual symbolic links are provided for a smooth transition and
|
|
||||||
may vanish at any point in time. Please use the new location!
|
|
||||||
EoM
|
|
||||||
%endif
|
|
||||||
|
|
||||||
%ifarch x86_64 aarch64
|
%ifarch x86_64 aarch64
|
||||||
%if 0%{?suse_version} >= 1230 || 0%{?suse_version} == 1110
|
%if 0%{?suse_version} >= 1230 || 0%{?suse_version} == 1110
|
||||||
@ -1304,12 +1291,6 @@ fi
|
|||||||
%dir %{sysefidir}
|
%dir %{sysefidir}
|
||||||
%{sysefidir}/grub.efi
|
%{sysefidir}/grub.efi
|
||||||
%if 0%{?suse_version} < 1600
|
%if 0%{?suse_version} < 1600
|
||||||
%ifarch x86_64
|
|
||||||
# provide compatibility sym-link for previous shim-install and kiwi
|
|
||||||
%dir /usr/lib64/efi
|
|
||||||
/usr/lib64/efi/DEPRECATED
|
|
||||||
/usr/lib64/efi/grub.efi
|
|
||||||
%endif
|
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%ifarch x86_64 aarch64
|
%ifarch x86_64 aarch64
|
||||||
@ -1338,9 +1319,6 @@ fi
|
|||||||
%defattr(-,root,root,-)
|
%defattr(-,root,root,-)
|
||||||
%dir %{_datadir}/%{name}/%{grubxenarch}
|
%dir %{_datadir}/%{name}/%{grubxenarch}
|
||||||
%{_datadir}/%{name}/%{grubxenarch}/*
|
%{_datadir}/%{name}/%{grubxenarch}/*
|
||||||
# provide compatibility sym-link for VM definitions pointing to old location
|
|
||||||
%dir %{_libdir}/%{name}
|
|
||||||
%{_libdir}/%{name}/%{grubxenarch}
|
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%if 0%{?has_systemd:1}
|
%if 0%{?has_systemd:1}
|
||||||
|
Loading…
Reference in New Issue
Block a user