diff options
author | Thomas Backlund <tmb@mageia.org> | 2012-12-17 19:07:47 +0000 |
---|---|---|
committer | Thomas Backlund <tmb@mageia.org> | 2012-12-17 19:07:47 +0000 |
commit | 7fd2efcef961711a995a89c3245a972a136e2463 (patch) | |
tree | ddec8283adaf6df350b93f1914b5b4647fd1a6ea /perl-install | |
parent | e5660bf092c9a54871d60b7eaf9393133d509e2e (diff) | |
download | drakx-7fd2efcef961711a995a89c3245a972a136e2463.tar drakx-7fd2efcef961711a995a89c3245a972a136e2463.tar.gz drakx-7fd2efcef961711a995a89c3245a972a136e2463.tar.bz2 drakx-7fd2efcef961711a995a89c3245a972a136e2463.tar.xz drakx-7fd2efcef961711a995a89c3245a972a136e2463.zip |
fix installing grub2 from live session (blino)
Diffstat (limited to 'perl-install')
-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 |