forked from pool/grub2
Accepting request 157383 from Base:System
(forwarded request 157376 from arvidjaar) OBS-URL: https://build.opensuse.org/request/show/157383 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/grub2?expand=0&rev=59
This commit is contained in:
parent
f57b826262
commit
b4a93d3f89
42
grub2-grub-mount-return-failure-if-FUSE-failed.patch
Normal file
42
grub2-grub-mount-return-failure-if-FUSE-failed.patch
Normal file
@ -0,0 +1,42 @@
|
||||
From: Andrey Borzenkov <arvidjaar@gmail.com>
|
||||
To: grub-devel@gnu.org
|
||||
Subject: [PATCH] return failure from grub-mount if fuse_main failed
|
||||
|
||||
Currently there is no way to check that mount was successful. It caused
|
||||
problem with os-prober which did not try kernel mount fallback.
|
||||
|
||||
Return value of fuse_init is currenty unused, but still it looks wrong
|
||||
to always return success. In this case it should simply be void; if it
|
||||
returns value, let value be correct.
|
||||
|
||||
Ref: https://bugzilla.novell.com/show_bug.cgi?id=802983
|
||||
|
||||
Signed-off-by: Andrey Borzenkov <arvidjaar@gmail.com>
|
||||
|
||||
---
|
||||
util/grub-mount.c | 5 +++--
|
||||
1 file changed, 3 insertions(+), 2 deletions(-)
|
||||
|
||||
Index: grub-2.00/util/grub-mount.c
|
||||
===================================================================
|
||||
--- grub-2.00.orig/util/grub-mount.c
|
||||
+++ grub-2.00/util/grub-mount.c
|
||||
@@ -383,7 +383,8 @@ fuse_init (void)
|
||||
return grub_errno;
|
||||
}
|
||||
|
||||
- fuse_main (fuse_argc, fuse_args, &grub_opers, NULL);
|
||||
+ if (fuse_main (fuse_argc, fuse_args, &grub_opers, NULL))
|
||||
+ grub_error (GRUB_ERR_UNKNOWN_FS, "fuse_main failed");
|
||||
|
||||
for (i = 0; i < num_disks; i++)
|
||||
{
|
||||
@@ -403,7 +404,7 @@ fuse_init (void)
|
||||
grub_free (loop_name);
|
||||
}
|
||||
|
||||
- return GRUB_ERR_NONE;
|
||||
+ return grub_errno;
|
||||
}
|
||||
|
||||
static struct argp_option options[] = {
|
@ -1,3 +1,14 @@
|
||||
-------------------------------------------------------------------
|
||||
Mon Mar 4 16:48:32 UTC 2013 - arvidjaar@gmail.com
|
||||
|
||||
- grub2-grub-mount-return-failure-if-FUSE-failed.patch - return error
|
||||
if fuse_main failed (bnc#802983)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Feb 25 13:31:31 UTC 2013 - fcrozat@suse.com
|
||||
|
||||
- Fix build for SLES 11.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Feb 19 15:38:04 UTC 2013 - duwe@suse.com
|
||||
|
||||
|
10
grub2.spec
10
grub2.spec
@ -46,7 +46,7 @@ BuildRequires: texinfo
|
||||
BuildRequires: python
|
||||
BuildRequires: xz-devel
|
||||
%ifarch x86_64
|
||||
%if 0%{?suse_version} >= 1230 || 0%{?sles_version} >= 11
|
||||
%if 0%{?suse_version} >= 1230 || 0%{?suse_version} == 1110
|
||||
BuildRequires: pesign-obs-integration
|
||||
%endif
|
||||
%endif
|
||||
@ -79,7 +79,7 @@ BuildRequires: pesign-obs-integration
|
||||
%endif
|
||||
%endif
|
||||
|
||||
%if 0%{?suse_version} == 1110 || 0%{?sles_version} == 11
|
||||
%if 0%{?suse_version} == 1110
|
||||
%define only_efi %{nil}
|
||||
%define only_x86_64 %{nil}
|
||||
%endif
|
||||
@ -133,6 +133,7 @@ Patch28: grub2-fix-unquoted-string-in-class.patch
|
||||
Patch29: grub2-secureboot-chainloader.patch
|
||||
Patch30: grub2-cdpath.patch
|
||||
Patch31: efidisk-ahci-workaround
|
||||
Patch32: grub2-grub-mount-return-failure-if-FUSE-failed.patch
|
||||
PreReq: perl-Bootloader
|
||||
Requires: gettext-runtime
|
||||
%if 0%{?suse_version} >= 1140
|
||||
@ -233,7 +234,7 @@ provides support for EFI systems.
|
||||
%patch0 -p1
|
||||
%patch1 -p1
|
||||
# Workaround SLE11's patch utility did not rename the file for us
|
||||
%if 0%{?suse_version} == 1110 || 0%{?sles_version} == 11
|
||||
%if 0%{?suse_version} == 1110
|
||||
mv docs/grub.texi docs/grub2.texi
|
||||
%endif
|
||||
%patch2 -p1
|
||||
@ -268,6 +269,7 @@ mv docs/grub.texi docs/grub2.texi
|
||||
%patch29 -p1
|
||||
%patch30 -p1
|
||||
%patch31 -p1
|
||||
%patch32 -p1
|
||||
|
||||
# README.openSUSE
|
||||
cp %{SOURCE3} .
|
||||
@ -355,7 +357,7 @@ make %{?_smp_mflags}
|
||||
%install
|
||||
%ifarch %{efi}
|
||||
%ifarch x86_64
|
||||
%if 0%{?suse_version} >= 1230 || 0%{?sles_version} >= 11
|
||||
%if 0%{?suse_version} >= 1230 || 0%{?suse_version} == 1110
|
||||
export BRP_PESIGN_FILES="%{_libdir}/%{name}/%{grubefiarch}/grub.efi"
|
||||
%endif
|
||||
%endif
|
||||
|
Loading…
Reference in New Issue
Block a user