summaryrefslogtreecommitdiffstats
path: root/perl-install
diff options
context:
space:
mode:
Diffstat (limited to 'perl-install')
-rw-r--r--perl-install/bootloader.pm11
1 files changed, 5 insertions, 6 deletions
diff --git a/perl-install/bootloader.pm b/perl-install/bootloader.pm
index 012921026..67ab14c00 100644
--- a/perl-install/bootloader.pm
+++ b/perl-install/bootloader.pm
@@ -229,12 +229,11 @@ sub read_grub {
}
}
}
- foreach (cat_("$::prefix/boot/grub/install.sh")) {
- if (/\s+d\s+(\(.*?\))/) {
- $b{boot} = grub2dev($1, $grub2dev);
- } elsif (/^setup\s+(\(.*?\))/) {
- $b{boot} = grub2dev($1, $grub2dev);
- }
+ #- matches either:
+ #- setup (hd0)
+ #- install (hd0,0)/boot/grub/stage1 d (hd0) (hd0,0)/boot/grub/stage2 p (hd0,0)/boot/grub/menu.lst
+ if (cat_("$::prefix/boot/grub/install.sh") =~ /^(?:setup|install\s+(?:\S+)(?:\s+d)?)\s+(\(.*?\))/m) {
+ $b{boot} = grub2dev($1, $grub2dev);
}
#- sanitize