72b8e53663
- replace os-prober-grep-for-windows-bcd-file.patch by upstream's version * modified os-prober-grep-for-windows-bcd-file.patch - include patch from upstream to fix os-prober is missing support for Windows 10 (bsc#947487) * added os-prober-properly-detect-Windows-10.patch OBS-URL: https://build.opensuse.org/request/show/335138 OBS-URL: https://build.opensuse.org/package/show/Base:System/os-prober?expand=0&rev=60
65 lines
2.8 KiB
Diff
65 lines
2.8 KiB
Diff
From 15dec5c28b77b6db1492e42e25946cd7ae7a7885 Mon Sep 17 00:00:00 2001
|
|
From: Cyril Brulebois <kibi@debian.org>
|
|
Date: Fri, 10 Jul 2015 00:59:38 +0200
|
|
Subject: [PATCH] Add -a flag to grep -qs for Windows Vista detection (Closes:
|
|
#791383).
|
|
|
|
It appears the file isn't always considered as a text file, so this should be
|
|
more robust. Thanks to Gianluigi Tiesi for the report and the suggestion.
|
|
---
|
|
debian/changelog | 9 +++++++++
|
|
os-probes/mounted/x86/20microsoft | 14 +++++++-------
|
|
2 files changed, 16 insertions(+), 7 deletions(-)
|
|
|
|
diff --git a/debian/changelog b/debian/changelog
|
|
index 195a3f2..1643099 100644
|
|
--- a/debian/changelog
|
|
+++ b/debian/changelog
|
|
@@ -1,3 +1,12 @@
|
|
+os-prober (1.66) UNRELEASED; urgency=medium
|
|
+
|
|
+ * Add -a flag to grep -qs for Windows Vista detection. It appears the
|
|
+ file isn't always considered as a text file, so this should be more
|
|
+ robust. Thanks to Gianluigi Tiesi for the report and the suggestion
|
|
+ (Closes: #791383).
|
|
+
|
|
+ -- Cyril Brulebois <kibi@debian.org> Fri, 10 Jul 2015 00:56:21 +0200
|
|
+
|
|
os-prober (1.65) unstable; urgency=medium
|
|
|
|
[ Steve McIntyre ]
|
|
diff --git a/os-probes/mounted/x86/20microsoft b/os-probes/mounted/x86/20microsoft
|
|
index 6fb3cc5..af83f40 100755
|
|
--- a/os-probes/mounted/x86/20microsoft
|
|
+++ b/os-probes/mounted/x86/20microsoft
|
|
@@ -31,19 +31,19 @@ if item_in_dir -q bootmgr "$2"; then
|
|
for boot in $(item_in_dir boot "$2"); do
|
|
bcd=$(item_in_dir bcd "$2/$boot")
|
|
if [ -n "$bcd" ]; then
|
|
- if grep -qs "W.i.n.d.o.w.s. .8" "$2/$boot/$bcd"; then
|
|
+ if grep -aqs "W.i.n.d.o.w.s. .8" "$2/$boot/$bcd"; then
|
|
long="Windows 8 (loader)"
|
|
- elif grep -qs "W.i.n.d.o.w.s. .7" "$2/$boot/$bcd"; then
|
|
+ elif grep -aqs "W.i.n.d.o.w.s. .7" "$2/$boot/$bcd"; then
|
|
long="Windows 7 (loader)"
|
|
- elif grep -qs "W.i.n.d.o.w.s. .V.i.s.t.a" "$2/$boot/$bcd"; then
|
|
+ elif grep -aqs "W.i.n.d.o.w.s. .V.i.s.t.a" "$2/$boot/$bcd"; then
|
|
long="Windows Vista (loader)"
|
|
- elif grep -qs "W.i.n.d.o.w.s. .S.e.r.v.e.r. .2.0.0.8. .R.2." "$2/$boot/$bcd"; then
|
|
+ elif grep -aqs "W.i.n.d.o.w.s. .S.e.r.v.e.r. .2.0.0.8. .R.2." "$2/$boot/$bcd"; then
|
|
long="Windows Server 2008 R2 (loader)"
|
|
- elif grep -qs "W.i.n.d.o.w.s. .S.e.r.v.e.r. .2.0.0.8." "$2/$boot/$bcd"; then
|
|
+ elif grep -aqs "W.i.n.d.o.w.s. .S.e.r.v.e.r. .2.0.0.8." "$2/$boot/$bcd"; then
|
|
long="Windows Server 2008 (loader)"
|
|
- elif grep -qs "W.i.n.d.o.w.s. .R.e.c.o.v.e.r.y. .E.n.v.i.r.o.n.m.e.n.t" "$2/$boot/$bcd"; then
|
|
+ elif grep -aqs "W.i.n.d.o.w.s. .R.e.c.o.v.e.r.y. .E.n.v.i.r.o.n.m.e.n.t" "$2/$boot/$bcd"; then
|
|
long="Windows Recovery Environment (loader)"
|
|
- elif grep -qs "W.i.n.d.o.w.s. .S.e.t.u.p" "$2/$boot/$bcd"; then
|
|
+ elif grep -aqs "W.i.n.d.o.w.s. .S.e.t.u.p" "$2/$boot/$bcd"; then
|
|
long="Windows Recovery Environment (loader)"
|
|
else
|
|
long="Windows Vista (loader)"
|
|
--
|
|
1.8.5.2
|
|
|