diff options
author | Martin Whitaker <mageia@martin-whitaker.me.uk> | 2017-04-02 12:19:44 +0100 |
---|---|---|
committer | RĂ©mi Verschelde <rverschelde@gmail.com> | 2017-04-04 20:05:53 +0200 |
commit | 4c91aaced1cb66d37bd1aae558b4e3364555d1cc (patch) | |
tree | 45c8de3271eb82b4c95874927a9c4a0d40236bf8 /perl-install | |
parent | b7a7defc4a6d8277adb2aec39b7b60c1165365f7 (diff) | |
download | drakx-4c91aaced1cb66d37bd1aae558b4e3364555d1cc.tar drakx-4c91aaced1cb66d37bd1aae558b4e3364555d1cc.tar.gz drakx-4c91aaced1cb66d37bd1aae558b4e3364555d1cc.tar.bz2 drakx-4c91aaced1cb66d37bd1aae558b4e3364555d1cc.tar.xz drakx-4c91aaced1cb66d37bd1aae558b4e3364555d1cc.zip |
Fix do_pkgs_standalone::remove() for Live install.
When running a Live install, we generally need to chroot to the
install root when removing packages.
This was causing os-prober to be removed from the Live system
instead of from the installed system when the "Probe foreign OS"
option was unchecked.
Diffstat (limited to 'perl-install')
-rw-r--r-- | perl-install/do_pkgs.pm | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/perl-install/do_pkgs.pm b/perl-install/do_pkgs.pm index 4de82a093..e4b9b0198 100644 --- a/perl-install/do_pkgs.pm +++ b/perl-install/do_pkgs.pm @@ -388,7 +388,8 @@ sub remove { my $_wait = $do->in && $do->in->wait_message(N("Please wait"), N("Removing packages...")); $do->in->suspend if $do->in; log::explanations("removing packages @l"); - my $ret = system('rpm', '-e', @l) == 0; + my @wrapper = $::isLiveInstall && $::prefix ? ('chroot', $::prefix) : (); + my $ret = system(@wrapper, 'rpm', '-e', @l) == 0; $do->in->resume if $do->in; $ret; } |