diff options
author | Oliver Tappe | 2007-05-18 19:59:01 +0200 |
---|---|---|
committer | Oliver Tappe | 2007-05-18 19:59:01 +0200 |
commit | e8198517caad8a97977a29cb5350018165eae2df (patch) | |
tree | 537740c3ac5be6371be6993ed491a4b9b6649cf6 /installer/OpenSLX/OSSetup/Engine.pm | |
parent | * fixed incorrect use of private-path instead of stage1-path, as reported (diff) | |
download | core-e8198517caad8a97977a29cb5350018165eae2df.tar.gz core-e8198517caad8a97977a29cb5350018165eae2df.tar.xz core-e8198517caad8a97977a29cb5350018165eae2df.zip |
* added support to packager for getting a list of the packages that are
already installed
git-svn-id: http://svn.openslx.org/svn/openslx/trunk@1087 95ad53e4-c205-0410-b2fa-d234c58c8868
Diffstat (limited to 'installer/OpenSLX/OSSetup/Engine.pm')
-rw-r--r-- | installer/OpenSLX/OSSetup/Engine.pm | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/installer/OpenSLX/OSSetup/Engine.pm b/installer/OpenSLX/OSSetup/Engine.pm index bc5856d2..006e31a4 100644 --- a/installer/OpenSLX/OSSetup/Engine.pm +++ b/installer/OpenSLX/OSSetup/Engine.pm @@ -863,11 +863,22 @@ sub stage1D_installPackageSelection vlog 1, "installing package selection <$selectionName>..."; my $pkgSelection = $self->{'distro-info'}->{selection}->{$selectionName}; my @pkgs = string2Array($pkgSelection); + my @installedPkgs = $self->{'packager'}->getInstalledPackages(); + @pkgs + = grep { + my $pkg = $_; + if (grep { $_ eq $pkg; } @installedPkgs) { + vlog 1, "package '$pkg' filtered, it is already installed."; + 0; + } else { + 1; + } + } @pkgs; if (scalar(@pkgs) == 0) { vlog 0, _tr("No packages listed for selection '%s', nothing to do.", $selectionName); } else { - vlog 2, "installing these packages:\n".join("\n\t", @pkgs); + vlog 1, "installing these packages:\n".join("\n\t", @pkgs); $self->{'meta-packager'}->startSession(); $self->{'meta-packager'}->installSelection(join " ", @pkgs); $self->{'distro'}->updateDistroConfig(); |