manibuilder: Fix Ubuntu Noble Numbat (24.04) for amd64

Some parts of the Dockerfile.ubuntu accidentally broke the apt setup for
amd64. Check for the newer `/etc/apt/sources.list.d/ubuntu.sources', and
skip the old hacks if it exists.

Change-Id: Iae42ba548e5ffa228922bd060a38450e969e4405
Signed-off-by: Nico Huber <nico.h@gmx.de>
Reviewed-on: https://review.sourcearcade.org/c/flashprog/+/273
diff --git a/util/manibuilder/Dockerfile.ubuntu b/util/manibuilder/Dockerfile.ubuntu
index b9b818f..326f17f 100644
--- a/util/manibuilder/Dockerfile.ubuntu
+++ b/util/manibuilder/Dockerfile.ubuntu
@@ -2,7 +2,9 @@
 
 RUN \
 	useradd -p locked -m mani && \
-	if grep -q main /etc/apt/sources.list; then \
+	if [ -f /etc/apt/sources.list.d/ubuntu.sources ]; then \
+		true; \
+	elif grep -q main /etc/apt/sources.list; then \
 		if ! grep -q universe /etc/apt/sources.list; then \
 			sed -i -e 's/ main$/ main universe/' \
 				/etc/apt/sources.list || exit 1; \
diff --git a/util/manibuilder/Makefile.targets b/util/manibuilder/Makefile.targets
index a3f3582..de164df 100644
--- a/util/manibuilder/Makefile.targets
+++ b/util/manibuilder/Makefile.targets
@@ -47,7 +47,7 @@
 	$(foreach a,ppc64le mips64le s390x arm64v8 arm32v7 arm32v5 amd64 i386, \
 	  $(foreach v,bookworm, \
 	    $(a)/debian\:$(v))) \
-	$(foreach a,arm32v7 arm64v8 ppc64le s390x, \
+	$(foreach a,amd64 arm32v7 arm64v8 ppc64le s390x, \
 	  $(foreach v,noble, \
 	    $(a)/ubuntu\:$(v))) \
 	$(foreach a,ppc64le s390x arm64v8 arm32v7 arm32v6 amd64 i386, \