diff options
-rw-r--r-- | perl-install/NEWS | 2 | ||||
-rw-r--r-- | perl-install/bootloader.pm | 8 | ||||
-rw-r--r-- | perl-install/install/NEWS | 1 |
3 files changed, 9 insertions, 2 deletions
diff --git a/perl-install/NEWS b/perl-install/NEWS index 770a1d420..7fb47634e 100644 --- a/perl-install/NEWS +++ b/perl-install/NEWS @@ -1,4 +1,6 @@ - ugtk2: use new exceptions management +- drakboot: + o fix installing grub2 from live session (blino) Version 15.13 - 15 December 2012 diff --git a/perl-install/bootloader.pm b/perl-install/bootloader.pm index dd0b25551..cecd5aa4c 100644 --- a/perl-install/bootloader.pm +++ b/perl-install/bootloader.pm @@ -1970,9 +1970,13 @@ sub restore_previous_MBR_bootloader { sub install_grub2 { my ($bootloader, $_all_hds) = @_; my $error; - run_program::rooted($::prefix, 'grub2-install', '2>', \$error, $bootloader->{boot}) or die "grub2 failed: $error"; + my $grub2_cfg = "/boot/grub2/grub.cfg"; + if (!-s "$::prefix/$grub2_cfg") { + run_program::rooted($::prefix, 'grub2-mkconfig', '2>', \$error, '-o', $grub2_cfg) or die "grub2-mkconfig failed: $error"; + } + run_program::rooted($::prefix, 'grub2-install', '2>', \$error, $bootloader->{boot}) or die "grub2-install failed: $error"; } - + sub install_grub { my ($bootloader, $all_hds) = @_; diff --git a/perl-install/install/NEWS b/perl-install/install/NEWS index 9cfa756b9..4f749b4de 100644 --- a/perl-install/install/NEWS +++ b/perl-install/install/NEWS @@ -1,4 +1,5 @@ - ugtk2: use new exceptions management +- fix installing grub2 from live session (blino) Version 15.13 - 15 December 2012 |