Hello community, here is the log from the commit of package os-prober.1953 for openSUSE:12.3:Update checked in at 2013-09-02 13:34:41 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:12.3:Update/os-prober.1953 (Old) and /work/SRC/openSUSE:12.3:Update/.os-prober.1953.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "os-prober.1953" Changes: -------- New Changes file: --- /dev/null 2013-07-23 23:44:04.804033756 +0200 +++ /work/SRC/openSUSE:12.3:Update/.os-prober.1953.new/os-prober.changes 2013-09-02 13:34:44.000000000 +0200 @@ -0,0 +1,85 @@ +------------------------------------------------------------------- +Fri Aug 16 15:45:01 UTC 2013 - [email protected] + +- update 05efi + * accept EFI partition on IMSM MD array (bnc#818871) + * fix DOS partition table detection + +------------------------------------------------------------------- +Fri Apr 5 16:33:28 UTC 2013 - [email protected] + +- add os-prober-linux-secure-boot.patch (bnc#810912) + * recognize linuxefi/initrdefi too + +------------------------------------------------------------------- +Sun Mar 3 16:06:32 UTC 2013 - [email protected] + +- 05efi - accept FUSE as valid filesystem too (bnc#807190) + +------------------------------------------------------------------- +Fri Feb 8 15:16:13 UTC 2013 - [email protected] + +- os-prober-usr_lib-detection.patch - fix detection of linux distro + which moved /lib to /usr/lib (e.g. Fedora) + +------------------------------------------------------------------- +Sat Jan 19 19:12:20 UTC 2013 - [email protected] + +- os-prober-1.49-grub2-mount.patch (bnc#767272) + * In openSUSE grub-mount is called grub2-mount + +------------------------------------------------------------------- +Sat Jan 19 13:41:59 UTC 2013 - [email protected] + +- fix os-prober-1.49-fix-grub2.cfg-parsing.patch (bnc#799457) + * initrd was missing + * entries sometimes were not emitted + +------------------------------------------------------------------- +Wed Jan 16 18:09:08 UTC 2013 - [email protected] + +- add os-prober-1.49-skip-LVM2_member.patch (bnc#798604) + * do not try to mount LVM2 PV + +------------------------------------------------------------------- +Tue Jan 8 07:14:53 UTC 2013 - [email protected] + +- add os-prober-1.49-fix-grub2.cfg-parsing.patch (bnc#796919) + +------------------------------------------------------------------- +Fri Jan 4 11:18:01 UTC 2013 - [email protected] + +- add support for chainloading another UEFI bootloader (bnc#775610) + * 05efi - top level driver to search ESP + * efi-20microsoft - support Microsoft UEFI bootloader + * efi-10elilo - support ELILO UEFI bootloader (Agnelo de la Crotche) +- skip legacy Microsoft bootloader on UEFI (bnc#775610) + +------------------------------------------------------------------- +Mon Dec 19 11:13:44 UTC 2011 - [email protected] + +- Clarify license. + +------------------------------------------------------------------- +Thu Dec 8 12:23:12 UTC 2011 - [email protected] + +- Update to 1.49: + * MeeGo detection support + * Bugfixes + +------------------------------------------------------------------- +Thu Dec 8 11:18:49 UTC 2011 - [email protected] + +- this seems to be "GPL" as it was understood 2004, so guessing + GPL-2.0+ + +------------------------------------------------------------------- +Fri Sep 30 15:53:26 UTC 2011 - [email protected] + +- cross-build fix: use %__cc macro + +------------------------------------------------------------------- +Tue Jul 12 13:08:58 UTC 2011 - [email protected] + +- Create new package. + New: ---- 05efi COPYING-note.txt efi-10elilo efi-20microsoft os-prober-1.49-fix-grub2.cfg-parsing.patch os-prober-1.49-grub2-mount.patch os-prober-1.49-skip-LVM2_member.patch os-prober-SUSE.patch os-prober-linux-secure-boot.patch os-prober-newnsdirfix.patch os-prober-skip-MS-legacy-on-UEFI.patch os-prober-usr_lib-detection.patch os-prober.changes os-prober.spec os-prober_1.49.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ os-prober.spec ++++++ # # spec file for package os-prober # # Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # Name: os-prober Version: 1.49 Release: 0 Summary: Probes disks on the system for installed operating systems License: GPL-2.0+ Group: System/Boot Url: http://kitenet.net/~joey/code/os-prober/ Source0: http://ftp.de.debian.org/debian/pool/main/o/os-prober/%{name}_%{version}.tar.gz Source1: COPYING-note.txt Source2: 05efi Source3: efi-20microsoft Source4: efi-10elilo # move newns binary outside of os-prober subdirectory, so that debuginfo # can be automatically generated for it Patch0: os-prober-newnsdirfix.patch # PATCH-FIX-OPENSUSE: Fix spelling of SUSE [email protected] Patch1: os-prober-SUSE.patch # PATCH-FIX-OPENSUSE: Skip legacy Microsoft bootloader on UEFI [bnc#775610] Patch2: os-prober-skip-MS-legacy-on-UEFI.patch # PATCH-FIX-OPENSUSE: Fix parsing of grub.cfg [bnc#796919] Patch3: os-prober-1.49-fix-grub2.cfg-parsing.patch # PATCH-FIX-OPENSUSE: Do not try to mount LVM2 PV [bnc#798604] Patch4: os-prober-1.49-skip-LVM2_member.patch # PATCH-FIX-OPENSUSE: Use correct name for grub2-mount Patch5: os-prober-1.49-grub2-mount.patch # PATCH-FIX-OPENSUSE: Detect distributions which moved /lib to /usr/lib Patch6: os-prober-usr_lib-detection.patch # PATCH-FIX-OPENSUSE: Detect linux secure boot entries too (bnc#810912) Patch7: os-prober-linux-secure-boot.patch Requires: /bin/grep Requires: /bin/sed Requires: /sbin/modprobe Requires: coreutils Requires: dmraid Requires: lvm2 Requires: udev Requires: util-linux %description This package detects other OSes available on a system and outputs the results in a generic machine-readable format. Support for new OSes and Linux distributions can be added easily. %prep %setup -q -n %{name} cp %SOURCE1 . %patch0 -p1 %patch1 -p1 %patch2 -p1 %patch3 -p1 %patch4 -p1 %patch5 -p1 %patch6 -p1 %patch7 -p1 %build make %{?_smp_mflags} CC="%__cc" CFLAGS="%{optflags}" %install install -m 0755 -d %{buildroot}%{_bindir} install -m 0755 -d %{buildroot}%{_localstatedir}/lib/%{name} install -m 0755 -p os-prober linux-boot-prober %{buildroot}%{_bindir} install -m 0755 -Dp newns %{buildroot}%{_libexecdir}/newns install -m 0644 -Dp common.sh %{buildroot}%{_datadir}/%{name}/common.sh %ifarch m68k ARCH=m68k %endif %ifarch ppc ppc64 ARCH=powerpc %endif %ifarch sparc sparc64 ARCH=sparc %endif %ifarch %{ix86} x86_64 ARCH=x86 %endif for probes in os-probes os-probes/mounted os-probes/init \ linux-boot-probes linux-boot-probes/mounted; do install -m 755 -d %{buildroot}%{_libexecdir}/$probes cp -a $probes/common/* %{buildroot}%{_libexecdir}/$probes if [ -e "$probes/$ARCH" ]; then cp -a $probes/$ARCH/* %{buildroot}%{_libexecdir}/$probes fi done if [ "$ARCH" = x86 ]; then install -m 755 -p os-probes/mounted/powerpc/20macosx \ %{buildroot}%{_libexecdir}/os-probes/mounted install -m 755 -p %SOURCE2 %{buildroot}%{_libexecdir}/os-probes/mounted install -m 755 -d %{buildroot}%{_libexecdir}/os-probes/mounted/efi install -m 755 -p %SOURCE3 \ %{buildroot}%{_libexecdir}/os-probes/mounted/efi/20microsoft install -m 755 -p %SOURCE4 \ %{buildroot}%{_libexecdir}/os-probes/mounted/efi/10elilo fi %files %defattr(-,root,root,-) %doc README TODO debian/copyright debian/changelog COPYING-note.txt %{_bindir}/* %{_libexecdir}/linux-boot-probes %{_libexecdir}/newns %{_libexecdir}/os-probes %{_datadir}/%{name} %{_localstatedir}/lib/%{name} %changelog ++++++ 05efi ++++++ #!/bin/sh # Detects all UEFI bootloaders on EFI System Partition . /usr/share/os-prober/common.sh partition="$1" mpoint="$2" type="$3" # This file is for UEFI platform only if [ ! -d /sys/firmware/efi ]; then debug "Not on UEFI platform" exit 1 fi # Weed out stuff that doesn't apply to us case "$type" in vfat) debug "$1 is a FAT32 partition" ;; msdos) debug "$1 is a FAT16 partition" ;; fuse|fuseblk) debug "$1 is a FUSE partition" ;; # might be GRUB *) debug "$1 is $type partition: exiting"; exit 1 ;; esac if type udevadm > /dev/null 2>&1; then udevinfo () { udevadm info "$@" } fi if type udevinfo > /dev/null 2>&1; then eval "$(udevinfo -q property -n "$partition" | grep -E '^(MD_CONTAINER|ID_PART_ENTRY_(TYPE|SCHEME))=')" debug "$partition container is '$MD_CONTAINER'" # Skip virtual devices unless they are known SW-RAID if udevinfo -q path -n $partition | grep -q /virtual/; then # Check for Intel Matrix array if [ -n "$MD_CONTAINER" ]; then eval "$(udevinfo -q property -n "$MD_CONTAINER" | grep -E '^MD_METADATA=')" debug "$MD_CONTAINER metadata is '$MD_METADATA'" fi if [ "$MD_METADATA" = imsm ]; then debug "$partition is on IMSM array" else debug "$1 is virtual device: exiting" exit 1 fi fi debug "$partition partition scheme is $ID_PART_ENTRY_SCHEME" debug "$partition partition type is $ID_PART_ENTRY_TYPE" if [ -z "$ID_PART_ENTRY_TYPE" -o -z "$ID_PART_ENTRY_SCHEME" -o \ \( "$ID_PART_ENTRY_SCHEME" != gpt -a "$ID_PART_ENTRY_SCHEME" != dos \) -o \ \( "$ID_PART_ENTRY_SCHEME" = gpt -a "$ID_PART_ENTRY_TYPE" != c12a7328-f81f-11d2-ba4b-00a0c93ec93b \) -o \ \( "$ID_PART_ENTRY_SCHEME" = dos -a "$ID_PART_ENTRY_TYPE" != 0xef \) ]; then debug "$partition is not a ESP partition: exiting" exit 1 fi else debug "udevinfo and udevadm missing - cannot check partition type" fi efi=$(item_in_dir efi "$mpoint") if [ -z "$efi" ]; then debug "$mpoint does not have /EFI directory: exiting" exit 1 fi ret=1 for test in /usr/lib/os-probes/mounted/efi/*; do debug "running subtest $test" if [ -f "$test" ] && [ -x "$test" ]; then entry=$("$test" "$mpoint/$efi") if [ -n "$entry" ]; then debug "bootloader $entry found by subtest $test" ret=0 result "${partition}@/$efi/${entry}:efi" fi fi done exit $ret ++++++ COPYING-note.txt ++++++ Version 1.50 of os-prober contains a license clarification, the license of the package is GPL-2+, see for example the following commits: http://anonscm.debian.org/gitweb/?p=d-i/os-prober.git;a=commitdiff;h=249d0814ae9c6e308baaaad4ec4e0a403a592ffd http://anonscm.debian.org/gitweb/?p=d-i/os-prober.git;a=commit;h=25024daeccd86cec17353455b99af677b3b83b16 http://anonscm.debian.org/gitweb/?p=d-i/os-prober.git;a=commit;h=cc0ce8e5ec252b10127ca3ebb71c12cd31d4ebc4 The copyright file reads as of 2011-12-19: The majority of code in os-prober is Copyright 2004-2011 by Joshua Kwan, Joey Hess, Christian Perrier, Colin Watson and Otavio Salvador. This is licensed under the terms of the GNU GPL, either version 2 or, at your option, any later version. Some portions of os-prober by other contributors has an unclear license of "GNU GPL", with the version not specified. On Debian systems, a copy of the GNU General Public License is available in /usr/share/common-licenses/GPL. ++++++ efi-10elilo ++++++ #!/bin/sh # Detects ELILO bootloader on a EFI System Partition . /usr/share/os-prober/common.sh efi="$1" found= elilo=`find $1 -name "elilo.efi"` if [ -n "$elilo" ]; then bdir=`dirname $elilo` bdir=`basename $bdir` vendor=$(echo $bdir | sed 's|SuSE|SUSE|') long="${vendor} ELILO Boot Manager" short="ELILO" path=${bdir}/elilo.efi found=true fi if [ -n "$found" ]; then label="$(count_next_label "$short")" result "${path}:${long}:${label}" fi exit 0 ++++++ efi-20microsoft ++++++ #!/bin/sh # Detects Microsoft bootloader on a EFI System Partition . /usr/share/os-prober/common.sh efi="$1" found= for microsoft in $(item_in_dir microsoft "$efi"); do for boot in $(item_in_dir boot "$efi/$microsoft"); do bcd=$(item_in_dir bcd "$efi/$microsoft/$boot") bootmgfw=$(item_in_dir bootmgfw.efi "$efi/$microsoft/$boot") if [ -n "$bcd" -a -n "$bootmgfw" ]; then long="Windows Boot Manager" short=Windows path="$microsoft/$boot/$bootmgfw" found=true break fi done done if [ -n "$found" ]; then label="$(count_next_label "$short")" result "${path}:${long}:${label}" fi exit 0 ++++++ os-prober-1.49-fix-grub2.cfg-parsing.patch ++++++ From: Andrey Borzenkov <[email protected]> Subject: fix parsing GRUB2 grub.cfg References: bnc#796919 Fix several problems in parsing of grub.cfg by linux-boot-probes/mounted/40grub2 1. It looked for /boot/grub/grub.cfg only. Make it check for /boot/grub2-efi/grub.cfg, /boot/grub2/grub.cfg, /boot/grub/grub.cfg in that order 2. Parsing of menuentry was completely broken. It is (near to) impossible to parse full fledged shell quoted strings with a couple of sed expressions. Replace it with ``eval "set -- $line"'', which should handle quoting automatically. It still may fail for manually created grub.cfg though. 3. It checked for literal "(on /dev/.*)" to filter out menu entries added by another os-prober on target system. But grub.cfg now includes TRANSLATED strings, so this check will fail if grub.cfg was created in non-English locale. Relax check and make it '(.* /dev/.*)'. It should work as long as grub.cfg was created by grub-mkconfig. Index: os-prober/linux-boot-probes/mounted/common/40grub2 =================================================================== --- os-prober.orig/linux-boot-probes/mounted/common/40grub2 +++ os-prober/linux-boot-probes/mounted/common/40grub2 @@ -34,33 +34,43 @@ parse_grub_menu () { title="" ignore_item=0 - while read line; do + # grub.cfg is written in shell like language that can contain + # arbitrary quoting. We need to extract second word according to + # normal quoting rules. Unfortunately, sticking ``eval $line'' for + # every line will try to interpret it according to shell + # grammar and error out for something as simple as "xxx; then". + # So the following is using it only on known cases. + # FIXME: it will fail if ``menuentry'' is not the first word on line. + # case patterns below include SPACE and TAB. + while read -r line; do debug "parsing: $line" - set -f - set -- $line - set +f - case "$1" in - menuentry) + line="$(printf "%s" "$line" | sed -e 's/^[[:space:]]*//')" + case "$line" in + menuentry[" "]*) entry_result - shift 1 - # The double-quoted string is the title. - title="$(echo "$@" | sed -n 's/[^"]*"\(.*\)".*/\1/p' | sed 's/://g')" - if [ -z "$title" ]; then - # ... or single-quoted? The - # unescaping here is odd because the - # 'set' above has already eaten - # backslash-escapes. - title="$(echo "$@" | sed -n "s/[^']*'\(.*\)'.*/\1/p" | sed "s/'''/'/; s/://g")" - fi + set -f + eval "set -- $line" + set +f + title="$2" if [ -z "$title" ]; then ignore_item=1 - elif echo "$title" | grep -q '(on /dev/[^)]*)$'; then + # Currently GRUB2 puts translated strings + # in grub.cfg, so checking for verbatim + # (on /dev/.*) will fail if target grub.cfg + # was created in non-English locale + elif echo "$title" | grep -q '(.* /dev/[^)]*)$'; then log "Skipping entry '$title':" log "appears to be an automatic reference taken from another menu.lst" ignore_item=1 fi ;; - linux) + linux[" "]*) + # And here we do NOT want to strip off + # existing quting, which will be transferred + # verbatim in new grub.cfg + set -f + set -- $line + set +f # Hack alert: sed off any (hdn,n) but # assume the kernel is on the same # partition. @@ -73,7 +83,13 @@ parse_grub_menu () { kernel="/boot$kernel" fi ;; - initrd) + initrd[" "]*) + # And here we do NOT want to strip off + # existing quting, which will be transferred + # verbatim in new grub.cfg + set -f + set -- $line + set +f initrd="$(echo "$2" | sed 's/(.*)//')" # Initrd same. if [ "$partition" != "$bootpart" ]; then @@ -89,11 +105,20 @@ parse_grub_menu () { entry_result } -if [ -e "$mpoint/boot/grub/grub.cfg" ] && \ +grubcfg= +if [ -e "$mpoint/boot/grub2-efi/grub.cfg" ]; then + grubcfg="$mpoint/boot/grub2-efi/grub.cfg" +elif [ -e "$mpoint/boot/grub2/grub.cfg" ]; then + grubcfg="$mpoint/boot/grub2/grub.cfg" +elif [ -e "$mpoint/boot/grub/grub.cfg" ]; then + grubcfg="$mpoint/boot/grub/grub.cfg" +fi + +if [ -n "$grubcfg" ] && \ ([ ! -e "$mpoint/boot/grub/menu.lst" ] || \ - [ "$mpoint/boot/grub/grub.cfg" -nt "$mpoint/boot/grub/menu.lst" ]); then - debug "parsing grub.cfg" - parse_grub_menu "$mpoint" "$partition" "$bootpart" < "$mpoint/boot/grub/grub.cfg" + [ "$grubcfg" -nt "$mpoint/boot/grub/menu.lst" ]); then + debug "parsing $grubcfg" + parse_grub_menu "$mpoint" "$partition" "$bootpart" < "$grubcfg" fi if [ "$found_item" = 0 ]; then ++++++ os-prober-1.49-grub2-mount.patch ++++++ From: Andrey Borzenkov <[email protected]> Subject: replace grub-mount with grub2-mount everywhere References: bnc#799457, bnc#767272 We use grub2-mount, not grub-mount. As shown in bnc#799457, grub2-mount may access filesystem even when kernel driver will refuse it. os-prober makes devices read-only to prevent accidental damage, so kernel driver fails if log replay is needed but cannot be performed. This may likely fix bnc#767272 Index: os-prober/common.sh =================================================================== --- os-prober.orig/common.sh +++ os-prober/common.sh @@ -259,8 +259,8 @@ linux_mount_boot () { debug "found boot partition $1 for linux system on $partition, but cannot map to existing device" else debug "found boot partition $bootpart for linux system on $partition" - if which grub-mount >/dev/null 2>&1 && \ - grub-mount "$boottomnt" "$tmpmnt/boot" 2>/dev/null; then + if which grub2-mount >/dev/null 2>&1 && \ + grub2-mount "$boottomnt" "$tmpmnt/boot" 2>/dev/null; then mounted=1 else ro_partition "$boottomnt" Index: os-prober/linux-boot-probes/common/50mounted-tests =================================================================== --- os-prober.orig/linux-boot-probes/common/50mounted-tests +++ os-prober/linux-boot-probes/common/50mounted-tests @@ -34,8 +34,8 @@ if [ ! -d "$tmpmnt" ]; then fi mounted= -if which grub-mount >/dev/null 2>&1 && \ - grub-mount "$partition" "$tmpmnt" 2>/dev/null; then +if which grub2-mount >/dev/null 2>&1 && \ + grub2-mount "$partition" "$tmpmnt" 2>/dev/null; then mounted=1 type=fuseblk else Index: os-prober/os-probes/common/50mounted-tests =================================================================== --- os-prober.orig/os-probes/common/50mounted-tests +++ os-prober/os-probes/common/50mounted-tests @@ -49,8 +49,8 @@ if [ ! -d "$tmpmnt" ]; then fi mounted= -if which grub-mount >/dev/null 2>&1 && \ - grub-mount "$partition" "$tmpmnt" 2>/dev/null; then +if which grub2-mount >/dev/null 2>&1 && \ + grub2-mount "$partition" "$tmpmnt" 2>/dev/null; then debug "mounted using GRUB" mounted=1 type=fuseblk Index: os-prober/os-probes/init/common/10filesystems =================================================================== --- os-prober.orig/os-probes/init/common/10filesystems +++ os-prober/os-probes/init/common/10filesystems @@ -3,7 +3,7 @@ set +e # ignore errors from modprobe FILESYSTEMS='ext2 ext3 ext4 reiserfs xfs jfs msdos vfat ntfs minix hfs hfsplus qnx4 ufs btrfs' -# fuse is needed to make grub-mount work. +# fuse is needed to make grub2-mount work. FILESYSTEMS="$FILESYSTEMS fuse" # The Ubuntu kernel udebs put a number of filesystem modules in # fs-{core,secondary}-modules. It's fairly cheap to check for these too. ++++++ os-prober-1.49-skip-LVM2_member.patch ++++++ Index: os-prober/os-probes/common/50mounted-tests =================================================================== --- os-prober.orig/os-probes/common/50mounted-tests +++ os-prober/os-probes/common/50mounted-tests @@ -15,6 +15,9 @@ elif [ "$types" = swap ]; then elif [ "$types" = crypto_LUKS ]; then debug "$1 is a LUKS partition; skipping" exit 0 +elif [ "$types" = LVM2_member ]; then + debug "$1 is a LVM2 partition; skipping" + exit 0 elif [ "$types" = ntfs ]; then if type ntfs-3g >/dev/null 2>&1; then types='ntfs-3g ntfs' ++++++ os-prober-SUSE.patch ++++++ Index: os-prober/os-probes/mounted/common/90linux-distro =================================================================== --- os-prober.orig/os-probes/mounted/common/90linux-distro +++ os-prober/os-probes/mounted/common/90linux-distro @@ -80,7 +80,7 @@ if ls "$dir"/lib*/ld*.so* >/dev/null 2>/ short="RedHat" long="$(cat "$dir/etc/redhat-release")" elif [ -e "$dir/etc/SuSE-release" ]; then - short="SuSE" + short="SUSE" long="$(head -n 1 "$dir/etc/SuSE-release")" elif [ -e "$dir/etc/gentoo-release" ]; then short="Gentoo" ++++++ os-prober-linux-secure-boot.patch ++++++ From: Andrey Borzenkov <[email protected]> Subject: detect linuxefi/initrdefi secure bootloaders too Reference: bnc#810912 Recognize initrdefi and linuxefi too. Whether linux/initrd or linuxefi/initrdefi will be emitted is controlled by SECURE_BOOT setting in /etc/sysconfig/bootloader. Index: os-prober/linux-boot-probes/mounted/common/40grub2 =================================================================== --- os-prober.orig/linux-boot-probes/mounted/common/40grub2 +++ os-prober/linux-boot-probes/mounted/common/40grub2 @@ -64,7 +64,7 @@ parse_grub_menu () { ignore_item=1 fi ;; - linux[" "]*) + linux[" "]*|linuxefi[" "]*) # And here we do NOT want to strip off # existing quting, which will be transferred # verbatim in new grub.cfg @@ -83,7 +83,7 @@ parse_grub_menu () { kernel="/boot$kernel" fi ;; - initrd[" "]*) + initrd[" "]*|initrdefi[" "]*) # And here we do NOT want to strip off # existing quting, which will be transferred # verbatim in new grub.cfg ++++++ os-prober-newnsdirfix.patch ++++++ diff -up os-prober-1.46/common.sh.newnsmove os-prober-1.46/common.sh --- os-prober-1.46/common.sh.newnsmove 2011-04-10 05:30:57.000000000 +0430 +++ os-prober-1.46/common.sh 2011-05-04 04:08:09.603020037 +0430 @@ -1,5 +1,5 @@ newns () { - [ "$OS_PROBER_NEWNS" ] || exec /usr/lib/os-prober/newns "$0" "$@" + [ "$OS_PROBER_NEWNS" ] || exec /usr/lib/newns "$0" "$@" } cleanup_tmpdir=false ++++++ os-prober-skip-MS-legacy-on-UEFI.patch ++++++ From: Andrey Borzenkov <[email protected]> Date: Fri Jan 4 09:46:56 UTC 2013 Subject: skip legacy Microsoft bootloader on UEFI system References: bnc#775610 Patch-Mainline: no Sometimes Windows installs both legacy BIOS and UEFI bootloaders. Attempt to chainload legacy bootloader on UEFI system fails. Skip adding legacy bootloader in this case. TODO: this probably should be implemented as runtime check. But it does the right thing in majority of cases. If mixed legacy/UEFI boot will be used frequently, it can be revisited. Index: os-prober/os-probes/mounted/x86/20microsoft =================================================================== --- os-prober.orig/os-probes/mounted/x86/20microsoft +++ os-prober/os-probes/mounted/x86/20microsoft @@ -7,6 +7,12 @@ partition="$1" mpoint="$2" type="$3" +# This script looks for legacy BIOS bootloaders only. Skip if running UEFI +if [ -d /sys/firmware/efi ]; then + debug "Skipping legacy bootloaders on UEFI system" + exit 1 +fi + # Weed out stuff that doesn't apply to us case "$type" in ntfs|ntfs-3g) debug "$1 is a NTFS partition" ;; ++++++ os-prober-usr_lib-detection.patch ++++++ From: Andrey Borzenkov <[email protected]> Subject: fix detection of distributions with /lib => /usr/lib symlink Upstream: yes grub-mount does not implement symbolic links, so distributions that replaced /lib with /usr/lib were not detected. Check both /lib and /usr/lib. Patch taken from upstream version. Affected is e.g. Fedora 18. Index: os-prober/os-probes/mounted/common/90linux-distro =================================================================== --- os-prober.orig/os-probes/mounted/common/90linux-distro +++ os-prober/os-probes/mounted/common/90linux-distro @@ -13,7 +13,7 @@ type="$3" # better. Make sure this test has a high number so that more accurate tests # can come first. # TODO: look for ld-linux.so on arches that have it -if ls "$dir"/lib*/ld*.so* >/dev/null 2>/dev/null; then +if (ls "$dir"/lib*/ld*.so* || ls "$dir"/usr/lib*/ld*.so*) >/dev/null 2>/dev/null; then if [ -e "$dir/etc/debian_version" ]; then short="Debian" long="$(printf "Debian GNU/Linux (%s)\n" "$(cat "$dir/etc/debian_version")")" -- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
