From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <gentoo-commits+bounces-1558194-garchives=archives.gentoo.org@lists.gentoo.org>
Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature RSA-PSS (2048 bits))
	(No client certificate requested)
	by finch.gentoo.org (Postfix) with ESMTPS id B7074158089
	for <garchives@archives.gentoo.org>; Thu, 28 Sep 2023 01:20:47 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id 060F12BC053;
	Thu, 28 Sep 2023 01:20:47 +0000 (UTC)
Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256)
	(No client certificate requested)
	by pigeon.gentoo.org (Postfix) with ESMTPS id DC96C2BC053
	for <gentoo-commits@lists.gentoo.org>; Thu, 28 Sep 2023 01:20:46 +0000 (UTC)
Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256)
	(No client certificate requested)
	by smtp.gentoo.org (Postfix) with ESMTPS id D18AC335C67
	for <gentoo-commits@lists.gentoo.org>; Thu, 28 Sep 2023 01:20:45 +0000 (UTC)
Received: from localhost.localdomain (localhost [IPv6:::1])
	by oystercatcher.gentoo.org (Postfix) with ESMTP id 50AF41124
	for <gentoo-commits@lists.gentoo.org>; Thu, 28 Sep 2023 01:20:44 +0000 (UTC)
From: "Sam James" <sam@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Content-Transfer-Encoding: 8bit
Content-type: text/plain; charset=UTF-8
Reply-To: gentoo-dev@lists.gentoo.org, "Sam James" <sam@gentoo.org>
Message-ID: <1695864026.e3b6ce2732f57003fda8023205cb7959fa517e8d.sam@gentoo>
Subject: [gentoo-commits] repo/gentoo:master commit in: app-emulation/qemu/
X-VCS-Repository: repo/gentoo
X-VCS-Files: app-emulation/qemu/Manifest app-emulation/qemu/qemu-9999.ebuild
X-VCS-Directories: app-emulation/qemu/
X-VCS-Committer: sam
X-VCS-Committer-Name: Sam James
X-VCS-Revision: e3b6ce2732f57003fda8023205cb7959fa517e8d
X-VCS-Branch: master
Date: Thu, 28 Sep 2023 01:20:44 +0000 (UTC)
Precedence: bulk
List-Post: <mailto:gentoo-commits@lists.gentoo.org>
List-Help: <mailto:gentoo-commits+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org>
X-BeenThere: gentoo-commits@lists.gentoo.org
X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply
X-Archives-Salt: 206f8084-90bc-40e3-a588-86da82324c26
X-Archives-Hash: 47e48c1f08ccd7b75d1413bdeff6c018

commit:     e3b6ce2732f57003fda8023205cb7959fa517e8d
Author:     Michal Privoznik <michal.privoznik <AT> gmail <DOT> com>
AuthorDate: Thu Sep  7 14:00:27 2023 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Thu Sep 28 01:20:26 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e3b6ce27

app-qemulation/qemu: Download subprojects in fetch phase

As suggested in [1], instead of using 'meson subprojects
download' in src_unpack() phase, the subproject tarballs can be
downloaded upfront and then merely just unpacked and moved to
their respective locations. This allows users to fetch sources
and build without network access.

1: https://github.com/gentoo/gentoo/pull/32484#discussion_r1308083818
Signed-off-by: Michal Privoznik <michal.privoznik <AT> gmail.com>
Closes: https://github.com/gentoo/gentoo/pull/32684
Signed-off-by: Sam James <sam <AT> gentoo.org>

 app-emulation/qemu/Manifest         |  3 +++
 app-emulation/qemu/qemu-9999.ebuild | 21 +++++++++++++++++++--
 2 files changed, 22 insertions(+), 2 deletions(-)

