build: package: build build packages even when nothing else is queued (MR 2376)

Bail on empty build queue after checking if build_packages need
building. So if apk-tools / alpine-base / etc are outdated but nothing
else is they'll still be built.

Signed-off-by: Caleb Connolly <caleb@postmarketos.org>
This commit is contained in:
Caleb Connolly 2024-07-18 02:34:23 +02:00
parent b14a872fad
commit d8e5037336
No known key found for this signature in database
GPG key ID: 5AE7F5513E0885CB

View file

@ -420,9 +420,6 @@ def packages(
context, queue_build, pkgname, arch, fallback_arch, force
)
if not len(build_queue):
return []
# If any of our common build packages need to be built and are missing, then add them
# to the queue so they're built first. This is necessary so that our abuild fork is
# always built first (for example). For now assume that if building in strict mode we
@ -443,6 +440,9 @@ def packages(
)
queue_build(aport, apkbuild, get_depends(context, apkbuild))
if not len(build_queue):
return []
# We built the queue by pushing each package before it's dependencies. Now we
# need to go backwards through the queue and build the dependencies first.
build_queue.reverse()