From nobody Mon Nov 23 04:18:40 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=oss.qualcomm.com ARC-Seal: i=1; a=rsa-sha256; t=1793232579; cv=none; d=zohomail.com; s=zohoarc; b=XBu5ownqZEg0vz7YI1u1wfl9z2lt+4sNGteQdRxaP/9H12p/sMH77WcIoQaS6ulnL+daGxQ090MT0q87jafxsm6cy2YlwsZkW5GYTpBRW0944qcxk51ZEUTAhUFPZ/i22nLRrcfsqmkvT6GaZJ504kkHzySNR7wCxOxBqEmw3A4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1793232579; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=gkkG7ylAmpcRku4JtK/ff051MCvMqQjlM1vb9OyiFo8=; b=Y5A1NY0ZUl3U5IqUchKKYJ8ShC3T5zYxK9FX9t2K1L5PuiXJwRHDtZ8H5Un5Cj3JrhXHuu6ror+mx4SXDu7YD6fC+8QZkkWdYSk2irUhGhUdXEq6P/RWkeEZ2PaP5nOZR7yExO8/Cvco4aKB4YTsMEftiAKJAZCMt10Lwq3V3F0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1793232579281816.0424569298981; Wed, 28 Oct 2026 17:09:39 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1xMDhe-0001lD-T8; Wed, 28 Oct 2026 20:09:10 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xMDhY-0001jz-I9 for qemu-devel@nongnu.org; Wed, 28 Oct 2026 20:09:05 -0400 Received: from mx0a-0031df01.pphosted.com ([205.220.168.131]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xMDhW-0000ER-Mc for qemu-devel@nongnu.org; Wed, 28 Oct 2026 20:09:04 -0400 Received: from pps.filterd (m0279863.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 69SMAVq32428939 for ; Thu, 29 Oct 2026 00:09:00 GMT Received: from mail-pf1-f197.google.com (mail-pf1-f197.google.com [209.85.210.197]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4hkbhwc2ng-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Thu, 29 Oct 2026 00:09:00 +0000 (GMT) Received: by mail-pf1-f197.google.com with SMTP id d2e1a72fcca58-8a03834d8ffso2065808b3a.3 for ; Wed, 28 Oct 2026 17:09:00 -0700 (PDT) Received: from pc.taild8403c.ts.net (192-80-163-190.dyn.novuscom.net. [192.80.163.190]) by smtp.gmail.com with ESMTPSA id 41be03b00d2f7-cd8ccc682d8sm4644744a12.18.2026.10.28.17.08.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Oct 2026 17:08:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= gkkG7ylAmpcRku4JtK/ff051MCvMqQjlM1vb9OyiFo8=; b=YlILoPzoJBrVIadR hWN1VJ9q2cKHR0guZKXCcZb/PThtnbETS1sCAKsGxnHUblH3grA5k+aM8cIErvaj Xm++Ey2746uPrxTTpjdDOnYLyNRyLrYH1WkzoQtCuD06qLDsDRh2NSgS7EP9e6cb CuMHGA499AIVwm7A2u7AUIvEQwNcAyQgSKsYGG9ILnPaYkbn6j18Bupynb4LH4Yj 7CrqbTWhN59bu04BHZ1u8nZ0X3vw6nOwGPeTCTAEtDbh0mtrER7KhhXwCZdRJxQf /+XYQE9unU4hM8Uqd5BJzMKtFcSxylECjo5+aL8bHHi2TThhJxba5MlQUjDTzbvv Q13ZhA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1793232540; x=1793837340; darn=nongnu.org; h=content-transfer-encoding:content-type:mime-version:references :in-reply-to:message-id:date:subject:cc:to:from:from:to:cc:subject :date:message-id:reply-to:content-type; bh=gkkG7ylAmpcRku4JtK/ff051MCvMqQjlM1vb9OyiFo8=; b=S5ctKzrya7/Ga5B/3ys57OVFZeewOQztBSqIKyplJxfDfAl2Phew+jsIdRpeekLAj0 4RZJE6GjyzMRx4k4QcsvJcxPpPf2TckL2YHcAWMuG2HRZ0g6gIvtEHI5xSozn1R4tK/s qUTEEM+2gFkQVT/2r1x4ZcoVoi4mV8fh6WmCqIUtp+3iUqysgSzs3bIxDGy91WcgKbD/ UKhKP4jZ+lNBmYUm/5AoC67o1hpUeF4eowbQdBT0Nl10udkmiUcGRt+xHsE2Col2Wn/8 agQYyAx4g+AHPRgSb0TK2Pgi4XmlkGy1PnMwi66JbzGAh51s9egV8FJ7KQjCWwGHm5qh 6XoQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1793232540; x=1793837340; h=content-transfer-encoding:content-type:mime-version:references :in-reply-to:message-id:date:subject:cc:to:from:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to :content-type; bh=gkkG7ylAmpcRku4JtK/ff051MCvMqQjlM1vb9OyiFo8=; b=PRpGnj8WTlmXZAiNAUKdaUXgX1kl62vgETJ2lMljFu8dNFtM1gdCQelj3cN902a02Y QUF5egHSfziNaJaPt3MsFx6F/iZ89grYqmimPsYP26S528F2NlSOD0ojDXYG9+NiEdLL +PXudy9RH4scUALjxNMhRAmu1Qrmtz+JYcGUxbRuIz+uMgDoVgCNjdruq+5FPhM7w3F4 wUmkOOpK/LiocMD4l80j7EeO0Oxl5p/dj0Y8btIiIc4PNoi9hghVj43F21AnjVD6EG9e q9WXwYvXhPtYgbwREpTPwRZmHK2EE8Yl45fWqZNiwWh1FPKy05yU4/OyUPAWno1IVakl Z7Dg== X-Gm-Message-State: AFq9FYLjCxtFXfFSx0JvnQyrkbLRrX/vKaQHfI8AAgt8rSIdxYIVI9TU vTB2rG4AySNySs96QZEG5sNw8j6deK5VsAfr1iUCMsf1SB/yIH8vzaHiuyeqP265DbOQOxePtBm SVOy/WUdDDtyrcp0VKMLSeV9qeN7qIKetHf4b6nO5SAhDxgPM6U4s00SfyHPMQq5m7w== X-Gm-Gg: AYBFou2ysNNJZ+Ue6IDN1KSxoOgERRCOW0rwzwNs2jv5PwFZHWcibeiTd0f0FLtNZhT p7qNxn3l4RF2xmQAs633kjfGt4/WMh+iZpAosR6JSIjm+kdli/nluAOS1H2/BdzxpISUsimwpVs VRbs04RHt5qt+EE1S1IbHiZmqe17lZLII4izxWdHeZ3rCOwtjutDN7EhCx1zBadY/m4V1BRyOl7 XlA94knYxuU68CZq9OBwVuHHbwGkGh3g7Idm8ljxDg0ffB8EscnORx4OE7feSedbjCmSMgcgph8 IfdKyrOYrHNpKVoyd6J1sN2ty75r17c5BisGq58mGXja2MDcS54ZPKkO4oQlhnuVsO57jjyYoGL TK9C7mqBFJHHI6BDnEjvgu9ICKQFJktJubom2b39Yr2FzMVZGjDxGAk0/de/7Q490Dk66O6OD9k W+OCR+jNBUZyvmNGsQXc+U1K2rYSwPI3xmHf5n X-Received: by 2002:a05:6a21:b84:b0:3c3:875d:c52f with SMTP id adf61e73a8af0-3e9020eef8amr3076074637.10.1793232539777; Wed, 28 Oct 2026 17:08:59 -0700 (PDT) X-Received: by 2002:a05:6a21:b84:b0:3c3:875d:c52f with SMTP id adf61e73a8af0-3e9020eef8amr3076055637.10.1793232539280; Wed, 28 Oct 2026 17:08:59 -0700 (PDT) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: =?UTF-8?q?Alex=20Benn=C3=A9e?= , peterx@redhat.com, Fabiano Rosas , mjt@tls.msk.ru, =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Pierrick Bouvier Subject: [PATCH v5 1/2] tests/docker/dockerfiles: add release.docker Date: Thu, 29 Oct 2026 00:08:52 +0000 Message-ID: <20261029000853.15166-2-pierrick.bouvier@oss.qualcomm.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20261029000853.15166-1-pierrick.bouvier@oss.qualcomm.com> References: <20261029000853.15166-1-pierrick.bouvier@oss.qualcomm.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Proofpoint-GUID: rnnAXZLSXJKBKWhHM2efP_FWQh230BWA X-Proofpoint-Spam-Info: AW1haW4tMjYxMDI5MDAwMCBTYWx0ZWRfXyq198zT73/5A 247E6qUNUXwMmpnsgYU2wGzVgvAdyYXFHZj192uhbIMVP8eekXvMfuyaDlM9D3/fxZI1IqSZSTf UQsGRMM5DlIO/rMA3rfUcgbZApdA3b0= X-Authority-Analysis: v=2.4 cv=V+joQuni c=1 sm=1 tr=0 ts=6ae28e9c cx=c_pps a=rEQLjTOiSrHUhVqRoksmgQ==:117 a=9852oil1ID9t5xBSyQ/BEA==:17 a=IkcTkHD0fZMA:10 a=660iZSQnnn4A:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=yOCtJkima9RkubShWh1s:22 a=p0WdMEafAAAA:8 a=EUspDBNiAAAA:8 a=DfNHnWVPAAAA:8 a=IH4dkz8bHYACMdZ4P1YA:9 a=3ZKOabzyN94A:10 a=QEXdDO2ut3YA:10 a=2VI0MkxyNR6bbpdq8BZq:22 a=rjTVMONInIDnV1a_A2c_:22 X-Proofpoint-ORIG-GUID: rnnAXZLSXJKBKWhHM2efP_FWQh230BWA X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYxMDI5MDAwMCBTYWx0ZWRfX1hcAVfoY4Uu8 02yh/30NR/nw1oYrDeUIk5BWPEPsHDm/HeFiQVmm4cicbSxtcUKU/1glM40OX/tfOvd9C9+Br/X CbN3hOxuFEemC3UBXd4heviYPfXChcJMkIwOvfOOCuZc5hR3Bt8V5UA3UV+BsN5eURJ1Ye4IEIB VqPqGg8NiGY+bhzacZzC45mM9nAfqliuprcDzgz4GvaL6C/SEqUiix+mxTMq6RUiAh/Mu6VouAD CgVoXkhhgsLl4XygKNda4ucOlQXNiGQtqHr1tICtJzdOqnt6tWojFv8ZyfSyji9Wa0w/PyF9gW+ li08/pRx90rie+QsuY/y8RQFK2U81pCQib54aw0V4SgDqJnUedgDQuQ5oLIBPaSgk/oShesnAP7 WdBbXA4E96w9pD2Yc5uCtRKBjDCf6X/IvgME/mVxERJthh9HbQQGEsNAEJjY0qP5SX8FMewXwiB j5B36w7FoKrVSNki76Q== X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1176,Hydra:6.1.138,FMLib:17.12.100.49 definitions=2026-10-28_07,2026-10-21_02,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 lowpriorityscore=0 malwarescore=0 suspectscore=0 clxscore=1015 bulkscore=0 phishscore=0 impostorscore=0 priorityscore=1501 spamscore=0 adultscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2610190000 definitions=main-2610290000 Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists1p.gnu.org; Received-SPF: pass client-ip=205.220.168.131; envelope-from=pierrick.bouvier@oss.qualcomm.com; helo=mx0a-0031df01.pphosted.com X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, KHOP_DYNAMIC=0.001, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: qemu development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @qualcomm.com) X-ZM-MESSAGEID: 1793232581687154100 This new dockerfile allows to build a distroless image containing only qemu stripped release binaries, their lib dependencies, and installed artifacts (roms, keymap, ...). There is no shell, no python, nothing else. This is achieved thanks to a multi-stage build, where we add qemu binaries, artifacts and libraries in a new scratch image. Image has the minimal size possible. This is based on Ubuntu, which has the advantage to have working containers available down to 14.04. Debian old old stable have broken apt sources for instance. This unique dockerfile works for all qemu versions >=3D 3.1.0 (2018). We could build down to v0.12.0, but it would require more tweaks in the dockerfile, so we keep it simple instead. To build the image, you need to provide a qemu and ubuntu version: $ podman build -f release.Dockerfile --build-arg QEMU_VERSION=3Dv11.1.0 --b= uild-arg UBUNTU_VERSION=3D24.04 -t qemu/v11.1.0 To run it, as there is no shell, and no defined entrypoint, you need to choose the binary you want explicitely: $ podman run -it --rm qemu/v11.1.0 qemu-system-aarch64 --version Reviewed-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Fabiano Rosas Signed-off-by: Pierrick Bouvier --- tests/docker/dockerfiles/release.docker | 48 +++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 tests/docker/dockerfiles/release.docker diff --git a/tests/docker/dockerfiles/release.docker b/tests/docker/dockerf= iles/release.docker new file mode 100644 index 00000000000..ca6babde01e --- /dev/null +++ b/tests/docker/dockerfiles/release.docker @@ -0,0 +1,48 @@ +ARG UBUNTU_VERSION=3D"UBUNTU_VERSION_build_arg_must_be_set" + +FROM ubuntu:$UBUNTU_VERSION AS build + +# add deb-src for apt build-dep +RUN sed -e 's/Types: deb/Types: deb deb-src/' -i /etc/apt/sources.list.d/*= || true +RUN sed -e 's/# deb-src/deb-src/' -i /etc/apt/sources.list +# archive.canonical.com is not reachable anymore, and cause a long timeout +RUN sed -e '/archive.canonical.com/d' -i /etc/apt/sources.list + +# build dependencies +RUN apt update && \ +env DEBIAN_FRONTEND=3Dnoninteractive apt install -y git build-essential fl= ex bison +RUN apt update && \ +env DEBIAN_FRONTEND=3Dnoninteractive apt build-dep -y --arch-only qemu + +ARG QEMU_VERSION +RUN echo "QEMU_VERSION=3D${QEMU_VERSION:?QEMU_VERSION build arg must be se= t}" +ARG QEMU_REPO=3D"https://gitlab.com/qemu-project/qemu.git" + +RUN cd /tmp && \ +mkdir qemu && cd qemu && git init && \ +git remote add origin "${QEMU_REPO}" && \ +git fetch origin "${QEMU_VERSION}" --depth 1 && \ +git checkout FETCH_HEAD && \ +./configure --prefix=3D/opt/qemu --disable-docs --disable-werror && \ +make install -j $(nproc) && \ +strip /opt/qemu/bin/* && \ +rm -rf /tmp/* + +# retrieve runtime dependencies (libs) +RUN ldd /opt/qemu/bin/* | grep '=3D>' | sed -e 's/.*=3D>//' -e 's/(.*//' |= sort -u > /opt/qemu/libs +# store them in /deps/lib +RUN mkdir -p /deps/lib && cp --preserve --dereference $(cat /opt/qemu/libs= ) /deps/lib +# copy loader (with its original path) +RUN cp --preserve --parents --dereference /lib*/ld-linux* /deps/ + +##########################################################################= ###### +FROM scratch + +COPY --from=3Dbuild /deps / +# copy qemu and all associated artifacts (roms, ...) +COPY --from=3Dbuild /opt/qemu /usr + +# build with: +# podman build -f release.docker --build-arg QEMU_VERSION=3Dv11.1.0 --buil= d-arg UBUNTU_VERSION=3D24.04 -t qemu/v11.1.0 +# run with: +# podman run -it --rm qemu/v11.1.0 qemu-system-aarch64 --version --=20 2.43.0 From nobody Mon Nov 23 04:18:40 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=oss.qualcomm.com ARC-Seal: i=1; a=rsa-sha256; t=1793232579; cv=none; d=zohomail.com; s=zohoarc; b=KOaIfa6sTCs16Qsdidp3f1L/av4Zuu3p6OU9JlprdLVUZLsdunV3E62He6EDGAZxgSscYAy8pXpQGdFeDF0bQEBnKN417SsZrb2eR3OsKdUZsndp3p3lCpUjCRqE+xakD1UPxyM2OxRUlEAps1HIEuxCxBjAQL/VM/R48upgfYI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1793232579; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=lQcOz/ELA/sLti/t7VIWZNE7juScjTeknU2VKG6UgK4=; b=OOGhyUQQC5cvqmnRlONFoa2eqH1EhaXbQSjjrEbIrWQ/i4tTF6yDra16CAvt/rryeSF4qZvGb25ynM15nr0uD6w1aeFj3u4bs9+QrdnvshicKnYB6zGsK45MFzDKGqE2iLPVaPwXv/byP4WapAgDAyx02QmXn7lM506m9wbMVRg= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1793232579783337.7690552190653; Wed, 28 Oct 2026 17:09:39 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1xMDhb-0001kt-Ri; Wed, 28 Oct 2026 20:09:07 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xMDhZ-0001kR-Sj for qemu-devel@nongnu.org; Wed, 28 Oct 2026 20:09:06 -0400 Received: from mx0a-0031df01.pphosted.com ([205.220.168.131]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xMDhW-0000EU-Mx for qemu-devel@nongnu.org; Wed, 28 Oct 2026 20:09:05 -0400 Received: from pps.filterd (m0279866.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 69SM9u3I1512875 for ; Thu, 29 Oct 2026 00:09:01 GMT Received: from mail-pg1-f198.google.com (mail-pg1-f198.google.com [209.85.215.198]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4hknb29f85-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Thu, 29 Oct 2026 00:09:00 +0000 (GMT) Received: by mail-pg1-f198.google.com with SMTP id 41be03b00d2f7-cc4ac5feaa4so978489a12.1 for ; Wed, 28 Oct 2026 17:09:00 -0700 (PDT) Received: from pc.taild8403c.ts.net (192-80-163-190.dyn.novuscom.net. [192.80.163.190]) by smtp.gmail.com with ESMTPSA id 41be03b00d2f7-cd8ccc682d8sm4644744a12.18.2026.10.28.17.08.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Oct 2026 17:08:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= lQcOz/ELA/sLti/t7VIWZNE7juScjTeknU2VKG6UgK4=; b=RF6fppYMEWLMeePC A4KbBKrkklOQZF0GJlILSO9kF3Ty1WESS0vKG9ZuTVMvrEj/rif1sceFekTrnSF7 m5H4cXAZj2ly8H4bQcy2l+Aj1cn7hMsjGwEQPiSRx77R44aRqf+ZPerVnjMVJ4o+ TyEbshkkyD06tozT4Dbdv5wzXgTxwPM8jOXKLK8f+2PBuiouAtlHq6Xs+v7/1QzK pRwR1xNJKfuCNIEWxlq9Wo3wetIFfpbjm4L4gGZAoMT1bFxqNvDVJKxV2uKoCgeX 7Fl0AnElkfZA9uKAHUtOGCOfgz3yC5A9CtDJj+LazKFNBp6BnbasJQ/CalCvBt1n 4xA/fg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1793232540; x=1793837340; darn=nongnu.org; h=content-transfer-encoding:content-type:mime-version:references :in-reply-to:message-id:date:subject:cc:to:from:from:to:cc:subject :date:message-id:reply-to:content-type; bh=lQcOz/ELA/sLti/t7VIWZNE7juScjTeknU2VKG6UgK4=; b=cDWBzVkCd3EcZk8YMpBNRwKRokrfhNziIWBodKFrLrUgrBsRrlGPOYhH3TEUTQrPqI NWRyRBQuDlAFn8Ivo9dng9sv4vvJ31MFPovjiT9vQWfu3iYhzjpQ6ZJnbIN0U6cH2LLr 4KHgkNcxJvMAu3LT/fAs8S/mUtezEmtvME+zVV4VnRFjCPsXH7h7O2FCOyFAtXWMPzfO qFNs+X6H3LIncyHZUIXMrC97p4CQt4L7zdUpMUaPzRG476DZ+ywW2kKR8vTduPt7I8F2 LPJFbOvm77SmsDaYRhOHIJMNnVbIusDoaoUWZzUM5Ll5964kE/6Ixph/AerNfQBX7b0a iuMg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1793232540; x=1793837340; h=content-transfer-encoding:content-type:mime-version:references :in-reply-to:message-id:date:subject:cc:to:from:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to :content-type; bh=lQcOz/ELA/sLti/t7VIWZNE7juScjTeknU2VKG6UgK4=; b=aFVJZmRrFI66j5nFkaIxKSyrSC6Sw1qCTE55kHM6rWcV3xBDVU2OfY8cEIDaPh2nGs CPdgQOAmKr6JJIC00IGegiyp+0dopSoAhetCHU0ay5rOUfYud2oxGOkJ13Z4wWNWSQyg tp3hNuE/9elxn3FouSN6+Ww6xvv/MJmQwr2y+xd7cKFQzENfU0el7Rqabl0jfhnvtHfo mnkMkbOlznfSVOWE2Ea5xi64AdIlXcLIdEdXLz3+ye+nT3klKGc+153GaTh/s3z8xCpc 28Lv7nZNgvG8yB4p94pzLkb8Z6klYmNXmvchzg6AvjpskGowF1OW7vDwqCa0iRQa1ICK 59vQ== X-Gm-Message-State: AFq9FYJle6aQnghIIyexNrFhxfQXONFWV8JbOhlwQfqOcBiSms+bWmib xzNi5sbsy3hWg2ue0KuIJ0mCeyXRY3/sF+IQhm1dtItR5EjOj5N5n9tOUTmir9fc4jR9MWA+8RZ /gmXRCTD6uh5+huGu+YvLKdIGuZ2Z2aVHIJi1ggNqrVAxSTJdLbrSTRTT/rLoFOHxRA== X-Gm-Gg: AYBFou30KA0X5NWUzNcOkhqiiPgjDAKND9mKoLjodA1cow2cv9HkEz370cSqJzqdOxN CnS5RcIrXcBaoZVKnCz9nymvQnbqDzojPimfBwgpam4sC+kBldqJIQ8NSz0blFpEso3wppyB1H0 MGIswaO7j4jNFsZU+gQNXc9BRmv5/iLjJoXDQILHS5AtqFTWFQJw2r0NA7TyaepRKyo7rWHWGEK 2pP7hgQrt1IiyjMyk4S6oXPzbusCv2UqUfDRKcGAuPi7g4iA6f8S6ov5Yjwc49LAryaBJ98MWMX uU7G+jNbVFgUyW2I0mQErvN4cZZYDJHLxjSxgcetjGb8MhIIDFH/jh2lsZoUVSFKDOgpgJ3ii8u km08cQf0WHLnsTQ6Fpxeb/xCCP27nRsd2+hZo7XlnFV3a+ejcfxpFYZmooEjHLMjv1/VcI+lnl2 rl8LIcPcewMzTbdbyQsMsKdcrkGZUOhD+mZaEX X-Received: by 2002:a05:6a20:2445:b0:3de:7bd5:fb47 with SMTP id adf61e73a8af0-3e9023a4ad3mr3261607637.39.1793232540321; Wed, 28 Oct 2026 17:09:00 -0700 (PDT) X-Received: by 2002:a05:6a20:2445:b0:3de:7bd5:fb47 with SMTP id adf61e73a8af0-3e9023a4ad3mr3261587637.39.1793232539897; Wed, 28 Oct 2026 17:08:59 -0700 (PDT) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: =?UTF-8?q?Alex=20Benn=C3=A9e?= , peterx@redhat.com, Fabiano Rosas , mjt@tls.msk.ru, =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Pierrick Bouvier Subject: [PATCH v5 2/2] scripts: add build_release_container.sh Date: Thu, 29 Oct 2026 00:08:53 +0000 Message-ID: <20261029000853.15166-3-pierrick.bouvier@oss.qualcomm.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20261029000853.15166-1-pierrick.bouvier@oss.qualcomm.com> References: <20261029000853.15166-1-pierrick.bouvier@oss.qualcomm.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Authority-Analysis: v=2.4 cv=Yu2a1IYX c=1 sm=1 tr=0 ts=6ae28e9d cx=c_pps a=Qgeoaf8Lrialg5Z894R3/Q==:117 a=9852oil1ID9t5xBSyQ/BEA==:17 a=IkcTkHD0fZMA:10 a=660iZSQnnn4A:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=YMgV9FUhrdKAYTUUvYB2:22 a=p0WdMEafAAAA:8 a=EUspDBNiAAAA:8 a=Ab9DfM9NdPcTtTRkZkQA:9 a=3ZKOabzyN94A:10 a=QEXdDO2ut3YA:10 a=x9snwWr2DeNwDh03kgHS:22 X-Proofpoint-ORIG-GUID: AeFwP0wEB2e_sR-Q5hKE5NMhiv7w29Zu X-Proofpoint-Spam-Info: AW1haW4tMjYxMDI5MDAwMCBTYWx0ZWRfX5W2ewomRVxTd sb42Do1m330pXzULOZhFkrmyhPhr2duOCgXGZCfK1U+sShkidf5vtLwsNEvu+VQyOJhimZiAVY/ lXrb5EDISIS/by4Fzu/+EsmLzG1M8pk= X-Proofpoint-GUID: AeFwP0wEB2e_sR-Q5hKE5NMhiv7w29Zu X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYxMDI5MDAwMCBTYWx0ZWRfX5vBpXxjSBGB3 lwTd7X1Nd28s4MQ0NqewzV3EcCHs9peoHHUHHcPnHXTtPVaJWpaigpxA9+U8n9EuJOEjGCKfkAM 9RKcf7TunIhK3spjFOs0t+yOh7RuuxRvnsbUH4Y4qDMF+YzuXXRAu31GbsGGkOxmO+SLSXjIfxU StAsUWiGQ41skDhicgpREho6BCpHzGYTGc9Nftcw2whYmGnpsNqoxGBFx1Dnbeotd3p9huQ6c01 lzGcPXKGEd/9T5cbUJRsgJx7sbc4BKEWtTc0Am7o3MRhmqfZJxamkSSh5Go6v2uUa28/qLsr0HP cYhKnJHFiSCb2Q3DoazlBnzOMU83dFx6P3BztaTE8DQNs7RSiUeCIuoh4HoKCNnZStz1vTYtr+j ZpEFff7sEaedD3dzn1IVlhg9YQ9VPlZ6QK+Bh6TeCqUQMm7pDsXijQV5jxWvEjwt5lCsdK7SfTv QhNlJhlloLr98jCKoiw== X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1176,Hydra:6.1.138,FMLib:17.12.100.49 definitions=2026-10-28_07,2026-10-21_02,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=0 malwarescore=0 bulkscore=0 clxscore=1015 priorityscore=1501 lowpriorityscore=0 phishscore=0 impostorscore=0 adultscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2610190000 definitions=main-2610290000 Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists1p.gnu.org; Received-SPF: pass client-ip=205.220.168.131; envelope-from=pierrick.bouvier@oss.qualcomm.com; helo=mx0a-0031df01.pphosted.com X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, KHOP_DYNAMIC=0.001, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: qemu development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @qualcomm.com) X-ZM-MESSAGEID: 1793232581398158500 This script allows to easily build a qemu release container, based on dockerfile introduced in previous commit. It names image "qemu/$version" and automatically detects which ubuntu version should be used to build it. $ ./scripts/build_release_container.sh v3.1.0 $ podman run -it --rm qemu/v3.1.0 qemu-system-arm --version QEMU emulator version 3.1.0 (-dirty) Copyright (c) 2003-2018 Fabrice Bellard and the QEMU Project developers Reviewed-by: Philippe Mathieu-Daud=C3=A9 Signed-off-by: Pierrick Bouvier Reviewed-by: Fabiano Rosas --- scripts/build_release_container.sh | 63 ++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100755 scripts/build_release_container.sh diff --git a/scripts/build_release_container.sh b/scripts/build_release_con= tainer.sh new file mode 100755 index 00000000000..7dd477deea8 --- /dev/null +++ b/scripts/build_release_container.sh @@ -0,0 +1,63 @@ +#!/usr/bin/env bash +# SPDX-License-Identifier: GPL-2.0-or-later + +set -euo pipefail + +script_dir=3D$(dirname $(readlink -f $0)) + +# The oldest buildable release we support is v3.1.0, as previous ones requ= ire +# additional tweaks in Dockerfile. +# For building previous releases (down to v0.12.0), +# see: 20261014005338.34657-1-pierrick.bouvier@oss.qualcomm.com +oldest_release=3Dv3.1.0 + +if [ $# -lt 1 ] || [ $# -gt 2 ]; then + echo "usage: version [git_repo]" + echo + echo "- version: tag or sha-1 (>=3D v3.1.0)" + echo "- git_repo: (optional) QEMU repository URL" + exit 1 +fi +version=3D$1;shift + +git_repo=3D"https://gitlab.com/qemu-project/qemu.git" +if [ $# -eq 1 ]; then + git_repo=3D$1;shift +fi + +year=3D$(date +%Y) +month=3D$(date +%m) +if git rev-parse $version >& /dev/null; then + year=3D$(git log -1 --format=3D'%cd' --date=3D'format:%Y' $version) + month=3D$(git log -1 --format=3D'%cd' --date=3D'format:%m' $version) +fi + +# Ubuntu LTS are published every (even) two years in April. +ubuntu=3D +if [ $((year % 2)) -eq 1 ]; then + # pick latest LTS from previous year + ubuntu=3D$((year - 1)) +elif [ $month -gt 6 ]; then + # LTS published this year should work + ubuntu=3D$year +else + # pick latest LTS from two years ago + ubuntu=3D$((year - 2)) +fi +if [ $ubuntu -lt 2014 ]; then + # oldest ubuntu release available with containers is 14.04 + ubuntu=3D2014 +fi +ubuntu=3D$((ubuntu - 2000)) +ubuntu_version=3D$ubuntu.04 + +dockerfile=3D$script_dir/../tests/docker/dockerfiles/release.docker +docker=3D$($script_dir/../tests/docker/docker.py probe) + +set -x +$docker build . \ + -f $dockerfile \ + --build-arg QEMU_VERSION=3D$version \ + --build-arg UBUNTU_VERSION=3D$ubuntu_version \ + --build-arg QEMU_REPO=3D"$git_repo" \ + -t qemu/$version --=20 2.43.0