Skip to content

Commit

Permalink
Remove duplicate options and dependencies from respective variables
Browse files Browse the repository at this point in the history
Duplicate options e.g. "+FOO +FOO" was causing the wanted and remote
options comparison to fail, causing poudriere to build packages
unnecessarily.

Duplicate dependencies e.g. "foo/bar foo/bar" was causing the wanted
and remote deps comparison to fail, causing poudriere to skip packages.
  • Loading branch information
patmaddox committed Jul 27, 2023
1 parent 97404ba commit 1d234c2
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/share/poudriere/common.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3679,7 +3679,7 @@ download_from_repo_check_pkg() {
$1 == pkgbase && $3 == "off" {print "-"$2;printed=1}
$1 != pkgbase && printed == 1 {exit}
' \
"${remote_all_options}" | sort -k1.2 | paste -s -d ' ' -)
"${remote_all_options}" | sort -k1.2 -u | paste -s -d ' ' -)

shash_get pkgname-options "${pkgname}" selected_options || \
selected_options=
Expand All @@ -3705,7 +3705,8 @@ download_from_repo_check_pkg() {
$1 == pkgbase {print $2;printed=1}
$1 != pkgbase && printed == 1 {exit}
' \
"${remote_all_deps}" | sort | paste -s -d ' ' -)
"${remote_all_deps}" | sort -u | paste -s -d ' ' -)

case "${local_deps}" in
${remote_deps}) ;;
*)
Expand Down

0 comments on commit 1d234c2

Please sign in to comment.