Skip to content

Commit

Permalink
[backend] findpackages: move multibuild processing after project link…
Browse files Browse the repository at this point in the history
… processing

We used to do multibuild processing first and relied on the project link
code to return the multibuild packages from the link. The problem with
this is that this uses the wrong multibuild data.

This commit changes findpackages_projlink to no longer return multibuild
packages and moves the addmultibuildpackages call after the
findpackages_projlink call.
  • Loading branch information
mlschroe committed Apr 1, 2020
1 parent 8738ce6 commit 1cb03a4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 2 additions & 0 deletions src/backend/BSSrcServer/Projlink.pm
Expand Up @@ -136,6 +136,8 @@ sub findpackages_projlink {
unshift @todo, map {$_->{'project'}} @$llink if $llink;
}
@lpackids = grep {$_ ne '_product' && !/^_product:/} @lpackids if $packids{'_product'};
# strip out multibuild packages
@lpackids = grep {!/(?<!^_product)(?<!^_patchinfo):./} @lpackids;
$packids{$_} = 1 for @lpackids;
if ($origins && $lorigins) {
for (@lpackids) {
Expand Down
4 changes: 3 additions & 1 deletion src/backend/bs_srcserver
Expand Up @@ -771,14 +771,16 @@ sub findpackages {
$origins->{$_} = $projid unless defined $origins->{$_};
}
}
@packids = BSSrcServer::Multibuild::addmultibuildpackages($projid, $origins, @packids) unless $deleted;

# handle project links (but not if deleted)
if ($proj && $proj->{'link'} && !$noexpand && !$deleted) {
push @packids, BSSrcServer::Projlink::findpackages_projlink($projid, $proj, $nonfatal, $origins);
@packids = sort(BSUtil::unify(@packids));
}

# add multibuild packages
@packids = BSSrcServer::Multibuild::addmultibuildpackages($projid, $origins, @packids) unless $deleted;

return @packids;
}

Expand Down

0 comments on commit 1cb03a4

Please sign in to comment.