makechrootpkg: sync database for checkpkg to avoid nonexistent targets

For build servers or similar infrastructure its relatively common to not
sync/update the database regularly. This leads to problems properly
running checkpkg duo to nonexistent target files that we try to
download. As building on build servers is a very common use case, lets
ensure we sync the local database before trying to resolve the package
locations.
parent cee28a1b
......@@ -387,7 +387,7 @@ if (( ret != 0 )); then
else
if (( run_checkpkg )); then
msg "Running checkpkg"
remotepkgs=($(pacman -Sddp --logfile /dev/null "${pkgnames[@]}"))
remotepkgs=($(pacman -Syddp --logfile /dev/null "${pkgnames[@]}"|grep '://'))
if (( $? )); then
warning "Skipped checkpkg due to missing repo packages"
exit 0
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment