summaryrefslogtreecommitdiffstats
path: root/perl-install/do_pkgs.pm
diff options
context:
space:
mode:
authorThierry Vignaud <thierry.vignaud@gmail.com>2015-01-07 01:13:50 +0100
committerThomas Backlund <tmb@mageia.org>2015-01-09 03:22:08 +0159
commit03bc6a6d53521054e42b6c43352fbd00ed285c6c (patch)
tree48299ca538e5e526ba3d3026bf2ba104058fa029 /perl-install/do_pkgs.pm
parent5af43b9e8eb15108b3c1195f393754e42e432c3e (diff)
downloaddrakx-03bc6a6d53521054e42b6c43352fbd00ed285c6c.tar
drakx-03bc6a6d53521054e42b6c43352fbd00ed285c6c.tar.gz
drakx-03bc6a6d53521054e42b6c43352fbd00ed285c6c.tar.bz2
drakx-03bc6a6d53521054e42b6c43352fbd00ed285c6c.tar.xz
drakx-03bc6a6d53521054e42b6c43352fbd00ed285c6c.zip
install packages in chroot when in mgalive mode
Diffstat (limited to 'perl-install/do_pkgs.pm')
-rw-r--r--perl-install/do_pkgs.pm5
1 files changed, 3 insertions, 2 deletions
diff --git a/perl-install/do_pkgs.pm b/perl-install/do_pkgs.pm
index a8ea89e1e..0640d0908 100644
--- a/perl-install/do_pkgs.pm
+++ b/perl-install/do_pkgs.pm
@@ -333,15 +333,16 @@ sub install {
return 1;
}
+ my @wrapper = is_mgalive() ? qw(chroot /mnt) : ();
my @options = ('--allow-medium-change', '--auto', '--no-verify-rpm', '--expect-install', @l);
my $ret;
if (check_for_xserver() && -x '/usr/bin/gurpmi') {
- $ret = system('gurpmi', @options) == 0;
+ $ret = system(@wrapper, 'gurpmi', @options) == 0;
} else {
my $_wait = $do->in && $do->in->wait_message(N("Please wait"), N("Installing packages..."));
$do->in->suspend if $do->in;
log::explanations("installing packages @l");
- $ret = system('urpmi', @options) == 0;
+ $ret = system(@wrapper, 'urpmi', @options) == 0;
$do->in->resume if $do->in;
}
$ret;