Skip to content

Commit

Permalink
[backend] bring reposerver's getbuildinfo in sync with scheduler
Browse files Browse the repository at this point in the history
The prereqs were handled differently: the scheduler only uses them
when doing build expansion.
  • Loading branch information
mlschroe committed Mar 27, 2014
1 parent 2188c05 commit dd3f68f
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions src/backend/bs_repserver
Expand Up @@ -2698,9 +2698,7 @@ sub getbuildinfo {
} elsif (@subpacks) {
$ret->{'subpack'} = [ @subpacks ];
}
my @deps = @{$info->{'prereq'} || []};
@deps = grep {!/^\// || $bconf->{'fileprovides'}->{$_}} @deps;
unshift @deps, @{$info->{'dep'} || []};
my @deps = @{$info->{'dep'} || []};

# expand deps
$ret->{'expanddebug'} = '' if $cgi->{'debug'};
Expand Down Expand Up @@ -2785,7 +2783,8 @@ sub getbuildinfo {
$pool->createwhatprovides();
}

my @bdeps;
my @bdeps = grep {!/^\// || $bconf->{'fileprovides'}->{$_}} @{$info->{'prereq'} || []};
unshift @bdeps, @deps;
$Build::expand_dbg = 1 if $cgi->{'debug'};
my $xp = BSSolv::expander->new($pool, $bconf);
my $ownexpand = sub {
Expand All @@ -2796,7 +2795,7 @@ sub getbuildinfo {
local *Build::expand = $ownexpand;
use warnings 'redefine';
if (!$cgi->{'deps'}) {
@bdeps = Build::get_build($bconf, \@subpacks, @deps, @{$cgi->{'add'} || []});
@bdeps = Build::get_build($bconf, \@subpacks, @bdeps, @{$cgi->{'add'} || []});
} else {
@bdeps = Build::get_deps($bconf, \@subpacks, @deps, @{$cgi->{'add'} || []});
}
Expand Down

0 comments on commit dd3f68f

Please sign in to comment.