From patchwork Tue Jul 21 04:31:10 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Deepesh Varatharajan X-Patchwork-Id: 93009 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 92512C44532 for ; Tue, 21 Jul 2026 04:31:48 +0000 (UTC) Received: from mx0b-0064b401.pphosted.com (mx0b-0064b401.pphosted.com [205.220.178.238]) by mx.groups.io with SMTP id smtpd.msgproc01-g2.15615.1784608305889441671 for ; Mon, 20 Jul 2026 21:31:46 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@windriver.com header.s=PPS06212021 header.b=h/Hz6OHG; spf=permerror, err=parse error for token &{10 18 %{ir}.%{v}.%{d}.spf.has.pphosted.com}: invalid domain name (domain: windriver.com, ip: 205.220.178.238, mailfrom: prvs=1662381085=deepesh.varatharajan@windriver.com) Received: from pps.filterd (m0250812.ppops.net [127.0.0.1]) by mx0a-0064b401.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 66L25nno1402197 for ; Tue, 21 Jul 2026 04:31:45 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=windriver.com; h=cc:content-transfer-encoding:content-type:date:from :message-id:mime-version:subject:to; s=PPS06212021; bh=CGHBc6KlL NZGIZLhU2FYl8XVcpCxwrtkgF/h7eGWswk=; b=h/Hz6OHGBMq6d4nNqx+geH7FK 6oHc6xm9IH7Mw+hwATTpneQnVSmy7O6VGOZ4du9DbyWxILpsD8zwvhtP47YN/hP4 fIkKETlu4/qx8xZtxY3QvzQRfw2/cE/OOcdP4q1xNB4SSj5N3fkrlegJyvpPVfV8 xhb7MbDkx/fQY3cRAjVJ2i5mbgUts8qCWKhLMerIrWNQas58xVgeFjDTmZkBog86 i+bCHvvStI19MTt2FuDScgO7d72u4UbnSHChbUvkGmNA5kjYSGTmgqb4Af4PvK7t gOw16lRbS0yJSUsMKN89pnnca4Sw6ScVCxLKuFbpJf21TgS8Le5gUex0urtTQ== Received: from ch5pr02cu005.outbound.protection.outlook.com (mail-northcentralusazon11012015.outbound.protection.outlook.com [40.107.200.15]) by mx0a-0064b401.pphosted.com (PPS) with ESMTPS id 4fg0f5c694-1 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT) for ; Tue, 21 Jul 2026 04:31:44 +0000 (GMT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=gnkseMcxGZ8F7s42XmyN4SI30nbd0dyknn/I/XdH2Z3IH9/EOZJq8htCrAuugtqQu4+dmLkXvk6IL1IrjOYIm4Bc+YZdgX0PkJyGohONmuve9kGRzLyiiKXErgdTKxckkWMHDsO6LU2zXOmmd6W1Os/us7lPVdnOXKaaF2Q2zIKNGA5r/ivEHXRcB/yop6oA0s72rZ1q28AUoAazJ6ICiLYs5mflRAxJ4x273ktdLQj/2YfOCAeGKAzFDRPuQlXmZnGDflpRsi90E4XwIUkxIPNPYvpGXNhICdhllFiO/D+Oz6fYGzWDS6Xo58B7AlbDPiIvAE6LKPGwqSfggj4u+w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=CGHBc6KlLNZGIZLhU2FYl8XVcpCxwrtkgF/h7eGWswk=; b=tFvdNHhSO4eG7OWyJ6uCqYS5MU+1/hz9jjWmy09e3PkDkJ4P4fxAoy1B3BZuL7drYwqFbkF53JrgSPeaDyKydK1cb+KszUf6lWd9tFx5SVBp9TMAT2cvxAppLmK3H4w7s4FlTQ4UGpbDSsOVVzx4VBRv0PDnYJLYPP+WtWvGptt67Nbq6vh2P390j+I871YKGEV9xzDfwHwsn+jdG2NO3sF+v6njhk2LhhZk9GArTo2XhIWYtQwvws3mJzzfYYYdT06X9OPrLzgbLEAACzfGRa//rYlkWv7oAip11vJhFlWxwbqzXJiWzRzo7/Ljb6XQDDtudAJDwIlRcsJ7XxBBlw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=windriver.com; dmarc=pass action=none header.from=windriver.com; dkim=pass header.d=windriver.com; arc=none Received: from SN7PR11MB6677.namprd11.prod.outlook.com (2603:10b6:806:26b::6) by DSVPR11MB445312.namprd11.prod.outlook.com (2603:10b6:8:37a::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.223.18; Tue, 21 Jul 2026 04:31:42 +0000 Received: from SN7PR11MB6677.namprd11.prod.outlook.com ([fe80::490a:519b:d657:99ab]) by SN7PR11MB6677.namprd11.prod.outlook.com ([fe80::490a:519b:d657:99ab%4]) with mapi id 15.21.0223.017; Tue, 21 Jul 2026 04:31:41 +0000 From: Deepesh.Varatharajan@windriver.com To: openembedded-core@lists.openembedded.org Cc: randy.macleod@windriver.com, Sundeep.Kokkonda@windriver.com, Deepesh.Varatharajan@windriver.com Subject: [PATCH 1/3] rust: Fix reproducibility with shared source trees Date: Mon, 20 Jul 2026 21:31:10 -0700 Message-ID: <20260721043124.3538696-1-Deepesh.Varatharajan@windriver.com> X-Mailer: git-send-email 2.49.0 X-ClientProxiedBy: SJ0PR13CA0099.namprd13.prod.outlook.com (2603:10b6:a03:2c5::14) To SN7PR11MB6677.namprd11.prod.outlook.com (2603:10b6:806:26b::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SN7PR11MB6677:EE_|DSVPR11MB445312:EE_ X-MS-Office365-Filtering-Correlation-Id: 69e796a6-da4c-47a6-505d-08dee6e0f694 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|52116014|376014|23010399003|1800799024|366016|38350700014|6133799003|12006099003|56012099006|11063799006|10067099003|18002099003; X-Microsoft-Antispam-Message-Info: ycpwiHo1Am5I6p2qlVReDxqZ2MoS68wx6wsqz0+3WT58JUC/nP6jVrzdmi0zLzEbomlk6AvkjZu4DcEIzu2Hn0D3b+ZNwr2H1orwEwiLdOJ2vALbzijRg0VlB7JEI4+rCOoxDAKyvzTQldVhH7mIjbe0dUPL1fUUPvcXC313Bbqrafs3d5gXnAr69CWc/LR78ivn5quzgQmamm0XaeCr5EwtjOv+HYNedDdkBMAOjCtfKuotlN4hX4TBhZxBKUBryr5bnBBm5Cmm0AfE/lYYGD3QFC2o4ZFA41/j6hRhEl77xe/MdkuPhfis8M4lmvZpLHMMF0ML3yEyFwTQL0I+h9sv9fE8T8iigUkkBy2qtN20X4xwocOVKl0H8/wn7oc5SRiR+OeEjXbX7v9jJRy1xKuSiXNO+qwDiRbxrurkw5uHmCzWm56z4ZnoguhzeTGm/MVkcQYylVFi4FFYYQXX2aw9fWfTO10TqMvWTyk7Y4J2YFECbfhPVfBPslOEpvMGCTRldCw8NR9rWiF+R9qIjUYxkFS2mKvRlRpvLE7XPNghgWlds+PvSHUTucemumuEgUjMAO/vFt19a5e8tJ/hGZR3/tKF8JOJ4YzXwNXLlBHllvrbt/uNTLBfIZRSogtDeSOeX0j2dYQdtLGIgAatNCLNEg/OU51s8aLYG0DYD7U= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SN7PR11MB6677.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(52116014)(376014)(23010399003)(1800799024)(366016)(38350700014)(6133799003)(12006099003)(56012099006)(11063799006)(10067099003)(18002099003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 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Tp92g== X-OriginatorOrg: windriver.com X-MS-Exchange-CrossTenant-Network-Message-Id: 69e796a6-da4c-47a6-505d-08dee6e0f694 X-MS-Exchange-CrossTenant-AuthSource: SN7PR11MB6677.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 21 Jul 2026 04:31:41.8919 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 8ddb2873-a1ad-4a18-ae4e-4644631433be X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: Q4hUVeI7EMClrkhYSLT7trrR5cI4mUVFH/AH3RuNYPBHlsqh+7QSZtmw3Y7x9deL5C2KFgMAWtWkA+TVWu6NsOkir6sWLDZQkgMxyghqfaAu/08fVPFjRzmeRwwhae4u X-MS-Exchange-Transport-CrossTenantHeadersStamped: DSVPR11MB445312 X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwNzIxMDA0MyBTYWx0ZWRfX6OW096qMHcOJ /0/O0rX1OJl8l0V3/BoQBcAUKCW52IbE3knYsvXkec/HQLJ78TTuhtlaWAvUsbZok7b/rc1qKv2 kmJCW2WxA/pl6Ptj+M7/F6/v2zgyVxv4YsV1UFS+t8Y3B4yMD8M1WqSOprcFErj5U9iBdCSr0EO m5V8D7l2IHpZjtfA7hNvuW/UBGwgh1Hnrmix79JM9jZc7EoHk012gbEeZXv3tWGwuo0C6c9OhNR LXHxKXH6rVuw4bO47K0zXT1ssCjx6mIttG3xI8NIuj0QITxLLYrj8FZyu8ScQcliCyQVd+8JJKb 19tYJ4IutEqdOEr60+vHalwbYJZGJFMh3WPcRWwwrQpjsBtklj50uI7xx9eI2TvFFHCIeFayPi+ 7lRsWC86GnBqLrnBrT8cfp7cpmTdLF7+gHhmXqQqwB9cd2qltMa8PF0IcHRZH6IZgdgKb92YmH1 9Dj3c0gLpquhQ6anB0Q== X-Proofpoint-GUID: qS6lw4SRh44KvwrMbVSLG-4vmr_UrCih X-Proofpoint-ORIG-GUID: qS6lw4SRh44KvwrMbVSLG-4vmr_UrCih X-Authority-Analysis: v=2.4 cv=IM0yzAvG c=1 sm=1 tr=0 ts=6a5ef630 cx=c_pps a=CD2IJdD5qp8L8UJuiUkm2w==:117 a=6eWqkTHjU83fiwn7nKZWdM+Sl24=:19 a=z/mQ4Ysz8XfWz/Q5cLBRGdckG28=:19 a=lCpzRmAYbLLaTzLvsPZ7Mbvzbb8=:19 a=xqWC_Br6kY4A:10 a=RAioF0-LDSMA:10 a=VkNPw1HP01LnGYTKEx00:22 a=bi6dqmuHe4P4UrxVR6um:22 a=fTW__CHxibyLmBMfj2wP:22 a=NEAV23lmAAAA:8 a=ei4SEBeUAAAA:8 a=t7CeM3EgAAAA:8 a=XTdeb_U8USiAPbms4-gA:9 a=8zIOOLb7Ym0NljyPXbuS:22 a=FdTzh2GWekK77mhwV6Dw:22 X-Proofpoint-Spam-Info: AW1haW4tMjYwNzIxMDA0MyBTYWx0ZWRfX/N38l2pNnMsJ tS9PFrRjWkiA4ZjkfN+JQyDHxusinGKx3d6Eb9uFXeX5c6UCiTAzpFI5OlT8iGRgSviKrrx95Qb MDhv4gNMUjHIZ0rvN7ijglDBi/2izbISUrhg7W9E7CceiEzIOe54 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1143,Hydra:6.1.134,FMLib:17.12.100.49 definitions=2026-07-20_06,2026-07-20_03,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 lowpriorityscore=0 spamscore=0 clxscore=1015 adultscore=0 phishscore=0 priorityscore=1501 impostorscore=0 malwarescore=0 bulkscore=0 suspectscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2606150000 definitions=main-2607210043 List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Tue, 21 Jul 2026 04:31:48 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/241496 From: Deepesh Varatharajan Backport an upstream Rust commit to fix a reproducibility issue when Rust family recipes share the same source tree. Signed-off-by: Deepesh Varatharajan --- ...ild-script-path-leakage-in-artifacts.patch | 28 +++++++++++++++++++ meta/recipes-devtools/rust/rust-source.inc | 1 + 2 files changed, 29 insertions(+) create mode 100644 meta/recipes-devtools/rust/files/0005-remap-OUT_DIR-paths-to-fix-build-script-path-leakage-in-artifacts.patch diff --git a/meta/recipes-devtools/rust/files/0005-remap-OUT_DIR-paths-to-fix-build-script-path-leakage-in-artifacts.patch b/meta/recipes-devtools/rust/files/0005-remap-OUT_DIR-paths-to-fix-build-script-path-leakage-in-artifacts.patch new file mode 100644 index 0000000000..8c93624df7 --- /dev/null +++ b/meta/recipes-devtools/rust/files/0005-remap-OUT_DIR-paths-to-fix-build-script-path-leakage-in-artifacts.patch @@ -0,0 +1,28 @@ +Backport a commit that remap OUT_DIR paths to fix build script path leakage in artifacts + +Upstream-Status: Backport [https://github.com/rust-lang/rust/commit/e743a4db62336027dcc1f1a755f4ca35f56b67df] + +Signed-off-by: Deepesh Varatharajan + +diff --git a/src/bootstrap/src/core/builder/cargo.rs b/src/bootstrap/src/core/builder/cargo.rs +index f785254..0264667 100644 +--- a/src/bootstrap/src/core/builder/cargo.rs ++++ b/src/bootstrap/src/core/builder/cargo.rs +@@ -1077,6 +1077,8 @@ impl Builder<'_> { + // rustc creates absolute paths (in part bc of the `rust-src` unremap + // and for working directory) so let's remap the build directory as well. + format!("{}={map_to}", self.build.src.display()), ++ // remap OUT_DIR so they don't leak into artifacts. ++ format!("{}={map_to}/out", self.build.out.display()), + ] + .join("\t"); + cargo.env("RUSTC_DEBUGINFO_MAP", map); +@@ -1097,6 +1099,8 @@ impl Builder<'_> { + // rustc creates absolute paths (in part bc of the `rust-src` unremap + // and for working directory) so let's remap the build directory as well. + format!("{}={map_to}", self.build.src.display()), ++ // remap OUT_DIR so they don't leak into artifacts. ++ format!("{}={map_to}/out", self.build.out.display()), + ] + .join("\t"); + cargo.env("RUSTC_DEBUGINFO_MAP", map); diff --git a/meta/recipes-devtools/rust/rust-source.inc b/meta/recipes-devtools/rust/rust-source.inc index a8d8de7165..5678e00671 100644 --- a/meta/recipes-devtools/rust/rust-source.inc +++ b/meta/recipes-devtools/rust/rust-source.inc @@ -9,6 +9,7 @@ SRC_URI += "https://static.rust-lang.org/dist/rustc-${RUST_VERSION}-src.tar.xz;n file://0002-Fix-rust-build-failure-with-unstable-options.patch;patchdir=${RUSTSRC} \ file://0003-explicit-tail-calls-disable-two-tests.patch;patchdir=${RUSTSRC} \ file://0004-explicit-tail-calls-ignore-tests-on-unsupported-llvm.patch;patchdir=${RUSTSRC} \ + file://0005-remap-OUT_DIR-paths-to-fix-build-script-path-leakage-in-artifacts.patch;patchdir=${RUSTSRC} \ " SRC_URI[rust.sha256sum] = "77a6ff3003a4ad0cb00697b043c879e3e1a15d945b1a1f63818903bfc3fa8b98" From patchwork Tue Jul 21 04:31:11 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Deepesh Varatharajan X-Patchwork-Id: 93010 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 912F9C44529 for ; Tue, 21 Jul 2026 04:31:48 +0000 (UTC) Received: from mx0a-0064b401.pphosted.com (mx0a-0064b401.pphosted.com [205.220.166.238]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.15637.1784608306694021345 for ; Mon, 20 Jul 2026 21:31:46 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="dkim: body hash did not verify" header.i=@windriver.com header.s=PPS06212021 header.b=IIie4EKt; spf=permerror, err=parse error for token &{10 18 %{ir}.%{v}.%{d}.spf.has.pphosted.com}: invalid domain name (domain: windriver.com, ip: 205.220.166.238, mailfrom: prvs=1662381085=deepesh.varatharajan@windriver.com) Received: from pps.filterd (m0250809.ppops.net [127.0.0.1]) by mx0a-0064b401.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 66L46B1r1635816 for ; Mon, 20 Jul 2026 21:31:46 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=windriver.com; h=cc:content-transfer-encoding:content-type:date:from :in-reply-to:message-id:mime-version:references:subject:to; s= PPS06212021; bh=Q1PQchsry7TqxfKAw092qGwn6B/m4k513lmPNJJrN8Q=; b= IIie4EKt3bvO3l6kFKTGVRvdNtTmnIeBory/p4eKtAvG7WzfKkGqzNf9R+LGUPxQ 0CTwMrTLK1DpmhdNTnupF3Xpkf+gkCC1onOvvGjvInSsbcKxyMUasMXYbQxYPPWI qgILCiNjAB1swocpOSthZvy3rm5+PugSw2ve2OSFlrx8/2WucCUfr5xtMYyyg3mi dHKckDSUC3DtLIz09TDAwjAftZOA0sAwYpVQJVJKXhY83Y+mvbIUzU8Qz6jIDvYr jGpTGr1Imwy/mI4JL0ABT9WdaU6CS3ViXWBkbaSJAF8DEZVO/oItzSCTI+VlEnJG Fv90N4n6BtVwIVLfBJDvgQ== Received: from ch5pr02cu005.outbound.protection.outlook.com (mail-northcentralusazon11012015.outbound.protection.outlook.com [40.107.200.15]) by mx0a-0064b401.pphosted.com (PPS) with ESMTPS id 4fg90cutfp-1 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT) for ; Mon, 20 Jul 2026 21:31:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=IgRed0xSTfaKzoWu+g4uhNOMnGvSH2q7aPagzeLUKicZCNALSQIJTD7ib8eyPLW45jB4b2/UqF0xrqPB/2zdaFbnxmi8L4YdLBX6jYJ3nbIGox7FPcLJG0WYi5+EgF2MfQJ0XKH8jzNkiazCXd6Z55XhkDDc5AcwEtO8UWkyrkBuqTEVk4QBuGUJXNmTZJcNdAO7yD77bt0MacBjTc7D3aUbaii0i4p97oV9916ZdbqQjB/FfznNBCbRoMPDQ9A9mN+H+g1sLNQvgV57S27LEQkRLYJlZ8xU7zmpEN5K1q8ZoKthTPBReQEgYy7NWlZcsQcL/i8Ruho3+O2lrV2trQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=Q1PQchsry7TqxfKAw092qGwn6B/m4k513lmPNJJrN8Q=; b=L2Gk8phchp7qzdpXdqI1oQk3h/W8OJVHjotwboZutdTHNjWwlMUJsksaFkAfZpqXIRKwe1iluPfKs1TkqlfzamDw34gzL1T+fxMxUZp1pixIBO9LbJQvaFK4yOo5ABmFntjCBNdT4aSKPg8tRyQ3kBV2mvEAnJ0Vw44c23IRemfXrMKk+AXae8xsOEYexVMpmnXb1rQQHazTbQiNiM0kpCm4UUEJvIjOAabU9sBvQqIwQFufAdozqKeesLUMWdTFi8WZz9BlJTAj48DL8xc4VPruLSMAy+iCOn8i8t46HbBBwK7Yl+mCYuWQbRiQD0/ZA8G/ggIVgoMzLDCjm4eyIQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=windriver.com; dmarc=pass action=none header.from=windriver.com; dkim=pass header.d=windriver.com; arc=none Received: from SN7PR11MB6677.namprd11.prod.outlook.com (2603:10b6:806:26b::6) by DSVPR11MB445312.namprd11.prod.outlook.com (2603:10b6:8:37a::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.223.18; Tue, 21 Jul 2026 04:31:44 +0000 Received: from SN7PR11MB6677.namprd11.prod.outlook.com ([fe80::490a:519b:d657:99ab]) by SN7PR11MB6677.namprd11.prod.outlook.com ([fe80::490a:519b:d657:99ab%4]) with mapi id 15.21.0223.017; Tue, 21 Jul 2026 04:31:44 +0000 From: Deepesh.Varatharajan@windriver.com To: openembedded-core@lists.openembedded.org Cc: randy.macleod@windriver.com, Sundeep.Kokkonda@windriver.com, Deepesh.Varatharajan@windriver.com Subject: [PATCH 2/3] rust: refactor source handling into a shared work-shared recipe Date: Mon, 20 Jul 2026 21:31:11 -0700 Message-ID: <20260721043124.3538696-2-Deepesh.Varatharajan@windriver.com> X-Mailer: git-send-email 2.49.0 In-Reply-To: <20260721043124.3538696-1-Deepesh.Varatharajan@windriver.com> References: <20260721043124.3538696-1-Deepesh.Varatharajan@windriver.com> X-ClientProxiedBy: SJ0PR13CA0099.namprd13.prod.outlook.com (2603:10b6:a03:2c5::14) To SN7PR11MB6677.namprd11.prod.outlook.com (2603:10b6:806:26b::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SN7PR11MB6677:EE_|DSVPR11MB445312:EE_ X-MS-Office365-Filtering-Correlation-Id: de5bad6c-3a53-4ccc-cdcf-08dee6e0f80b X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|52116014|376014|23010399003|1800799024|366016|13003099007|38350700014|29003799003|25016099003|6133799003|12006099003|56012099006|11063799006|5023799004|10067099003|22082099003|18002099003|3023799007; X-Microsoft-Antispam-Message-Info: 2qGmiQ/BitD54Gw3tuULfnorRdHkbVyr7arAsbNspzFYzOy7S8vAdGrIh83hKsZPGC/HfowyUfjQxbYmdVerfgGOnlktw98RjM3yeuL+jVYxMG+zt+MZNq0qWQeFv3gqsZrxYtOxgmEkFItsgTd+umkzrllVE0bF4l/GtmPay3kc0J3ZZnimUNkoeJ8GJfaqHb8aUPenLLUZHsj+2CFjaVx9so38mMUnyq4FSPzx0g8tSji37d8fy473dP7ajNvubAMiMQRH2PWbqTqMoOJ+gfZU2QlNklbbT5Z7DuGo8vRXQUGcrWyz317JDpSQTcAAO7ebZRyWkNEZqL4D7NMOWN0F9v8GW68sR623/hj90U6Z/wxr5XwwguWtxomzR5BG5SaPL+QlGVmpRWAuHHaG/WLUT1VHHTiTOgpRmmoB5ipjDWQpsnJICd60PzoLGX0/h7pib164kg26efHfJdMu68yzRJ/KmvGlqw5QvqQz09K4eY4EpFvI00eNg1+wCZKbxrGD3F7ydoVDfJrfSzwBE9MZfydZ9bG2wmT5LscEkI+s0Gy5OKRG1chtVsCDnB/J6TBcJIDk6yUwTUYYj9ZyhVnow9QMgV6y9jnrYJtCv98lmwnAaRSR234KK23++5wdr4gyE9LOnAqZZLhMt6+uKpFcbDlYX3spdQn118MAhco= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SN7PR11MB6677.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(52116014)(376014)(23010399003)(1800799024)(366016)(13003099007)(38350700014)(29003799003)(25016099003)(6133799003)(12006099003)(56012099006)(11063799006)(5023799004)(10067099003)(22082099003)(18002099003)(3023799007);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?d2TRn8368mSOVAuUZgi32Jv+tsQT?= =?utf-8?q?rxryAkUaAOu3lIir2M9QMJhKvUP1398F7p5efnWbi3Tqdcaq4PlX9Jd5tLuDi3Avk?= =?utf-8?q?5pLEK5yIEVJR/E0OwABdyK8yoivaS4lCHWupEUq2RqiWfECl0bMPsBN9gDbJEh/Cn?= =?utf-8?q?bCdhz5sLlH2yDQFQ6J/80hb48oQqfHoEfA+4NzNKNvTc1BoZlz9RQxi1q8P5QzaWT?= =?utf-8?q?mQUooKp9/esx2IujHz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zGva52JeHKybF6Pv6scuVkQ== X-OriginatorOrg: windriver.com X-MS-Exchange-CrossTenant-Network-Message-Id: de5bad6c-3a53-4ccc-cdcf-08dee6e0f80b X-MS-Exchange-CrossTenant-AuthSource: SN7PR11MB6677.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 21 Jul 2026 04:31:44.3373 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 8ddb2873-a1ad-4a18-ae4e-4644631433be X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: jXvOZ6/sl4BPXLNcIC8DY1BQ/JdFUvgYBuedPDGrPcsouqrwbPjahF0XWQy+psYzYPotqGSxltg9iYuk/vC3CS20hzz01R7suaXKBbZujrhy4KaX8kkDZYBHQQuzJZhC X-MS-Exchange-Transport-CrossTenantHeadersStamped: DSVPR11MB445312 X-Proofpoint-ORIG-GUID: E6YdjWugzT77yL4fxdB8qKmmWbWuKnyh X-Proofpoint-GUID: E6YdjWugzT77yL4fxdB8qKmmWbWuKnyh X-Authority-Analysis: v=2.4 cv=AOkSgtoa c=1 sm=1 tr=0 ts=6a5ef632 cx=c_pps a=CD2IJdD5qp8L8UJuiUkm2w==:117 a=6eWqkTHjU83fiwn7nKZWdM+Sl24=:19 a=z/mQ4Ysz8XfWz/Q5cLBRGdckG28=:19 a=lCpzRmAYbLLaTzLvsPZ7Mbvzbb8=:19 a=xqWC_Br6kY4A:10 a=IkcTkHD0fZMA:10 a=RAioF0-LDSMA:10 a=VkNPw1HP01LnGYTKEx00:22 a=bi6dqmuHe4P4UrxVR6um:22 a=iKiJcTA2PjBS6x5JeXcw:22 a=ei4SEBeUAAAA:8 a=t7CeM3EgAAAA:8 a=7CQSdrXTAAAA:8 a=iGHA9ds3AAAA:8 a=8wEic9LhAAAA:8 a=ag1SF4gXAAAA:8 a=Tr0CIQbrg0mKLZOxC6IA:9 a=5O9rwaaqg39D_ep3:21 a=3ZKOabzyN94A:10 a=QEXdDO2ut3YA:10 a=8zIOOLb7Ym0NljyPXbuS:22 a=FdTzh2GWekK77mhwV6Dw:22 a=a-qgeE7W1pNrGK8U0ZQC:22 a=nM-MV4yxpKKO9kiQg6Ot:22 a=M9VCcFR7d36vLOFuqMn8:22 a=Yupwre4RP9_Eg_Bd0iYG:22 X-Proofpoint-Spam-Info: AW1haW4tMjYwNzIxMDA0MyBTYWx0ZWRfXyCYK//DzmmRW yIUT+C4poJjdjVvXzg8qwjjj+Ou44C+nHz8Ptq1OpFWaEUsQNFIRGLtRctvD22FGZEOQQruFC7n 5DncIkeE7x1MaqfECdSRwKE1fAoMGlhUBiXKqL2Y/dvk8mhPdwCR X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwNzIxMDA0MyBTYWx0ZWRfXz8ZV33W9JCgG eJl5m97a/0/VLsJiE1g1GzK+iXxtWGtQCp7lznIDukIwCphUcNyNeBkGcazEJV9DKLrAX5v55EZ zst7GwPdqpG/KGDBF4T4uAM0nZrnYOk+oPVitKQJ1ulU2V4zsUXjxrUfLb9/7c6Yf783NHWLpYs vlHef2DpaxmRdCQFpmed/bQFww0Ga7xOGpmn7E5hLGdXh6RwddQtQm68R8BNZ5jd7hEp300RiaO MLHJeW80XPxXXsBPNeejlQUSqVZYq4PDMD3qKa/h5fAD0rzNzSQxvu0wiwPHJKRNjGUTy0OsBoN YYExNAgjyUOEC+eG4rt6dtu6rWDTZTok9A8fyki3uzDfNiPTdbtOzYs0Vbw2b9z40bjOgL+aTeQ 4S3TKt2CXffdluHxXl2QX4+vnG/goK53Cq4xPQ2ltQbN/E5yxmdI1MyWJ1LtjsS9LsXo5x3co0S RUOc7YSS79GucQjkPNA== X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1143,Hydra:6.1.134,FMLib:17.12.100.49 definitions=2026-07-20_06,2026-07-20_03,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 malwarescore=0 spamscore=0 clxscore=1015 adultscore=0 priorityscore=1501 impostorscore=0 phishscore=0 bulkscore=0 lowpriorityscore=0 suspectscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2606150000 definitions=main-2607210043 X-MIME-Autoconverted: from 8bit to quoted-printable by mx0a-0064b401.pphosted.com id 66L46B1r1635816 List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Tue, 21 Jul 2026 04:31:48 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/241497 From: Deepesh Varatharajan [YOCTO #15808] Consolidate Rust source management across all Rust recipes (rust, cargo, libstd-rs and their native/nativesdk variants) into a single shared source tree using the work-shared pattern. Disk savings: a world build with multilibs enabled, together with nativesdk-rust and nativesdk-cargo, now shares a single ~4.2 GB rustc-src tree instead of maintaining up to 11 independent copies (~46.2 GB total). Performance (clean core-image-sato build, qemux86-64): Before: 68m53.507s After: 65m46.159s Improvement: 3m07.348s (~4.5%) New files: - rust-source.bb: A shared recipe that fetches, unpacks, and patches the rustc source tree into ${TMPDIR}/work-shared/rust-source-${PV}-${PR}. All build/install/packaging tasks are disabled; this recipe exists solely to provide a single copy of the source. Inherits allarch/nopackages, excludes itself from rm_work, and is hidden from world builds. Also defines RUST_BUILD_ARCH locally since this recipe does not inherit rust-common.bbclass but still needs the mapping for snapshot fetching via rust-snapshot.inc. - common-source.inc: Included by consumer recipes (rust, cargo, libstd-rs) to disable their local do_fetch/do_unpack/do_patch tasks, clear SRC_URI, and add task dependencies on rust-source-${PV} for configure, licensing, and SPDX generation. Also provides is_work_shared_spdx() override for correct SPDX shared-workdir detection. Modified files: - rust-source.inc: - Replace RUST_VERSION with explicit MAJOR_VER/MINOR_VER/PATCH_VER and PV. - Set UNPACKDIR to the work-shared location so all consumers share one source tree via RUSTSRC and S. - rust_git.bb (renamed from rust_1.96.1.bb): - Add 'require common-source.inc' to use the shared source tree. - Set B = ${WORKDIR}/build to separate build artifacts from shared source. - Set CARGO_HOME = ${WORKDIR}/cargo_home to isolate cargo caching. - Set build-dir = "rust-build" in config.toml to distinguish Yocto's build directory (B), which holds config.toml, from the bootstrap's own build output directory. Without this, bootstrap defaults to "build/" inside B, creating an ambiguous build/build/ nesting. - Use absolute ${S}/src/bootstrap/bootstrap.py path since cwd is now B. - Update install functions to reference rust-build/ instead of build/. - Update do_test_compile to use absolute ${S}/src/tools/ path. - Change do_rust_setup_snapshot from 'after do_unpack' to depend on rust-source-${PV}:do_unpack (since local do_unpack is removed). - cargo_git.bb (renamed from cargo_1.96.1.bb): - Add 'require common-source.inc' to use the shared source tree. - Change do_cargo_setup_snapshot from 'after do_unpack' to depend on rust-source-${PV}:do_unpack. - libstd-rs_git.bb (renamed from libstd-rs_1.96.1.bb): - Add 'require common-source.inc' to use the shared source tree. - rust-cross-canadian_git.bb (renamed from rust-cross-canadian_1.96.1.bb): - Rename only (version now comes from rust-source.inc via PV). - rust-common.bbclass: - Add a second --remap-path-prefix for ${TMPDIR}/work-shared so debug info from the shared source tree is correctly remapped. - Retain RUST_BUILD_ARCH definition so that consumer recipes (rust, cargo, libstd-rs) which inherit this class can resolve snapshot directory names used by do_rust_setup_snapshot and do_cargo_setup_snapshot. - lib/oeqa/selftest/cases/rust.py: - Adapt the selftest to the build-dir/source-dir split: use B for build artifacts and RUSTSRC for source paths. - Update remote-test-server copy path from build/ to rust-build/. - Pass --build-dir and --config explicitly to bootstrap.py. - conf/distro/include/maintainers.inc: - Add maintainer entry for the new rust-source recipe. Signed-off-by: Deepesh Varatharajan --- meta/classes-recipe/rust-common.bbclass | 4 +- meta/conf/distro/include/maintainers.inc | 1 + meta/lib/oeqa/selftest/cases/rust.py | 9 ++- .../rust/{cargo_1.96.1.bb => cargo_git.bb} | 8 ++- meta/recipes-devtools/rust/common-source.inc | 28 ++++++++++ .../{libstd-rs_1.96.1.bb => libstd-rs_git.bb} | 4 ++ ...n_1.96.1.bb => rust-cross-canadian_git.bb} | 0 meta/recipes-devtools/rust/rust-source.bb | 56 +++++++++++++++++++ meta/recipes-devtools/rust/rust-source.inc | 16 +++++- .../rust/{rust_1.96.1.bb => rust_git.bb} | 31 +++++++--- 10 files changed, 140 insertions(+), 17 deletions(-) rename meta/recipes-devtools/rust/{cargo_1.96.1.bb => cargo_git.bb} (91%) create mode 100644 meta/recipes-devtools/rust/common-source.inc rename meta/recipes-devtools/rust/{libstd-rs_1.96.1.bb => libstd-rs_git.bb} (92%) rename meta/recipes-devtools/rust/{rust-cross-canadian_1.96.1.bb => rust-cross-canadian_git.bb} (100%) create mode 100644 meta/recipes-devtools/rust/rust-source.bb rename meta/recipes-devtools/rust/{rust_1.96.1.bb => rust_git.bb} (93%) diff --git a/meta/classes-recipe/rust-common.bbclass b/meta/classes-recipe/rust-common.bbclass index 057aeda67a..6bc42016d1 100644 --- a/meta/classes-recipe/rust-common.bbclass +++ b/meta/classes-recipe/rust-common.bbclass @@ -14,7 +14,9 @@ FILES:${PN}-dev += "${rustlibdir}/*.rlib ${rustlibdir}/*.rmeta" FILES:${PN}-dbg += "${rustlibdir}/.debug" RUSTLIB ?= "-L ${STAGING_DIR_HOST}${rustlibdir}" -RUST_DEBUG_REMAP = "--remap-path-prefix=${WORKDIR}=${TARGET_DBGSRC_DIR}" +RUST_DEBUG_REMAP = "--remap-path-prefix=${WORKDIR}=${TARGET_DBGSRC_DIR} \ + --remap-path-prefix=${TMPDIR}/work-shared=${TARGET_DBGSRC_DIR} \ +" RUSTFLAGS += "${RUSTLIB} ${RUST_DEBUG_REMAP}" RUSTLIB_DEP ??= "libstd-rs" RUST_PANIC_STRATEGY ??= "unwind" diff --git a/meta/conf/distro/include/maintainers.inc b/meta/conf/distro/include/maintainers.inc index 4c6307086c..bfff5082c2 100644 --- a/meta/conf/distro/include/maintainers.inc +++ b/meta/conf/distro/include/maintainers.inc @@ -784,6 +784,7 @@ RECIPE_MAINTAINER:pn-ruby = "Ross Burton " RECIPE_MAINTAINER:pn-run-postinsts = "Ross Burton " RECIPE_MAINTAINER:pn-rust = "Randy MacLeod " RECIPE_MAINTAINER:pn-rust-cross-canadian-${TRANSLATED_TARGET_ARCH} = "Randy MacLeod " +RECIPE_MAINTAINER:pn-rust-source-1.96.1 = "Deepesh Varatharajan " RECIPE_MAINTAINER:pn-rxvt-unicode = "Unassigned " RECIPE_MAINTAINER:pn-sassc = "Simone Weiß " RECIPE_MAINTAINER:pn-sato-icon-theme = "Richard Purdie " diff --git a/meta/lib/oeqa/selftest/cases/rust.py b/meta/lib/oeqa/selftest/cases/rust.py index c961a8f652..4111d72044 100644 --- a/meta/lib/oeqa/selftest/cases/rust.py +++ b/meta/lib/oeqa/selftest/cases/rust.py @@ -46,7 +46,8 @@ class RustSelfTestSystemEmulated(OESelftestTestCase, OEPTestResultTestCase): recipe = "rust" start_time = time.time() bitbake("{} -c test_compile".format(recipe)) - builddir = get_bb_var("RUSTSRC", "rust") + builddir = get_bb_var("B", "rust") + sourcedir = get_bb_var("RUSTSRC", "rust") # build core-image-minimal with required packages default_installed_packages = ["libgcc", "libstdc++", "libatomic", "libgomp", "libzstd", "llvm", "openssl"] features = [] @@ -111,7 +112,7 @@ class RustSelfTestSystemEmulated(OESelftestTestCase, OEPTestResultTestCase): # Copy remote-test-server to image through scp host_sys = get_bb_var("RUST_BUILD_SYS", "rust") ssh = SSHControl(ip=qemu.ip, logfile=qemu.sshlog, user="root") - ssh.copy_to(builddir + "/build/" + host_sys + "/stage2-tools-bin/remote-test-server","~/") + ssh.copy_to(builddir + "/rust-build/" + host_sys + "/stage2-tools-bin/remote-test-server","~/") # Execute remote-test-server on image through background ssh command = '~/remote-test-server --bind 0.0.0.0:12345 -v' sshrun=subprocess.Popen(("ssh", '-o', 'UserKnownHostsFile=/dev/null', '-o', 'StrictHostKeyChecking=no', '-f', "root@%s" % qemu.ip, command), shell=False, stdout=subprocess.PIPE, stderr=subprocess.PIPE) @@ -131,8 +132,10 @@ class RustSelfTestSystemEmulated(OESelftestTestCase, OEPTestResultTestCase): # PowerPC mac99 QEMU has 768MB RAM limit, so we need to minimize test binary sizes cmd = cmd + " export RUSTFLAGS='-C strip=debuginfo -Clink-arg=-lz -Clink-arg=-lzstd';" # Trigger testing. + # Run bootstrap from sourcedir with explicit --build-dir and --config + # pointing to the separate build directory. cmd = cmd + " export TEST_DEVICE_ADDR=\"%s:12345\";" % qemu.ip - cmd = cmd + " cd %s; python3 src/bootstrap/bootstrap.py test %s --target %s" % (builddir, testargs, targetsys) + cmd = cmd + " cd %s; python3 src/bootstrap/bootstrap.py --build-dir %s/rust-build --config %s/config.toml test %s --target %s" % (sourcedir, builddir, builddir, testargs, targetsys) retval = runCmd(cmd) end_time = time.time() diff --git a/meta/recipes-devtools/rust/cargo_1.96.1.bb b/meta/recipes-devtools/rust/cargo_git.bb similarity index 91% rename from meta/recipes-devtools/rust/cargo_1.96.1.bb rename to meta/recipes-devtools/rust/cargo_git.bb index f16688fc76..8047a2b255 100644 --- a/meta/recipes-devtools/rust/cargo_1.96.1.bb +++ b/meta/recipes-devtools/rust/cargo_git.bb @@ -13,6 +13,8 @@ LIC_FILES_CHKSUM = " \ require rust-source.inc require rust-snapshot.inc +# Use shared source tree from rust-source.bb; disables local fetch/unpack/patch +require common-source.inc S = "${RUSTSRC}/src/tools/cargo" CARGO_VENDORING_DIRECTORY = "${RUSTSRC}/vendor" @@ -21,6 +23,9 @@ CVE_PRODUCT = "rust-lang:cargo" inherit cargo pkgconfig +# Explicit CARGO_HOME avoids cargo caching in the shared source tree +CARGO_HOME = "${WORKDIR}/cargo_home" + DEBUG_PREFIX_MAP += "-ffile-prefix-map=${RUSTSRC}/vendor=${TARGET_DBGSRC_DIR}" do_cargo_setup_snapshot () { @@ -32,9 +37,10 @@ do_cargo_setup_snapshot () { fi } -addtask cargo_setup_snapshot after do_unpack before do_configure +addtask cargo_setup_snapshot before do_configure do_cargo_setup_snapshot[dirs] += "${WORKDIR}/${CARGO_SNAPSHOT}" do_cargo_setup_snapshot[vardepsexclude] += "UNINATIVE_LOADER" +do_cargo_setup_snapshot[depends] += "rust-source-${PV}:do_unpack" do_compile:prepend () { export RUSTC_BOOTSTRAP="1" diff --git a/meta/recipes-devtools/rust/common-source.inc b/meta/recipes-devtools/rust/common-source.inc new file mode 100644 index 0000000000..a0d4dc542c --- /dev/null +++ b/meta/recipes-devtools/rust/common-source.inc @@ -0,0 +1,28 @@ +# common-source.inc - Disable source tasks for recipes using shared rust-source +# +# Recipes that include this file rely on rust-source-${PV} for fetching, +# unpacking, and patching the Rust source tree. This avoids duplicating the +# ~4.2 GB rustc-src tree per recipe variant (rust, cargo, libstd-rs and their +# native/nativesdk counterparts). + +# Disable local fetch/unpack/patch since rust-source-${PV} handles them +do_fetch() { + : +} +do_fetch[noexec] = "1" +deltask do_unpack +deltask do_patch + +# Clear SRC_URI to prevent fetcher warnings from stale URIs inherited via .inc +SRC_URI = "" + +# Ensure the shared source is fully ready before dependent tasks run +do_configure[depends] += "rust-source-${PV}:do_patch" +do_populate_lic[depends] += "rust-source-${PV}:do_unpack" +do_create_spdx[depends] += "rust-source-${PV}:do_patch" + +# The SPDX class uses is_work_shared_spdx() to detect shared workdirs. +# Since we redirect S rather than WORKDIR, the default detection fails. +# Override to always return True so SPDX processing works correctly. +def is_work_shared_spdx(d): + return True diff --git a/meta/recipes-devtools/rust/libstd-rs_1.96.1.bb b/meta/recipes-devtools/rust/libstd-rs_git.bb similarity index 92% rename from meta/recipes-devtools/rust/libstd-rs_1.96.1.bb rename to meta/recipes-devtools/rust/libstd-rs_git.bb index 2a5e977a5e..31d42a8525 100644 --- a/meta/recipes-devtools/rust/libstd-rs_1.96.1.bb +++ b/meta/recipes-devtools/rust/libstd-rs_git.bb @@ -5,6 +5,7 @@ LICENSE = "(MIT | Apache-2.0) & Unicode-3.0" LIC_FILES_CHKSUM = "file://../../COPYRIGHT;md5=11a3899825f4376896e438c8c753f8dc" require rust-source.inc +require common-source.inc # The dummy crate named `sysroot` represents the standard library target. # @@ -30,6 +31,9 @@ CARGO_FEATURES ?= "panic-unwind backtrace" CARGO_BUILD_FLAGS += "--features '${CARGO_FEATURES}'" CARGO_VENDORING_DIRECTORY = "${RUSTSRC}/vendor" +# Explicit CARGO_HOME avoids cargo caching in the shared source tree +CARGO_HOME = "${WORKDIR}/cargo_home" + do_compile:prepend () { # For Rust 1.13.0 and newer export RUSTC_BOOTSTRAP="1" diff --git a/meta/recipes-devtools/rust/rust-cross-canadian_1.96.1.bb b/meta/recipes-devtools/rust/rust-cross-canadian_git.bb similarity index 100% rename from meta/recipes-devtools/rust/rust-cross-canadian_1.96.1.bb rename to meta/recipes-devtools/rust/rust-cross-canadian_git.bb diff --git a/meta/recipes-devtools/rust/rust-source.bb b/meta/recipes-devtools/rust/rust-source.bb new file mode 100644 index 0000000000..ba696984b3 --- /dev/null +++ b/meta/recipes-devtools/rust/rust-source.bb @@ -0,0 +1,56 @@ +# rust-source.bb - Shared source recipe for the Rust toolchain +# +# This recipe fetches, unpacks, and patches the rustc source tree into a +# work-shared location so that rust, cargo, libstd-rs, and their native/nativesdk +# variants all share a single copy of the source. This eliminates duplication +# (up to 11 copies of the ~4.2 GB source tree in multilib + nativesdk builds) +# and significantly reduces disk usage (~46.2 GB -> ~4.2 GB for rustc-src). +# +# Only do_fetch, do_unpack, and do_patch are meaningful here. All other +# tasks are disabled since this recipe exists solely to provide sources. + +SUMMARY = "Rust compiler and runtime libaries" +HOMEPAGE = "http://www.rust-lang.org" +SECTION = "devel" +LICENSE = "(MIT | Apache-2.0) & Unicode-3.0" +LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=11a3899825f4376896e438c8c753f8dc" + +# This recipe only provides source; disable build/install/packaging tasks +deltask do_configure +deltask do_compile +deltask do_install +deltask do_populate_sysroot +deltask do_populate_lic + +# Prevent rm_work from removing the shared source tree +RM_WORK_EXCLUDE += "${PN}" + +require rust-source.inc +require rust-snapshot.inc + +inherit allarch nopackages + +PN = "rust-source-${PV}" +BPN = "rust-source" + +# Place WORKDIR under work-shared so all consumers reference the same location +WORKDIR = "${TMPDIR}/work-shared/rust-source-${PV}-${PR}" +SSTATE_SWSPEC = "sstate:rust-source::${PV}:${PR}::${SSTATE_VERSION}:" + +# Use work-shared stamp directory so sstate is shared across all architectures +STAMP = "${STAMPS_DIR}/work-shared/rust-source-${PV}-${PR}" +STAMPCLEAN = "${STAMPS_DIR}/work-shared/rust-source-${PV}-*" + +DEPENDS = "" +PACKAGES = "" +baselib = "lib" +PACKAGE_ARCH = "all" + +B = "${WORKDIR}/build" + +# rust-source.bb does not inherit rust-common.bbclass (it is allarch/nopackages +# and has no toolchain dependencies), so we define RUST_BUILD_ARCH locally for +# snapshot URL resolution in rust-snapshot.inc. +RUST_BUILD_ARCH = "${@{'ppc': 'powerpc', 'ppc64': 'powerpc64', 'ppc64le': 'powerpc64le', 'riscv64': 'riscv64gc'}.get(d.getVar('BUILD_ARCH'), d.getVar('BUILD_ARCH'))}" + +EXCLUDE_FROM_WORLD = "1" diff --git a/meta/recipes-devtools/rust/rust-source.inc b/meta/recipes-devtools/rust/rust-source.inc index 5678e00671..49207a3947 100644 --- a/meta/recipes-devtools/rust/rust-source.inc +++ b/meta/recipes-devtools/rust/rust-source.inc @@ -1,6 +1,12 @@ -RUST_VERSION ?= "${@d.getVar('PV').split('-')[0]}" +# Version is split into MAJOR_VER and MINOR_VER for easy bumping and +# to allow consistent use of PV across all consuming recipes. +MAJOR_VER = "1" +MINOR_VER = "96" +PATCH_VER = "1" -SRC_URI += "https://static.rust-lang.org/dist/rustc-${RUST_VERSION}-src.tar.xz;name=rust \ +PV = "${MAJOR_VER}.${MINOR_VER}.${PATCH_VER}" + +SRC_URI += "https://static.rust-lang.org/dist/rustc-${PV}-src.tar.xz;name=rust \ file://0001-Define-more-ioctl-codes-on-riscv32gc-unknown-linux-g.patch;patchdir=${RUSTSRC} \ file://rust-oe-selftest.patch;patchdir=${RUSTSRC} \ file://repro-issue-fix-with-cc-crate-hashmap.patch;patchdir=${RUSTSRC} \ @@ -13,7 +19,11 @@ SRC_URI += "https://static.rust-lang.org/dist/rustc-${RUST_VERSION}-src.tar.xz;n " SRC_URI[rust.sha256sum] = "77a6ff3003a4ad0cb00697b043c879e3e1a15d945b1a1f63818903bfc3fa8b98" -RUSTSRC = "${UNPACKDIR}/rustc-${RUST_VERSION}-src" +# Point UNPACKDIR into the work-shared location so rust-source.bb and all +# consumers (via S/RUSTSRC) reference a single shared source tree. +UNPACKDIR = "${TMPDIR}/work-shared/rust-source-${PV}-${PR}/sources" +RUSTSRC = "${UNPACKDIR}/rustc-${PV}-src" +S = "${RUSTSRC}" UPSTREAM_CHECK_URI = "https://forge.rust-lang.org/infra/other-installation-methods.html" UPSTREAM_CHECK_REGEX = "rustc-(?P\d+(\.\d+)+)-src" diff --git a/meta/recipes-devtools/rust/rust_1.96.1.bb b/meta/recipes-devtools/rust/rust_git.bb similarity index 93% rename from meta/recipes-devtools/rust/rust_1.96.1.bb rename to meta/recipes-devtools/rust/rust_git.bb index 8b0f1d1459..da042ffaae 100644 --- a/meta/recipes-devtools/rust/rust_1.96.1.bb +++ b/meta/recipes-devtools/rust/rust_git.bb @@ -4,6 +4,10 @@ SECTION = "devel" LICENSE = "(MIT | Apache-2.0) & Unicode-3.0" LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=11a3899825f4376896e438c8c753f8dc" +require rust-source.inc +require rust-snapshot.inc +require common-source.inc + inherit rust inherit cargo_common @@ -24,6 +28,9 @@ INHIBIT_DEFAULT_RUST_DEPS:class-native = "1" PROVIDES:class-native = "virtual/${TARGET_PREFIX}rust" S = "${RUSTSRC}" +# Separate build directory from the shared source tree so that multiple +# variants (target, native, nativesdk) don't conflict in the source dir. +B = "${WORKDIR}/build" # Use at your own risk, accepted values are stable, beta and nightly RUST_CHANNEL ?= "stable" @@ -38,6 +45,9 @@ RUST_ALTERNATE_EXE_PATH_NATIVE = "${STAGING_BINDIR_NATIVE}/llvm-config" # own vendoring. CARGO_DISABLE_BITBAKE_VENDORING = "1" +# Explicit CARGO_HOME avoids cargo caching in the shared source tree +CARGO_HOME = "${WORKDIR}/cargo_home" + setup_cargo_environment () { # The first step is to build bootstrap and some early stage tools, # these are build for the same target as the snapshot, e.g. @@ -66,11 +76,11 @@ do_rust_setup_snapshot () { done fi } -addtask rust_setup_snapshot after do_unpack before do_configure +addtask rust_setup_snapshot before do_configure addtask do_test_compile after do_configure do_rust_gen_targets do_rust_setup_snapshot[dirs] += "${WORKDIR}/rust-snapshot" do_rust_setup_snapshot[vardepsexclude] += "UNINATIVE_LOADER" -do_rust_setup_snapshot[depends] += "patchelf-native:do_populate_sysroot" +do_rust_setup_snapshot[depends] += "patchelf-native:do_populate_sysroot rust-source-${PV}:do_unpack" RUSTC_BOOTSTRAP = "${STAGING_BINDIR_NATIVE}/rustc" CARGO_BOOTSTRAP = "${STAGING_BINDIR_NATIVE}/cargo" @@ -173,6 +183,12 @@ python do_configure() { # nothing about when trying to build some stage0 tools (like fabricate) config.set("build", "build", e(d.getVar("RUST_BUILD_SYS"))) + # Yocto's B (${WORKDIR}/build) is where config.toml lives. Rust's + # bootstrap creates its own build output directory inside B; name it + # "rust-build" to avoid ambiguity with Yocto's build directory and + # prevent a confusing build/build/ nesting. + config.set("build", "build-dir", e("rust-build")) + # [install] config.add_section("install") # ./x.py install doesn't have any notion of "destdir" @@ -223,13 +239,10 @@ rust_runx () { oe_cargo_fix_env - python3 src/bootstrap/bootstrap.py ${@oe.utils.parallel_make_argument(d, '-j %d')} "$@" --verbose + python3 ${S}/src/bootstrap/bootstrap.py ${@oe.utils.parallel_make_argument(d, '-j %d')} "$@" --verbose } rust_runx[vardepsexclude] += "PARALLEL_MAKE" -require rust-source.inc -require rust-snapshot.inc - INSANE_SKIP:${PN}:class-native = "already-stripped" FILES:${PN} += "${libdir}/rustlib" FILES:${PN} += "${libdir}/*.so" @@ -241,7 +254,7 @@ do_compile () { do_test_compile[dirs] = "${B}" do_test_compile () { replace_llvm_config_path - rust_runx build src/tools/remote-test-server --target "${RUST_TARGET_SYS}" + rust_runx build ${S}/src/tools/remote-test-server --target "${RUST_TARGET_SYS}" } ALLOW_EMPTY:${PN} = "1" @@ -282,7 +295,7 @@ rust_do_install:class-nativesdk() { install -d ${D}${bindir} for i in cargo-clippy clippy-driver rustfmt; do - cp build/${RUST_BUILD_SYS}/stage2-tools/${RUST_HOST_SYS}/release/$i ${D}${bindir} + cp rust-build/${RUST_BUILD_SYS}/stage2-tools/${RUST_HOST_SYS}/release/$i ${D}${bindir} patchelf --set-rpath "\$ORIGIN/../lib" ${D}${bindir}/$i done @@ -322,7 +335,7 @@ rust_do_install:class-target() { install -d ${D}${bindir} for i in ${EXTRA_TOOLS}; do - cp build/${RUST_BUILD_SYS}/stage2-tools/${RUST_HOST_SYS}/release/$i ${D}${bindir} + cp rust-build/${RUST_BUILD_SYS}/stage2-tools/${RUST_HOST_SYS}/release/$i ${D}${bindir} patchelf --set-rpath "\$ORIGIN/../lib" ${D}${bindir}/$i done From patchwork Tue Jul 21 04:31:12 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Deepesh Varatharajan X-Patchwork-Id: 93011 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6B72DC44529 for ; Tue, 21 Jul 2026 04:31:58 +0000 (UTC) Received: from mx0a-0064b401.pphosted.com (mx0a-0064b401.pphosted.com [205.220.166.238]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.15638.1784608310323791094 for ; Mon, 20 Jul 2026 21:31:50 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@windriver.com header.s=PPS06212021 header.b=HICi54BV; spf=permerror, err=parse error for token &{10 18 %{ir}.%{v}.%{d}.spf.has.pphosted.com}: invalid domain name (domain: windriver.com, ip: 205.220.166.238, mailfrom: prvs=1662381085=deepesh.varatharajan@windriver.com) Received: from pps.filterd (m0250809.ppops.net [127.0.0.1]) by mx0a-0064b401.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 66L3aA5q1584403 for ; Mon, 20 Jul 2026 21:31:50 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=windriver.com; h=cc:content-transfer-encoding:content-type:date:from :in-reply-to:message-id:mime-version:references:subject:to; s= PPS06212021; bh=lEnmHvUemps7tSKcW61ZLn1izUf5ixxwaKma6WXB4yc=; b= HICi54BVYOroGo/3C6OhV5LOCLr3NHwqljX31oL+/oSbZCwJyNO1kqxvLapnILLe wRYMASK8ENxdjIlcIwSLfjORbeTCcIDUhUGxNFn48ieqJn6rnjLri0MuvaGUe84f fqkghQqbpCnSrBfv4/X4G+v8HASKsZsZa/yavsZnYBklIgXoU09wCGLkAr2t3hxM 7UBQg6lyR4+eLvfBsIiqhqSJ0PnE7q3jgd5RXgZMDjadr6BmDME+lVSiRU0VcEd7 smHUhVWkHbHfKyVGsYg6XmvKYclY9sJ4frKU5eNLrFQaiCXJDcPWMU+MQWxunDqM WhnnROpJAY3VhKoWQuy6Og== Received: from ch5pr02cu005.outbound.protection.outlook.com (mail-northcentralusazon11012028.outbound.protection.outlook.com [40.107.200.28]) by mx0a-0064b401.pphosted.com (PPS) with ESMTPS id 4fg90cutft-1 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT) for ; Mon, 20 Jul 2026 21:31:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=kB5J8gU3a74OTOEDx+QmzfPMEKJRyQubXOWWW6uIwRVCdrH3bhMpXMAVWL3KjU0X/C4Ip9DiD2bEWbVAJyGi+q0ofW6HCwkWov9WWwq+aVwkBNvTefXYePzLTaBKYYkrUFkV9NFQ/OVFb2UiQ80Mp69JPcppim5V4OjFnwvrOjdQG9e6Of03/u4ah41WeKkgToCByLiLvXf4yxUP4A94bKMEjvLN+pzcY/JcdqEVw9y4H9Zjk6Xy++fTrwYgs6QIn/oYjbVyt6mho1tB4b/KD0IffY9xvYxZQCT5pFyaXzYc+N+03SI/wpYp3ttS11SqIkr/eI1kqDFQf+CuicJowA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=lEnmHvUemps7tSKcW61ZLn1izUf5ixxwaKma6WXB4yc=; b=O05QkdyZjdf0oWX4ABGS2gJCNQ1BKiMbfzYy+0wybTpmOyBTbkBV0i+f/Jq1rHA0xisZbLMDqDfiabQvTvfoPfL4Xl8Kcfo0Iv2ioyVzBv0KCGPOaQFQMC+msUQK0wLsozqyf1QKL/SFPxun55/pqUHuK7uA3De413KdKqGMr8vrqyooThEtanq/lR2ATydmECKxA+UNPtGaQTlhEXBeFK+cYFvS4eM5Q+0suDK02AATWF7FGTugFkEZ5nEOJywqBNyyTbAXTAZdCvV7hf7N5aU5qHB7QL/HXpvKPV7v/HD5ZDqTzfQ4J2PQfpL60JEdSxdfCX9HCH7CvsPUeMmbJQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=windriver.com; dmarc=pass action=none header.from=windriver.com; dkim=pass header.d=windriver.com; arc=none Received: from SN7PR11MB6677.namprd11.prod.outlook.com (2603:10b6:806:26b::6) by DSVPR11MB445312.namprd11.prod.outlook.com (2603:10b6:8:37a::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.223.18; Tue, 21 Jul 2026 04:31:48 +0000 Received: from SN7PR11MB6677.namprd11.prod.outlook.com ([fe80::490a:519b:d657:99ab]) by SN7PR11MB6677.namprd11.prod.outlook.com ([fe80::490a:519b:d657:99ab%4]) with mapi id 15.21.0223.017; Tue, 21 Jul 2026 04:31:48 +0000 From: Deepesh.Varatharajan@windriver.com To: openembedded-core@lists.openembedded.org Cc: randy.macleod@windriver.com, Sundeep.Kokkonda@windriver.com, Deepesh.Varatharajan@windriver.com Subject: [PATCH 3/3] rust: Move do_update_snapshot to rust-source Date: Mon, 20 Jul 2026 21:31:12 -0700 Message-ID: <20260721043124.3538696-3-Deepesh.Varatharajan@windriver.com> X-Mailer: git-send-email 2.49.0 In-Reply-To: <20260721043124.3538696-1-Deepesh.Varatharajan@windriver.com> References: <20260721043124.3538696-1-Deepesh.Varatharajan@windriver.com> X-ClientProxiedBy: SJ0PR13CA0099.namprd13.prod.outlook.com (2603:10b6:a03:2c5::14) To SN7PR11MB6677.namprd11.prod.outlook.com (2603:10b6:806:26b::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SN7PR11MB6677:EE_|DSVPR11MB445312:EE_ X-MS-Office365-Filtering-Correlation-Id: 3f138861-89c4-4f7f-32e7-08dee6e0fa88 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|52116014|376014|23010399003|1800799024|366016|38350700014|6133799003|56012099006|11063799006|10067099003|22082099003|18002099003; X-Microsoft-Antispam-Message-Info: 096Yt8Lm/mMYxigDIofXuhg4oshN7GkMu2SaL3KDAliiOfB7xSxsnT2FaEtzX31LgqIUh3hgrILES/WLe/MOJ/flleXiHVom2OeLhwOpk2dD5llCIpMysGCiR2SRxW8DIDtt/YZTDbzskto+rqCz/RU3TWy5Pj81NTGdD5GugkHrvSFYQv7UZIfaWKdFkttvZddJtm8ein4ApSCjyAdEtz8hus+7sJPIucHG/2O0FcE7aheeViQK3D4/ahLeFs7FqZY6x+uDbbeYbXP7fRMrn96y8jyOhj0l+64BSZ2z5AqzmZ5yHw23psiNOPRmqfFi+SaqVS5KTn2gwxFZdTzjihLN8GSgsom6NiSFXLJz1qbCD/zI2mWZoFItNNtIJ9q3RLJbbnAr0YZJWIA/gS6RJaM5hNI2LSynQLi641N/vhP5o+4Msf4Q019R4YNSfmvN+R2nednNbzyiBqZmx2JqJpmbTOXmzltuyBYpooLNG3572v6mdfBVY1w5byFSb0fi27LSQazwPAoqcu/Zz6nR02zAQzeGUGVqzEhIB3/yNlgnRGkaR+670NT3yIDjOlRVr5yLS22yvXGm1GH/T7lCqH5CsG/ljdwaqWdgJP3Ew4xjCavjLLuY4Ta+BWufMnmuD+v8yovZ01BK3RbAxLoUxsWxzA74ukQQqLjwEv5cGjPaUmNJkjn2Twgkw+ZTWn7T6W0eKZWm+9sW8RwoX8DT97UEcuD1IgV41cvYRnfukPY= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SN7PR11MB6677.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(52116014)(376014)(23010399003)(1800799024)(366016)(38350700014)(6133799003)(56012099006)(11063799006)(10067099003)(22082099003)(18002099003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 6S57JM0Q13QT2/7u2dc8NTKbVlGEGjMsPBadZ3LGR2KuBed7tfU9OuoAFOLpcQ9LWwHeMfsVh2g2hGtEhxIpu5LffUjYsb3B9IHh6U0aPEwpJOy0RSwEKcQz1IuklmgN5AXsqffvoVo3X/uVtXbQkiAreG9uIm7YMg1fK17Sl7cC5FpyhIOw9uko+HYiC76eFA3jiSJv593vUsPRBMS99xaXdj0gQFOMxR4Dg5Tif16TUsVJU48xJ0hBH+HuPGGz6IDMxASO9vmT+e5QSdQR7iRsm/Yqk+Aju+15gv7j3WNNi0LD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bUwaZbcNxvy35TZ3NbSJbZP8Aizywl7UViE7ynP16/vEPVdfCfGrgw8mgq/R86jecKuE7LF+oTAWfY9XYHXytFW9l8Nlds+kayXf3YPYaz6hfS91WAFWo2sC2xlO6jD2AisL4BNCsws95RW5aTRtMgAseqkL+9SmRmINwA5xKvVKj8OtSLPQHr+k3mGcioiMBslU+bH2KFqeEg76p+4ZjbYmx8chfkAreQQnoN+Le9Ododz2GhdD4pD/HL4QBXdngmRswN8gkKsYzmFBZ8WwOWtDwYHBwRb8KEmTdNzcazQ5IB7s757MUMDFkdH0Z/KXXCXQTLUCOxhKCJ8XGyVXSgWYpEWOI4xo6TTLnj4N40LsRwuxhljfNKtPsg/soene4TfjKq+jRHJe6/CrrwIUwAEwnwXxxAvi2+ X-Exchange-RoutingPolicyChecked: rucz/ZerVPSkF8Aytg7Ple3cMEt/xxbqS3F0FX0rVQBEhml7i6Eo1rAG/SKnXnslMdYFnND/VjYH5OWtWSe3STmNoEWfOevLzQ820+jWOiwjOSuOd6ZfEZvFV+2zHG2c7galTYd2O/ips0aAsOUW3KlZGtGjJDT+I3c2vI4wet90BnImttXmlPNp4DUdjUu02QzDCuETn2SP9ZGKuKWLHN/tULO9izULOMG73A4DexJW8cqIUp1PYL1SGBpCqQx/gzX9VNO/zPx4BiOZhbUVVJxBXSS7AnQXRBu/7X9FTo3v+BjcmO0kOFMA6WJWgRzA8BsSBMeOKKSz2Ryp/B7mqA== X-OriginatorOrg: windriver.com X-MS-Exchange-CrossTenant-Network-Message-Id: 3f138861-89c4-4f7f-32e7-08dee6e0fa88 X-MS-Exchange-CrossTenant-AuthSource: SN7PR11MB6677.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 21 Jul 2026 04:31:48.4556 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 8ddb2873-a1ad-4a18-ae4e-4644631433be X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 0irJARa9qMuKNaJG7nTjsRjLKr+H8g2fdNaI+FHd2+fEU3lWC6Cq0OGK2Y325ptvmdrgQ6EsKtDYwVBYtmXDClea0F5uu6S/1T+K+qZwirYyrddXkM5A3IQqUydFxbR9 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DSVPR11MB445312 X-Proofpoint-ORIG-GUID: P2XAr55VGc14q5DcG4ch-POnGeBWIU64 X-Proofpoint-GUID: P2XAr55VGc14q5DcG4ch-POnGeBWIU64 X-Authority-Analysis: v=2.4 cv=AOkSgtoa c=1 sm=1 tr=0 ts=6a5ef635 cx=c_pps a=7whtcbPCeBOLW6TxF+pv5A==:117 a=6eWqkTHjU83fiwn7nKZWdM+Sl24=:19 a=z/mQ4Ysz8XfWz/Q5cLBRGdckG28=:19 a=lCpzRmAYbLLaTzLvsPZ7Mbvzbb8=:19 a=xqWC_Br6kY4A:10 a=RAioF0-LDSMA:10 a=VkNPw1HP01LnGYTKEx00:22 a=bi6dqmuHe4P4UrxVR6um:22 a=iKiJcTA2PjBS6x5JeXcw:22 a=t7CeM3EgAAAA:8 a=M-5mPBX6iDpf5b3w-P8A:9 a=FdTzh2GWekK77mhwV6Dw:22 X-Proofpoint-Spam-Info: AW1haW4tMjYwNzIxMDA0MyBTYWx0ZWRfX9vBeyTybls+I oLTMT1C7K8m4LFE+sRU+wxXxXXrI8zH0JZDBQz9wSYjEEdQQzkE/4hqb9T+0vBTkiulsEvIY/tK Ae1WFIiA7KsH+t5LdMFZbkF/kq7ivFTiPp95vpaHQIztrnbIGgFT X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwNzIxMDA0MyBTYWx0ZWRfX7Zne7iHCAlhA LEQb3VNQuGSuvVOEsAXvK5z4Uzz4n3ZgFugWuszl1t/UtvU4/RVttcH14s3PQCSUwPu5pqxAEd5 L+V60yo8kOkljBdYmOjzYtVJXd4ACH5/zcduUw86lqEFtNiAjLYlFselCd9+CgS3ZSiwHwuWVjg T8ZsZaoaQELwyLESP916G1/PlaVWnrB3NXriIwwbI6UA7WdLcxgpPR4ylOkICmvipX+/d3kyA5+ WZMu5wwlutt9yXz8LrXfRWHKfBF0LoLA5MQSb0MWuFFoNWMLiijbOnxWZF1T+I8h6bpjsxwBZW+ VshbRcFLdnt/5qzpDTJsdGUuXFHO3QzpaYyxle5XRdeKp/nXiw/XJhQi5DXQ2zv49k7imHOvP77 Y394aea9LcrRJsaOCtGSmAotYhhnnasHGdyL7WD2yBdFOVKBHcu0vrPqwFE70mN8UMGByuYybjh AX1wy58FcjT92FH7+/Q== X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1143,Hydra:6.1.134,FMLib:17.12.100.49 definitions=2026-07-20_06,2026-07-20_03,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 malwarescore=0 spamscore=0 clxscore=1015 adultscore=0 priorityscore=1501 impostorscore=0 phishscore=0 bulkscore=0 lowpriorityscore=0 suspectscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2606150000 definitions=main-2607210043 List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Tue, 21 Jul 2026 04:31:58 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/241498 From: Deepesh Varatharajan Move do_update_snapshot from rust to rust-source, since rust-source now owns do_fetch/do_unpack/do_patch tasks after the shared source refactoring. Signed-off-by: Deepesh Varatharajan --- meta/recipes-devtools/rust/rust-source.bb | 72 ++++++++++++++++++++++ meta/recipes-devtools/rust/rust_git.bb | 73 ----------------------- 2 files changed, 72 insertions(+), 73 deletions(-) diff --git a/meta/recipes-devtools/rust/rust-source.bb b/meta/recipes-devtools/rust/rust-source.bb index ba696984b3..4c29b8e3c7 100644 --- a/meta/recipes-devtools/rust/rust-source.bb +++ b/meta/recipes-devtools/rust/rust-source.bb @@ -54,3 +54,75 @@ B = "${WORKDIR}/build" RUST_BUILD_ARCH = "${@{'ppc': 'powerpc', 'ppc64': 'powerpc64', 'ppc64le': 'powerpc64le', 'riscv64': 'riscv64gc'}.get(d.getVar('BUILD_ARCH'), d.getVar('BUILD_ARCH'))}" EXCLUDE_FROM_WORLD = "1" + +addtask do_update_snapshot after do_patch +do_update_snapshot[nostamp] = "1" + +# Run with `bitbake rust-source-${PV} -c update_snapshot` to update `rust-snapshot.inc` +# with the checksums for the rust snapshot associated with this rustc-src tarball. +python do_update_snapshot() { + import json + import re + import sys + + from collections import defaultdict + + key_value_pairs = {} + with open(os.path.join(d.getVar("S"), "src", "stage0")) as f: + for line in f: + # Skip empty lines or comments + if not line.strip() or line.startswith("#"): + continue + # Split the line into key and value using '=' as separator + match = re.match(r'(\S+)\s*=\s*(\S+)', line.strip()) + if match: + key = match.group(1) + value = match.group(2) + key_value_pairs[key] = value + # Extract the required values from key_value_pairs + config_dist_server = key_value_pairs.get('dist_server', '') + compiler_date = key_value_pairs.get('compiler_date', '') + compiler_version = key_value_pairs.get('compiler_version', '') + + src_uri = defaultdict(list) + # Assuming checksums_sha256 is now a key-value pair like: checksum_key = checksum_value + for k, v in key_value_pairs.items(): + # Match the pattern for checksums + if "dist" in k and "tar.xz" in k: + m = re.search(f"dist/{compiler_date}/(?P.*)-{compiler_version}-(?P.*)-unknown-linux-gnu\\.tar\\.xz", k) + if m: + component = m.group('component') + arch = m.group('arch') + src_uri[arch].append(f"SRC_URI[{component}-snapshot-{arch}.sha256sum] = \"{v}\"") + # Create the snapshot string with the extracted values + snapshot = """\ +## This is information on the rust-snapshot (binary) used to build our current release. +## snapshot info is taken from rust/src/stage0 +## Rust is self-hosting and bootstraps itself with a pre-built previous version of itself. +## The exact (previous) version that has been used is specified in the source tarball. +## The version is replicated here. + +SNAPSHOT_VERSION = "%s" + +""" % compiler_version + # Add the checksum components to the snapshot + for arch, components in src_uri.items(): + snapshot += "\n".join(components) + "\n\n" + # Add the additional snapshot URIs + snapshot += """\ +SRC_URI += " \\ + ${RUST_DIST_SERVER}/dist/${RUST_STD_SNAPSHOT}.tar.xz;name=rust-std-snapshot-${RUST_BUILD_ARCH};subdir=rust-snapshot-components \\ + ${RUST_DIST_SERVER}/dist/${RUSTC_SNAPSHOT}.tar.xz;name=rustc-snapshot-${RUST_BUILD_ARCH};subdir=rust-snapshot-components \\ + ${RUST_DIST_SERVER}/dist/${CARGO_SNAPSHOT}.tar.xz;name=cargo-snapshot-${RUST_BUILD_ARCH};subdir=rust-snapshot-components \\ +" + +RUST_DIST_SERVER = "%s" + +RUST_STD_SNAPSHOT = "rust-std-${SNAPSHOT_VERSION}-${RUST_BUILD_ARCH}-unknown-linux-gnu" +RUSTC_SNAPSHOT = "rustc-${SNAPSHOT_VERSION}-${RUST_BUILD_ARCH}-unknown-linux-gnu" +CARGO_SNAPSHOT = "cargo-${SNAPSHOT_VERSION}-${RUST_BUILD_ARCH}-unknown-linux-gnu" +""" % config_dist_server + # Write the updated snapshot information to the rust-snapshot.inc file + with open(os.path.join(d.getVar("THISDIR"), "rust-snapshot.inc"), "w") as f: + f.write(snapshot) +} diff --git a/meta/recipes-devtools/rust/rust_git.bb b/meta/recipes-devtools/rust/rust_git.bb index da042ffaae..e75c5980f0 100644 --- a/meta/recipes-devtools/rust/rust_git.bb +++ b/meta/recipes-devtools/rust/rust_git.bb @@ -354,79 +354,6 @@ rust_do_install:class-target() { rm ${D}${libdir}/rustlib/${RUST_HOST_SYS}/lib/libstd*.so } -addtask do_update_snapshot after do_patch -do_update_snapshot[nostamp] = "1" - -# Run with `bitbake -c update_snapshot rust` to update `rust-snapshot.inc` -# with the checksums for the rust snapshot associated with this rustc-src -# tarball. -python do_update_snapshot() { - import json - import re - import sys - - from collections import defaultdict - - key_value_pairs = {} - with open(os.path.join(d.getVar("S"), "src", "stage0")) as f: - for line in f: - # Skip empty lines or comments - if not line.strip() or line.startswith("#"): - continue - # Split the line into key and value using '=' as separator - match = re.match(r'(\S+)\s*=\s*(\S+)', line.strip()) - if match: - key = match.group(1) - value = match.group(2) - key_value_pairs[key] = value - # Extract the required values from key_value_pairs - config_dist_server = key_value_pairs.get('dist_server', '') - compiler_date = key_value_pairs.get('compiler_date', '') - compiler_version = key_value_pairs.get('compiler_version', '') - - src_uri = defaultdict(list) - # Assuming checksums_sha256 is now a key-value pair like: checksum_key = checksum_value - for k, v in key_value_pairs.items(): - # Match the pattern for checksums - if "dist" in k and "tar.xz" in k: - m = re.search(f"dist/{compiler_date}/(?P.*)-{compiler_version}-(?P.*)-unknown-linux-gnu\\.tar\\.xz", k) - if m: - component = m.group('component') - arch = m.group('arch') - src_uri[arch].append(f"SRC_URI[{component}-snapshot-{arch}.sha256sum] = \"{v}\"") - # Create the snapshot string with the extracted values - snapshot = """\ -## This is information on the rust-snapshot (binary) used to build our current release. -## snapshot info is taken from rust/src/stage0 -## Rust is self-hosting and bootstraps itself with a pre-built previous version of itself. -## The exact (previous) version that has been used is specified in the source tarball. -## The version is replicated here. - -SNAPSHOT_VERSION = "%s" - -""" % compiler_version - # Add the checksum components to the snapshot - for arch, components in src_uri.items(): - snapshot += "\n".join(components) + "\n\n" - # Add the additional snapshot URIs - snapshot += """\ -SRC_URI += " \\ - ${RUST_DIST_SERVER}/dist/${RUST_STD_SNAPSHOT}.tar.xz;name=rust-std-snapshot-${RUST_BUILD_ARCH};subdir=rust-snapshot-components \\ - ${RUST_DIST_SERVER}/dist/${RUSTC_SNAPSHOT}.tar.xz;name=rustc-snapshot-${RUST_BUILD_ARCH};subdir=rust-snapshot-components \\ - ${RUST_DIST_SERVER}/dist/${CARGO_SNAPSHOT}.tar.xz;name=cargo-snapshot-${RUST_BUILD_ARCH};subdir=rust-snapshot-components \\ -" - -RUST_DIST_SERVER = "%s" - -RUST_STD_SNAPSHOT = "rust-std-${SNAPSHOT_VERSION}-${RUST_BUILD_ARCH}-unknown-linux-gnu" -RUSTC_SNAPSHOT = "rustc-${SNAPSHOT_VERSION}-${RUST_BUILD_ARCH}-unknown-linux-gnu" -CARGO_SNAPSHOT = "cargo-${SNAPSHOT_VERSION}-${RUST_BUILD_ARCH}-unknown-linux-gnu" -""" % config_dist_server - # Write the updated snapshot information to the rust-snapshot.inc file - with open(os.path.join(d.getVar("THISDIR"), "rust-snapshot.inc"), "w") as f: - f.write(snapshot) -} - RUSTLIB_DEP:class-nativesdk = "" # musl builds include libunwind.a