From c7b3dff10c273fc8f4b5f1fd5f801e6a0edf2be7 Mon Sep 17 00:00:00 2001 From: Nicolas Thill Date: Sun, 13 Apr 2008 22:36:51 +0000 Subject: install dependencies after installing package to avoid deep recursion and mass memory consuption SVN-Revision: 10823 --- scripts/feeds | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/scripts/feeds b/scripts/feeds index 2b50d5c1a5..78e65ad1d5 100755 --- a/scripts/feeds +++ b/scripts/feeds @@ -264,13 +264,6 @@ sub install_package { # newly installed packages set the source package $installed{$src} and return 0; - # install all dependencies - foreach my $dep (@{$pkg->{depends}}, @{$pkg->{builddepends}}) { - next if $dep =~ /@/; - $dep =~ s/^\+//; - install_package($feed, $dep) == 0 or $ret = 1; - } - # check previously installed packages $installed{$name} and return 0; $installed{$src} = 1; @@ -286,6 +279,13 @@ sub install_package { return 1; }; + # install all dependencies + foreach my $dep (@{$pkg->{depends}}, @{$pkg->{builddepends}}) { + next if $dep =~ /@/; + $dep =~ s/^\+//; + install_package($feed, $dep) == 0 or $ret = 1; + } + return $ret; } -- cgit v1.2.3