diff --git a/app-emulation/qemu/Manifest b/app-emulation/qemu/Manifest
index aeb71908b5db..a38c71af25bf 100644
--- a/app-emulation/qemu/Manifest
+++ b/app-emulation/qemu/Manifest
@@ -1,3 +1,6 @@
+DIST berkeley-softfloat-3-b64af41c3276f97f0e181920400ee056b9c88037.tar.gz 148741 BLAKE2B 72014022926b636147e202d74c42df2ce9cfed00b91c275d5b2e0afbc5c68765445cbe7ac6389d7c2512bd1d45b0e16e999936552d09bbc733ab66c92968bd31 SHA512 8420c29faa7ff57e06d6758b03e81ca0630c59946bc031e8611f1449e23634cf901b502161f2c1423c0cff949b5481445e36a3aa53dc885b61ca2c673b3ba567
+DIST berkeley-testfloat-3-40619cbb3bf32872df8c53cc457039229428a263.tar.gz 139281 BLAKE2B b370befc6a08e09ee84fa19d22628470063b7780d6aa931fb0a4bc9271e970f652f4067cd86cfb5eb4937508174f25cb3b40d20f3f01261fff539067a1e50887 SHA512 842c784674d2d606838a6870f8d53818eea4a86adc498a40fcb0a65a5c657ab7c4fe266029d46fed7297384c7f0b9abab571ceeb301192818fa68007a8ad738c
+DIST keycodemapdb-f5772a62ec52591ff6870b7e8ef32482371f22c6.tar.gz 29580 BLAKE2B 5511922dc8c4011a2c96f17f733c068e090fbb2b25227701bf73f66ea164892bdae09f08fb6888805aa7d018d97dfbc9872a907f3c55d293b2c5949d54ec9730 SHA512 6131753ed017fcdbf1d6b428d3dff79fd11800f9417c35ec45003b0b77ae7a36b9e1d4aec8e7fe256661baa367d9b0952a296afde4ccf3ed9e2a427b91009504
 DIST qemu-7.2.0-docs.tar.xz 1984184 BLAKE2B 103900fb7903ed8d75f7f012bf61fa2d6fce345b657c851d0437c3384f5735bd1cfd3129320683ea7846ea0b0940e5af5b2663c9320f12fee74b058523a8ea06 SHA512 a7edd448982865e07533c300d3e44a8b50cefbdde1982b73c24d0b2aa74315439252c59b634c75de312860874c7b06c75aa72629da681b5105f28ee936794585
 DIST qemu-7.2.0.tar.xz 122408576 BLAKE2B 415ff621356c59f88b29cfe3ef5db1e282b26bbafbee3d535477c6125ccb060ec9762d9e3ab9f70ce5478804dca0a46a59bcf12c112a2462029a93e578e61530 SHA512 f3cfa00da739ba819a218d7e6e95c77fb79a8e0f487b024ddd281602e785249b81144595e3f8c746c32a4f5c4d1a88c6aebae3c162603edfbb50ae3722d7ed13
 DIST qemu-7.2.1.tar.xz 122400592 BLAKE2B bae1df5d332beaca313c4bac88f06dd5992988d7c1b6fdc6ced4043d858f437339cd7d0009ae667f9e66705117697bee7ee44ec4e911cc203d34eecc3d8f139b SHA512 e286dc66c923a5df77eb02d69235d048e80a7cced638fae52fbed385b4c3cd736cfea66bb3c9843bebf0a33e81ea141fc015e0bd82108df304f148ce59d9ae8a

diff --git a/app-emulation/qemu/qemu-9999.ebuild b/app-emulation/qemu/qemu-9999.ebuild
index 6bc1056cfd1c..de4d90b78216 100644
--- a/app-emulation/qemu/qemu-9999.ebuild
+++ b/app-emulation/qemu/qemu-9999.ebuild
@@ -28,6 +28,16 @@ if [[ ${PV} == *9999* ]]; then
 	EGIT_SUBMODULES=()
 	inherit git-r3
 	SRC_URI=""
+	declare -A SUBPROJECTS=(
+		[keycodemapdb]="f5772a62ec52591ff6870b7e8ef32482371f22c6"
+		[berkeley-softfloat-3]="b64af41c3276f97f0e181920400ee056b9c88037"
+		[berkeley-testfloat-3]="40619cbb3bf32872df8c53cc457039229428a263"
+	)
+
+	for proj in "${!SUBPROJECTS[@]}"; do
+		c=${SUBPROJECTS[${proj}]}
+		SRC_URI+=" https://gitlab.com/qemu-project/${proj}/-/archive/${c}/${proj}-${c}.tar.gz"
+	done
 else
 	MY_P="${PN}-${PV/_rc/-rc}"
 	SRC_URI="https://download.qemu.org/${MY_P}.tar.xz"
@@ -439,8 +449,15 @@ check_targets() {
 if [[ ${PV} == 9999 ]]; then
 src_unpack() {
 	git-r3_src_unpack
-	cd "${P}" || die
-	meson subprojects download keycodemapdb berkeley-softfloat-3 berkeley-testfloat-3 || die
+	for file in ${A}; do
+		unpack "${file}"
+	done
+	cd ${WORKDIR} || die
+	for proj in "${!SUBPROJECTS[@]}"; do
+		mv "${proj}-${SUBPROJECTS[${proj}]}" "${S}/subprojects/${proj}" || die
+	done
+	cd "${S}" || die
+	meson subprojects packagefiles --apply || die
 }
 fi