From patchwork Sat Nov 22 22:14:07 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75221 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 A1315CFD2FC for ; Sat, 22 Nov 2025 22:14:43 +0000 (UTC) Received: from mail-pj1-f41.google.com (mail-pj1-f41.google.com [209.85.216.41]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.3743.1763849675702609338 for ; Sat, 22 Nov 2025 14:14:36 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=OrQcuebJ; spf=softfail (domain: sakoman.com, ip: 209.85.216.41, mailfrom: steve@sakoman.com) Received: by mail-pj1-f41.google.com with SMTP id 98e67ed59e1d1-3437af8444cso3357702a91.2 for ; Sat, 22 Nov 2025 14:14:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849675; x=1764454475; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=h742afWuemoFVasah5LQQuHHUsQwDPyfX6YtGwvzBzs=; b=OrQcuebJjlUSvvcGWyKGyFSNi4BtFVYyKuvUjxflNsUoXsD6LKNeh94S0EL3Ob/Boa 0ZaVDCdirfGXs9U6NvytJa4y//RzoFpcP/C3ZSRTkPFF7hHhJanzJeDPebOz+C18mdRK FPJ46Pvdd24KTOL5gfWC4XuAI6iZL/l8ham8wQ67eae4RRBM6kD23GXdv636avdyvLYI lzsHJ9d4SgIs+/WAYWJwKiP+es2PEocgdoDNYTCu5fRCTnHB7EuEsOM2Cy6We8NUdhUf aSz6gG4jqXhoO/STlk4Azm0hbWYMJbE7DA75BmRbhG97cNWFtXjjlEJ8W9Vd7n5GhrPg NdtQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849675; x=1764454475; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=h742afWuemoFVasah5LQQuHHUsQwDPyfX6YtGwvzBzs=; b=QwbuZsdtWlhFNS2jB1XhB+BteAFHdFHsUAB1gcj7/lFF5zNdLzxS9Y4UyPHHripRuf XbcYNe6kxY3CqNVaJ4xCfvnuT96oe7HnPcWamnKIaqBH6fvAZCwvpyNH3TdTb6KVjrYG kCRdwwT5gpyG2JIU7iUPbBqLFNxueJo/Aane/8DztcicFQgo1BUNzDAfoF+67ltAKtbz lDD3BjlaGhLkDCsD6+o9ox+vq8oHDOsAQYfGbOoviMc5JcaCvTPatn82P+2l0t/5ZIeB oHK70feu6oEablWhc5Ugw/HNrpjUS93+JqTu0wqIQBTrV2lQ69jw21Es0aWXuRHZdh1i FcpA== X-Gm-Message-State: AOJu0YzO9Wlvq33d7/dBgnai0rPmJynjgqsokzt4Ti5qtoeTX+0RKk1T LUyu1psvIwKumqwIiMZ7jUszc3XObjtWgkPTlOqlgwA1Py0V1XucF1kM7tZjkQizIJLSlJs+8gm PJVLP X-Gm-Gg: ASbGncs7zllHS71eOeLp2+Q1HYq/U6RmtPvt3LZukxKFsmKTsZdrcwQtnsX7cQDn1Bm a4SbwTA2eESpCKZThau+jfSPCpGxxNZdWtVmpcEGNWvOxoGGsbozs9gD9hXZlMLgNG3Lkoaq+gK SSu/cAFeRLPmnLibaF2I41CH5BKfKmmmHUjwKb3Y9BfkGAOX2vyqVMtf6+PRhdRSNX82ChLNLM5 Q2fIRjiserC4XbUo+j5PuDfxk0oPsPlcjhwxwvUuU1ZmmHHwNK6t8gGsROCUI4DoOc+fHHyQaoK 6BH932n62y6lKXspcoXvtLt3GlZ2PzmD+JSjM9iaxtlsFusr0sOYnHT7xZpAWFH77zrUnzeTV3R sRmPNn37YSrhHvIU+C2MyiqbO/QsPOgaUaZta3eXiAa+0IoLG3rUcNRgKwl/Sxs5QIiOHr6R9Bp y1Eg== X-Google-Smtp-Source: AGHT+IFS+l8eGkuzISXR5pmm8ELnhF7UiwYCG5Bqmal2TtXH167Q0htTOUU2r4pke/PzZ9f84YUWOQ== X-Received: by 2002:a17:90b:582d:b0:341:88ba:bdda with SMTP id 98e67ed59e1d1-34733f40cc0mr7284182a91.31.1763849674868; Sat, 22 Nov 2025 14:14:34 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.14.34 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:14:34 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 01/21] spdx30: fix cve status for patch files in VEX Date: Sat, 22 Nov 2025 14:14:07 -0800 Message-ID: <8d14b2bb02861612130f02c445392f34090ba5d9.1763849517.git.steve@sakoman.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:14:43 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226698 From: Peter Marko This commit fixes commit 08595b39b46ef2bf3a928d4528292ee31a990c98 which adapts vex creation between function create_spdx where all changes were backported and funtion get_patched_cves where changes were not backported. CVE patches were previously ignored as they cannot be decoded from CVE_STATUS variables and each caused a warning like: WARNING: ncurses-native-6.4-r0 do_create_spdx: Skipping CVE-2023-50495 — missing or unknown CVE status Master branch uses fix-file-included for CVE patches however since cve-check-map.conf was not part of spdx-3.0 backport, closest one available (backported-patch) was implemented. Signed-off-by: Peter Marko Signed-off-by: Steve Sakoman --- meta/lib/oe/spdx30_tasks.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/meta/lib/oe/spdx30_tasks.py b/meta/lib/oe/spdx30_tasks.py index 6b0aa137c4..8115088ab8 100644 --- a/meta/lib/oe/spdx30_tasks.py +++ b/meta/lib/oe/spdx30_tasks.py @@ -503,7 +503,13 @@ def create_spdx(d): if include_vex != "none": patched_cves = oe.cve_check.get_patched_cves(d) for cve_id in patched_cves: - mapping, detail, description = oe.cve_check.decode_cve_status(d, cve_id) + # decode_cve_status is decoding CVE_STATUS, so patch files need to be hardcoded + if cve_id in (d.getVarFlags("CVE_STATUS") or {}): + mapping, detail, description = oe.cve_check.decode_cve_status(d, cve_id) + else: + mapping = "Patched" + detail = "backported-patch" # fix-file-included is not available in scarthgap + description = None if not mapping or not detail: bb.warn(f"Skipping {cve_id} — missing or unknown CVE status") From patchwork Sat Nov 22 22:14:08 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75224 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 B36C8CFD2FF for ; Sat, 22 Nov 2025 22:14:43 +0000 (UTC) Received: from mail-pl1-f177.google.com (mail-pl1-f177.google.com [209.85.214.177]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.3744.1763849677562813380 for ; Sat, 22 Nov 2025 14:14:37 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=Rm7y8BdN; spf=softfail (domain: sakoman.com, ip: 209.85.214.177, mailfrom: steve@sakoman.com) Received: by mail-pl1-f177.google.com with SMTP id d9443c01a7336-29806bd47b5so19265825ad.3 for ; Sat, 22 Nov 2025 14:14:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849677; x=1764454477; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=U4KHufZ11gDbUMpOjLLwT4JzLv3M7MYiGrj5xrheH9c=; b=Rm7y8BdN1zB6yTYmi3ph0/KLOtzMhqRZiyMjfbyDf5m7Tm7hPzC0E3Fx+vMNSlPSz5 dZYXLFJmvcwAqdzk8TVhP7W+Mz698NzjisB3laeXBDfcnao1MacmtYWNUV+9SpHgarin NCeJsDDnEDjOIpBq6s9MDbRXQzUX4+y0uHKduwqni3zecxMjAnz8/pZBq279KJyqnRqg sucaXtyGmZ1IdVeasjWfRGGnbcTCQGzabQG71TaGt9pOva404KsAy2fi58ZmRAie6BDD nt6/pOFcFre3zw7RzPvJkkuPdYzUO/D0gnPkkcYb7h5k52x+a2CdnX1dcDergO6vikGC 2Inw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849677; x=1764454477; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=U4KHufZ11gDbUMpOjLLwT4JzLv3M7MYiGrj5xrheH9c=; b=j+C6dmDNVvrw4QYO518xU3cVP1uFIs1U8VGT8NB44PK3QzfpEe3XyHCQMATACeNjci qcK4eCLHRacIuLwiTyspDgwvVu2dgDCSZFROyYe2NHdV7vsCVmuDjSHGNJ+TEWafQLj9 A9BNwyhtAFxE7VODytSnjSimNCVqjGhiKARy+nZCtI86pxGM3MFsHfC6tesPeJbDIvk/ uzpw8e7Bo27K93NQ9zA/tcAY+OlCJERjxD3da8hwC3TYk+VlglYmyR32A0AX8zHPmxTa 9JYhJR7o+3miIp0LUIvbswqW4gFM9UxxteFR+E0snzU4FiECJ83RzQPFhvvO47FnCkht fsOg== X-Gm-Message-State: AOJu0YyXYuvyMJ84onlKJCKDm28sEeTLGZvdCg6PpEniC617GVQSBTD3 PHuuwxkdzpGxjTyajWL5LT1xpq7RFOailkJyeAZ1rjMeZlvBIwWYNLXwocZsw2Vzy8BF/mkgn1e +1O4Z X-Gm-Gg: ASbGncsi6qrBOVNigOibwxf4JeLG9jT5BtM9jcmM7ROBoUxEkW+YhBoAXIxIKiKynnj bbYlw52a/Pq/GnKb92Jya0k1RbasKEkl1QfDjsrz1FJO+mCYG6jCcKsfgu7WH3PCkI4oVZpMlOo sn84Xfn54eCQO+uYh5jcyYEiwZAeEvUVAvg6K5V1vcfzC92V01EXaKaXEZuZLmvrq8SKZJa5Lzm 1BiOg0o87IeWImzN3GQWwKLUVWS7BeVelEZd9rCOFYZZk2sugYpPC2VJVtLFIaHc4T2pweyhxYl hjgztdAvr1c+QLYhnRB68uloP9EBjtihepHWSAP3Ib0mDJhHE7HZcywKbdJ3rjCeJ4vmMF+guLS qJ2ZkUX3+9HSAkZi31JU2TDdpxYww7z+AubaQEzb7OlAMS1nKaUrT+J0Mn6vCdu8aIc0RfHJ1Ze hSPg== X-Google-Smtp-Source: AGHT+IF9jQ1PDnFyfYRASZf3tyai1hgFAD9EFIBrI0KVqG7Qhw6AIbevWzsMvwkjKYXLFhvnB24k7Q== X-Received: by 2002:a17:90b:2b50:b0:343:653d:31c with SMTP id 98e67ed59e1d1-34733e4cb69mr5948319a91.5.1763849676758; Sat, 22 Nov 2025 14:14:36 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.14.35 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:14:36 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 02/21] spdx30: Provide software_packageUrl field in SPDX 3.0 SBOM Date: Sat, 22 Nov 2025 14:14:08 -0800 Message-ID: <60724efdb3a243bc796b390ad0c478584a0fb7fa.1763849517.git.steve@sakoman.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:14:43 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226700 From: Hongxu Jia Define var-SPDX_PACKAGE_URL to provide software_packageUrl field [1][2] in SPDX 3.0 SBOM, support to override with package name SPDX_PACKAGE_URL: Currently, the format of purl is not defined in Yocto, set empty for now until we have a comprehensive plan for what Yocto purls look like. But users could customize their own purl by setting var-SPDX_PACKAGE_URL [1] https://spdx.github.io/spdx-spec/v3.0.1/model/Software/Properties/packageUrl/ [2] https://spdx.github.io/spdx-spec/v3.0.1/annexes/pkg-url-specification/ (From OE-Core rev: c8e6953a0b6f59ffca994c440069db39e60b12d2) Signed-off-by: Hongxu Jia Signed-off-by: Mathieu Dubois-Briand Signed-off-by: Richard Purdie Signed-off-by: Peter Marko Signed-off-by: Steve Sakoman --- meta/classes/create-spdx-3.0.bbclass | 5 +++++ meta/lib/oe/spdx30_tasks.py | 8 ++++++++ 2 files changed, 13 insertions(+) diff --git a/meta/classes/create-spdx-3.0.bbclass b/meta/classes/create-spdx-3.0.bbclass index 044517d9f7..c0a5436ad6 100644 --- a/meta/classes/create-spdx-3.0.bbclass +++ b/meta/classes/create-spdx-3.0.bbclass @@ -117,6 +117,11 @@ SPDX_PACKAGE_VERSION ??= "${PV}" SPDX_PACKAGE_VERSION[doc] = "The version of a package, software_packageVersion \ in software_Package" +SPDX_PACKAGE_URL ??= "" +SPDX_PACKAGE_URL[doc] = "Provides a place for the SPDX data creator to record \ +the package URL string (in accordance with the Package URL specification) for \ +a software Package." + IMAGE_CLASSES:append = " create-spdx-image-3.0" SDK_CLASSES += "create-spdx-sdk-3.0" diff --git a/meta/lib/oe/spdx30_tasks.py b/meta/lib/oe/spdx30_tasks.py index 8115088ab8..a2d316301f 100644 --- a/meta/lib/oe/spdx30_tasks.py +++ b/meta/lib/oe/spdx30_tasks.py @@ -632,6 +632,14 @@ def create_spdx(d): set_var_field("SUMMARY", spdx_package, "summary", package=package) set_var_field("DESCRIPTION", spdx_package, "description", package=package) + if d.getVar("SPDX_PACKAGE_URL:%s" % package) or d.getVar("SPDX_PACKAGE_URL"): + set_var_field( + "SPDX_PACKAGE_URL", + spdx_package, + "software_packageUrl", + package=package + ) + pkg_objset.new_scoped_relationship( [oe.sbom30.get_element_link_id(build)], oe.spdx30.RelationshipType.hasOutput, From patchwork Sat Nov 22 22:14:09 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75222 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 A2BAACFD2F9 for ; Sat, 22 Nov 2025 22:14:43 +0000 (UTC) Received: from mail-pl1-f171.google.com (mail-pl1-f171.google.com [209.85.214.171]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.3747.1763849680996138624 for ; Sat, 22 Nov 2025 14:14:41 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=2UxcHayS; spf=softfail (domain: sakoman.com, ip: 209.85.214.171, mailfrom: steve@sakoman.com) Received: by mail-pl1-f171.google.com with SMTP id d9443c01a7336-297ef378069so28460855ad.3 for ; Sat, 22 Nov 2025 14:14:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849678; x=1764454478; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=qemn87Sd+YJW+tsT1Rm60an8k4/9528uHl8OMAIFFiw=; b=2UxcHaySWQsB6rVEikj2jLPo0kbadHoYWWqJmfyb7b1ckarW4p5zL4tvKzjM7i7nds UA/QI3XnlU53RlavaF+9sbGzJsLaT6Pnn4yl7QaUomdMVByoojYrb3XevROTtU/FKq9Y Vd5KLFgKh4mFYwGQBnf2H/2eB24IzNQVd/FVePG3YPiWodE6Tskyu2g9tN5YoSzgzn0p tgCSCrNNvHg5Fm3OR6KQwHlpYsMx33Yd43v39dg4EqRZjch4quTIgiNQJVVLC7IMc58p cT+9Acu7snQOg2AdBkS9xBaLm2oWgkX2SjMuaO2NUEFf2PayJ9u2bZm5GWid4dbQdOBO ZkQg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849678; x=1764454478; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=qemn87Sd+YJW+tsT1Rm60an8k4/9528uHl8OMAIFFiw=; b=kYez1/mrE3j1t15mb2brNo5SHzZj+FxAunKEOsOG0StcdNWHCatNShyHirRRfa7siO yOlSry9Jwx4DksU3RpKeifl0OGmJZTvgkCPtCEbMPEU5pug/vDQOaVeSmz2exadYR4xW HV9fJPacgOrO+xPOOxHqmxJ+rcgNqeeako6LbxodhCvzAsTz0KFtuPrenqHFqjvxsXld xo4+pun4uZt/D1Vhpapazcx5YPz12ay/FOXugce4Vggl/7Wft72vxY+/CgNOoIxTrpGU GXl0YZ8Dh6QiDybUkgXtdQI1diFbSVgn9BCb8Cl79pb66GtZCeMENEvl5rVRnqDZPfmU pKFA== X-Gm-Message-State: AOJu0Ywq6YGY/41aCfcfi24LFyDDALUmH85sapbfQ/uBkMO0SaqweS3g uw+grsLHVqlAemBfKHULRtiEiQ8fGRMzQCONWccUcKlY8DUB9u2vllh4imxB4q3VQw1BP2fmHSE UbIia X-Gm-Gg: ASbGncs3ImGINQZt3SoAUqRxnhwGbJ+DYdpDF/m6bZnw9yI3boYzpABczH3aM5UXP6c lWQEaK+gSYIQR95Iq2uPqxHMnIiweOviOYpNxbjU3GwcFGqjEneDFWr5JkPwJPO3R2w33ppj7Pt AfHDVZezbxob1LYEdM8ai8Pl9Eb0KCtjDm2pxa67WRoBiKsNDEI1HyhiGjE2HCEJ9HKS5TtS+Ox 0pKPW9Hdz+sY3JHHWKMvQKfWBrFeB++jMX/EociVQ218/RjLz0c2a7PVhIQpNz/CrVXreyJjz7r S/aPGZUNXjquVlUSP8ukXYUwKVWd3a8NQDn/zwYOcb0RkTt3wgEab42LKw3XQi2ry8JqKg5UNUu jVF/RnY7I630rfa4d9wx2AE609s89euLl/07fa3t+Ul+hg8Fw3V1l13lBKZ4FqpNBsMplLaqBq3 nXig== X-Google-Smtp-Source: AGHT+IHZ90nEOmXBcj6e3a1S1xpNYAYeBgA1okG+tSaI+EicYd5n2pkE4YrATF6Lz3PkxYt7TP+P0g== X-Received: by 2002:a17:90b:58ab:b0:341:88c9:ca62 with SMTP id 98e67ed59e1d1-34733f2a45bmr5232845a91.31.1763849678264; Sat, 22 Nov 2025 14:14:38 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.14.37 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:14:37 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 03/21] sqlite3: patch CVE-2025-7709 Date: Sat, 22 Nov 2025 14:14:09 -0800 Message-ID: X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:14:43 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226702 From: Hugo SIMELIERE Pick commit used in debian patch https://git.launchpad.net/ubuntu/+source/sqlite3/commit/?id=9a309a50fa99e3b69623894bfd7d1f84d9fab33c Upstream-Status: Backport [https://github.com/sqlite/sqlite/commit/192d0ff8ccf0bf55776a5930cdc64e25f87299d6] Signed-off-by: Bruno VERNAY Signed-off-by: Hugo SIMELIERE Signed-off-by: Steve Sakoman --- .../sqlite/sqlite3/CVE-2025-7709.patch | 33 +++++++++++++++++++ meta/recipes-support/sqlite/sqlite3_3.45.3.bb | 1 + 2 files changed, 34 insertions(+) create mode 100644 meta/recipes-support/sqlite/sqlite3/CVE-2025-7709.patch diff --git a/meta/recipes-support/sqlite/sqlite3/CVE-2025-7709.patch b/meta/recipes-support/sqlite/sqlite3/CVE-2025-7709.patch new file mode 100644 index 0000000000..820262881f --- /dev/null +++ b/meta/recipes-support/sqlite/sqlite3/CVE-2025-7709.patch @@ -0,0 +1,33 @@ +From a7ed2fcba8ef1df4bcd846d895469ca72542be07 Mon Sep 17 00:00:00 2001 +From: Hugo SIMELIERE +Date: Fri, 14 Nov 2025 15:31:17 +0100 +Subject: [PATCH] Optimize allocation of large tombstone arrays in fts5. + +FossilOrigin-Name: 0fcc3cbdfa21adf97aed01fa76991cccf9380e2755b0182a9e2c94e3c8fb38d7 + +CVE: CVE-2025-7709 +Upstream-Status: Backport [https://github.com/sqlite/sqlite/commit/192d0ff8ccf0bf55776a5930cdc64e25f87299d6] +Signed-off-by: Hugo SIMELIERE +--- + sqlite3.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/sqlite3.c b/sqlite3.c +index 1ee8de4..43f59e2 100644 +--- a/sqlite3.c ++++ b/sqlite3.c +@@ -240724,9 +240724,9 @@ static void fts5SegIterSetNext(Fts5Index *p, Fts5SegIter *pIter){ + ** leave an error in the Fts5Index object. + */ + static void fts5SegIterAllocTombstone(Fts5Index *p, Fts5SegIter *pIter){ +- const int nTomb = pIter->pSeg->nPgTombstone; ++ const i64 nTomb = (i64)pIter->pSeg->nPgTombstone; + if( nTomb>0 ){ +- int nByte = nTomb * sizeof(Fts5Data*) + sizeof(Fts5TombstoneArray); ++ i64 nByte = nTomb * sizeof(Fts5Data*) + sizeof(Fts5TombstoneArray); + Fts5TombstoneArray *pNew; + pNew = (Fts5TombstoneArray*)sqlite3Fts5MallocZero(&p->rc, nByte); + if( pNew ){ +-- +2.43.0 + diff --git a/meta/recipes-support/sqlite/sqlite3_3.45.3.bb b/meta/recipes-support/sqlite/sqlite3_3.45.3.bb index 60a8f1449b..05bfaac1af 100644 --- a/meta/recipes-support/sqlite/sqlite3_3.45.3.bb +++ b/meta/recipes-support/sqlite/sqlite3_3.45.3.bb @@ -7,6 +7,7 @@ SRC_URI = "http://www.sqlite.org/2024/sqlite-autoconf-${SQLITE_PV}.tar.gz \ file://CVE-2025-3277.patch \ file://CVE-2025-29088.patch \ file://CVE-2025-6965.patch \ + file://CVE-2025-7709.patch \ " SRC_URI[sha256sum] = "b2809ca53124c19c60f42bf627736eae011afdcc205bb48270a5ee9a38191531" From patchwork Sat Nov 22 22:14:10 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75223 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 B02D6CFD301 for ; Sat, 22 Nov 2025 22:14:43 +0000 (UTC) Received: from mail-pj1-f51.google.com (mail-pj1-f51.google.com [209.85.216.51]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.3746.1763849680934568740 for ; Sat, 22 Nov 2025 14:14:41 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=z8U/oKna; spf=softfail (domain: sakoman.com, ip: 209.85.216.51, mailfrom: steve@sakoman.com) Received: by mail-pj1-f51.google.com with SMTP id 98e67ed59e1d1-343f35d0f99so2605766a91.0 for ; Sat, 22 Nov 2025 14:14:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849680; x=1764454480; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=wTpTa/2AILc3xxtKO5TTYvCq4xhh+HEXVGRI0v41INs=; b=z8U/oKnamgqyEyenSJfUK68EQXCGu14TS1Gw/Y/EBFKUyd8RBxr9pM8fOKlF5hHiLW 7rLLBhzPxKzlRQCgMsUL/mCUPd/p8EtX3GPeKVl6wui7FckzSY/gL2uvpPi9bG2upOgN 4sYN087hor1LFiJx4kAh9n4FrLaDlKUDxFI4/qTBDO0LxBvfnihs7uuQV5z/zH7OY569 8gZlrM/ScJkTRTF8noSzNhQhxFGkwUZ44c2roj5yIkFVhxxV8qRs97vmioqVQfBA5wpY sw7CwGcWhfJxMRO7wZpWX9CPBZyWWVQRlwBVCZSWgal62WnJfuTyfc58hYsWNUVSkfCs C3Kw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849680; x=1764454480; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=wTpTa/2AILc3xxtKO5TTYvCq4xhh+HEXVGRI0v41INs=; b=RDxzCFp5BFeiLNpfRlrIB8Pc6sY5SZEquGSHwqc78OWVlgvH/n8U6jSbEWKElZvFA/ Sppx/hDS3eLA3HfJmDMBl/9yNTsnNOB1svBzTJlZf8QzZUBDXkDNceit2L+G9bzoC/Hn mEzff5HXzrUqeACIWcspWfWRh71M7j3Br8/k+neqwpPhA7LwRlCPUNxBITJRNy+tH6bK tE7di/Q/RKgEmmVPN8nztEjlxBGjZUzwhz6I1jTWSFTs7cfwiXKVS82OFRJp7VYtp6pp Iis4jmiVKq/nI0AuXpg+fT7ryUwBePujCjwtSvAa4y2zdSoIXwEaSjaby6xy+U6OPWAc 5zlg== X-Gm-Message-State: AOJu0YxANWvTRiXbBUpXQY6U/H8BncYnj2HJhVKHmNSBphkCcaXt239u m9rN8ZhBJXfC1qUEC8jFAiPMoEablFjUDabXY+I+8zTlAcCgGBNiF/LI9rdI0QAcM4HKs8M+JTQ kvWpo X-Gm-Gg: ASbGncvmLEJtfQNXyFXsn8mVCr1Fc0DbqRkmtx7W8cb5vTYVmpfLokYUVOU9oQac67R qG3DoqKz6/EVoiBkAcHjCrLcg07RgT3PsFUFGlGVeEKc0AtIlQBrVTZHKH1SZ09wMWp793kFA/Y t9u21K2K2zOkMBVD4lWjf6vSbQpPRPe+ejirVp9TtB95dxVoW7JQE7PcODhbeKuBOzn/lD6IQ+r jMI+Pvm4UK+8fBvEs7IHpzgC0w8uE0TsCBV+/xYRUkfN+9ykrUefAw9myL5No6ApYY9htr/fNkT k2aans4JGYENP4wjjQi2nKsoj+YrXdFaHLJruL59ZguUWl9GjTfI4mBA2pOqZqfo9hpR900xS+I OvxK5QZlAcomdkCm1Q+XSY2vwlgjC6bqvv/strzf5Tjd6ZD2mRR6XrXKvm0BqULSunNQvd+kFvh FOZw== X-Google-Smtp-Source: AGHT+IGdAB8umAEoHoghGYlIf+sslQcDsLB8+ZvLTu+EcFaQ8cpyGJAf9ivcPs2Se9MM9Ho/i9OudA== X-Received: by 2002:a17:90b:5112:b0:33b:a5d8:f198 with SMTP id 98e67ed59e1d1-34733f3b29emr6743980a91.25.1763849680084; Sat, 22 Nov 2025 14:14:40 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.14.39 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:14:39 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 04/21] xserver-xorg: remove redundant patch Date: Sat, 22 Nov 2025 14:14:10 -0800 Message-ID: X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:14:43 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226701 From: Ross Burton The underlying issue with -fno-common was resolved upstream in xserver 21.1.0 onwards[1]. [1] xserver 0148a15da ("compiler.h: don't define inb/outb and friends on mips") (From OE-Core rev: 74b77ee90efd50a703af76769fac66a0f7c394ca) Signed-off-by: Ross Burton Signed-off-by: Mathieu Dubois-Briand Signed-off-by: Richard Purdie Signed-off-by: Yogita Urade Signed-off-by: Steve Sakoman --- ...-duplicate-definitions-of-IOPortBase.patch | 28 ------------------- .../xorg-xserver/xserver-xorg_21.1.18.bb | 4 +-- 2 files changed, 1 insertion(+), 31 deletions(-) delete mode 100644 meta/recipes-graphics/xorg-xserver/xserver-xorg/0001-Avoid-duplicate-definitions-of-IOPortBase.patch diff --git a/meta/recipes-graphics/xorg-xserver/xserver-xorg/0001-Avoid-duplicate-definitions-of-IOPortBase.patch b/meta/recipes-graphics/xorg-xserver/xserver-xorg/0001-Avoid-duplicate-definitions-of-IOPortBase.patch deleted file mode 100644 index e9cbc9b4da..0000000000 --- a/meta/recipes-graphics/xorg-xserver/xserver-xorg/0001-Avoid-duplicate-definitions-of-IOPortBase.patch +++ /dev/null @@ -1,28 +0,0 @@ -From cedc797e1a0850039a25b7e387b342e54fffcc97 Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Mon, 17 Aug 2020 10:50:51 -0700 -Subject: [PATCH] Avoid duplicate definitions of IOPortBase - -This fixed build with gcc10/-fno-common - -Fixes -compiler.h:528: multiple definition of `IOPortBase'; - -Upstream-Status: Pending -Signed-off-by: Khem Raj ---- - hw/xfree86/os-support/linux/lnx_video.c | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/hw/xfree86/os-support/linux/lnx_video.c b/hw/xfree86/os-support/linux/lnx_video.c -index fd83022..1d0d96e 100644 ---- a/hw/xfree86/os-support/linux/lnx_video.c -+++ b/hw/xfree86/os-support/linux/lnx_video.c -@@ -78,6 +78,7 @@ xf86OSInitVidMem(VidMemInfoPtr pVidMem) - /***************************************************************************/ - /* I/O Permissions section */ - /***************************************************************************/ -+_X_EXPORT unsigned int IOPortBase; /* Memory mapped I/O port area */ - - #if defined(__powerpc__) - volatile unsigned char *ioBase = NULL; diff --git a/meta/recipes-graphics/xorg-xserver/xserver-xorg_21.1.18.bb b/meta/recipes-graphics/xorg-xserver/xserver-xorg_21.1.18.bb index 14c45be432..1e341553f9 100644 --- a/meta/recipes-graphics/xorg-xserver/xserver-xorg_21.1.18.bb +++ b/meta/recipes-graphics/xorg-xserver/xserver-xorg_21.1.18.bb @@ -1,8 +1,6 @@ require xserver-xorg.inc -SRC_URI += "file://0001-xf86pciBus.c-use-Intel-ddx-only-for-pre-gen4-hardwar.patch \ - file://0001-Avoid-duplicate-definitions-of-IOPortBase.patch \ - " +SRC_URI += "file://0001-xf86pciBus.c-use-Intel-ddx-only-for-pre-gen4-hardwar.patch" SRC_URI[sha256sum] = "c878d1930d87725d4a5bf498c24f4be8130d5b2646a9fd0f2994deff90116352" # These extensions are now integrated into the server, so declare the migration From patchwork Sat Nov 22 22:14:11 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75226 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 A53AECFD2FE for ; Sat, 22 Nov 2025 22:14:43 +0000 (UTC) Received: from mail-pl1-f180.google.com (mail-pl1-f180.google.com [209.85.214.180]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.3748.1763849683078378850 for ; Sat, 22 Nov 2025 14:14:43 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=HLg7WIbt; spf=softfail (domain: sakoman.com, ip: 209.85.214.180, mailfrom: steve@sakoman.com) Received: by mail-pl1-f180.google.com with SMTP id d9443c01a7336-298144fb9bcso34304165ad.0 for ; Sat, 22 Nov 2025 14:14:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849682; x=1764454482; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=1I8WV5B30Z8obBFZx0ArEgedYAMsAEsibCKovYo65To=; b=HLg7WIbtYDKvjr6HR8O6h8/OIZ+/2+q2Bf3jEMERTq91IyA2MVc5QU9MV1hTlBUPnV lDsHxBk4XvEgu9R2LqyKgG7APwYb2oCc1hkomEH4pyS8znneF42rAAuSPtWv0jG6xdWl OQhm8SD7qzpBht6SyO7v4u8tqdVQDSL59fhG7xzp++UZVkNcGjlhHLszVXvNZbGs7mz5 gWPRxks5og7LhPNOKKEkFsSjXDhJqk0sdr9GtlhzI9wfrUA0Umrr4mk/tCY7DYJOVcFD weu10JHKRUDYAQA5+5Zw8hi+GAy3FK6YvzH187ot2BlROLFjqLFVSOY2EDYrdhZ18gNG WlAQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849682; x=1764454482; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=1I8WV5B30Z8obBFZx0ArEgedYAMsAEsibCKovYo65To=; b=hkkYTrYk0aAQqlveZIx+aHmrvINloy7yuWl2kehtvh4cFmCGL9/otzFkSeK/dmDGY8 w+8o/2MCPMrHBvdG+Q21Gf6fi5XmTYF70raOqwcOAsF4GuiQY2PPAUVSARO6Cl4DF/eM pQ7rBkTRLwCForPDUsqBn/pUUIpJml9ODB4gmvEM2Sb0lH9J60nfOWsuF1W3ZnbLibgw uh6Vzhk5Zn61Zy2ts8AAtiyfw7CLede1ZIv5V1ijjj2hE5lxy07e18RYMGBigFy9A9Mv P/FhN3x9UNFe3A0RniPe1FOUD/Uew3AhmITyfle7+r5yPdf16tIuYA/I0qXFSndLHdL0 sh/Q== X-Gm-Message-State: AOJu0Yx6gkHYubhKq1Fyu9DCk191XuMj8Vm+8VePeELAsOAoSBB31bUg f+xgTcFK/eGHlgf3HMw3jlRkIoeWtXcuvNYDw2B+m3PCZcYMKhyTHWL2pZLV17nyNFtLjTldAYL L+4TD X-Gm-Gg: ASbGncs2P9jUymsxyo7olb1XfRtHsWZfpLBydBntCPuLWGWMo8zn/97PA2M4TuPPDfH M2kfPwWi+s8hwcZKbGHGUihe49ox5fpD1NgJG53VaNskn+4lgDDLt9q9uTK1SpzVqoZpnyoB7Y0 OtbyyrfpX7HlI68ympiEe+qyqfvquhatJYRPY0FWGeVkgUX7PnOQQF12/U2ReFGrXNLvZArxggg Yqc1wt+DN7KFRanQ0sD/ZvPgh01S0yUrrJ85L/eyD08t/chogviLHVhHk8zlXK3VPTq2CpXFf9o u3HYW7Izui+Pq480RgqCU4eZfV/jRqv+DvU3wlRE73pn7y8pUEoTvzXU0tEOYGYT3HRn+nrXiYg kRKMsPlJP2s88V10iZFvRFNPnro7/lHHYrH5iYfbSUClSARjOvSEe9owPVkxuMhUx8J7xuK2sCI 7gFg== X-Google-Smtp-Source: AGHT+IF+dSi119IblLCg8bud+Zn6TrNVIf4vOfjbs8UjNCxbwL/IUWFhfeH/mzZWzSQaR9RtEkh/lA== X-Received: by 2002:a17:90b:5291:b0:340:f05a:3ed3 with SMTP id 98e67ed59e1d1-34733f19bbamr8285548a91.17.1763849682178; Sat, 22 Nov 2025 14:14:42 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.14.41 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:14:41 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 05/21] xserver-xorg: fix CVE-2025-62229 CVE-2025-62230 CVE-2025-62231 Date: Sat, 22 Nov 2025 14:14:11 -0800 Message-ID: X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:14:43 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226703 From: Ross Burton >From https://lists.x.org/archives/xorg-announce/2025-October/003635.html: 1) CVE-2025-62229: Use-after-free in XPresentNotify structures creation Using the X11 Present extension, when processing and adding the notifications after presenting a pixmap, if an error occurs, a dangling pointer may be left in the error code path of the function causing a use-after-free when eventually destroying the notification structures later. Introduced in: Xorg 1.15 Fixed in: xorg-server-21.1.19 and xwayland-24.1.9 Fix: https://gitlab.freedesktop.org/xorg/xserver/-/commit/5a4286b1 Found by: Jan-Niklas Sohn working with Trend Micro Zero Day Initiative. 2) CVE-2025-62230: Use-after-free in Xkb client resource removal When removing the Xkb resources for a client, the function XkbRemoveResourceClient() will free the XkbInterest data associated with the device, but not the resource associated with it. As a result, when the client terminates, the resource delete function triggers a use-after-free. Introduced in: X11R6 Fixed in: xorg-server-21.1.19 and xwayland-24.1.9 Fix: https://gitlab.freedesktop.org/xorg/xserver/-/commit/99790a2c https://gitlab.freedesktop.org/xorg/xserver/-/commit/10c94238 Found by: Jan-Niklas Sohn working with Trend Micro Zero Day Initiative. 3) CVE-2025-62231: Value overflow in Xkb extension XkbSetCompatMap() The XkbCompatMap structure stores some of its values using an unsigned short, but fails to check whether the sum of the input data might overflow the maximum unsigned short value. Introduced in: X11R6 Fixed in: xorg-server-21.1.19 and xwayland-24.1.9 Fix: https://gitlab.freedesktop.org/xorg/xserver/-/commit/475d9f49 Found by: Jan-Niklas Sohn working with Trend Micro Zero Day Initiative. (From OE-Core rev: 50b9c34ba932761fab9035a54e58466d72b097bf) Signed-off-by: Ross Burton Signed-off-by: Mathieu Dubois-Briand Signed-off-by: Richard Purdie Signed-off-by: Yogita Urade Signed-off-by: Steve Sakoman --- ...after-free-in-present_create_notifie.patch | 91 ++++++++++++++++++ ...ke-the-RT_XKBCLIENT-resource-private.patch | 63 +++++++++++++ ...KB-resource-when-freeing-XkbInterest.patch | 92 +++++++++++++++++++ ...-Prevent-overflow-in-XkbSetCompatMap.patch | 53 +++++++++++ .../xorg-xserver/xserver-xorg_21.1.18.bb | 7 +- 5 files changed, 305 insertions(+), 1 deletion(-) create mode 100644 meta/recipes-graphics/xorg-xserver/xserver-xorg/0001-present-Fix-use-after-free-in-present_create_notifie.patch create mode 100644 meta/recipes-graphics/xorg-xserver/xserver-xorg/0002-xkb-Make-the-RT_XKBCLIENT-resource-private.patch create mode 100644 meta/recipes-graphics/xorg-xserver/xserver-xorg/0003-xkb-Free-the-XKB-resource-when-freeing-XkbInterest.patch create mode 100644 meta/recipes-graphics/xorg-xserver/xserver-xorg/0004-xkb-Prevent-overflow-in-XkbSetCompatMap.patch diff --git a/meta/recipes-graphics/xorg-xserver/xserver-xorg/0001-present-Fix-use-after-free-in-present_create_notifie.patch b/meta/recipes-graphics/xorg-xserver/xserver-xorg/0001-present-Fix-use-after-free-in-present_create_notifie.patch new file mode 100644 index 0000000000..fa8bc542d8 --- /dev/null +++ b/meta/recipes-graphics/xorg-xserver/xserver-xorg/0001-present-Fix-use-after-free-in-present_create_notifie.patch @@ -0,0 +1,91 @@ +From 359c9c0478406fe00e0d4c5d52bd9bf8c2ca4081 Mon Sep 17 00:00:00 2001 +From: Olivier Fourdan +Date: Wed, 2 Jul 2025 09:46:22 +0200 +Subject: [PATCH 1/4] present: Fix use-after-free in present_create_notifies() + +Using the Present extension, if an error occurs while processing and +adding the notifications after presenting a pixmap, the function +present_create_notifies() will clean up and remove the notifications +it added. + +However, there are two different code paths that can lead to an error +creating the notify, one being before the notify is being added to the +list, and another one after the notify is added. + +When the error occurs before it's been added, it removes the elements up +to the last added element, instead of the actual number of elements +which were added. + +As a result, in case of error, as with an invalid window for example, it +leaves a dangling pointer to the last element, leading to a use after +free case later: + + | Invalid write of size 8 + | at 0x5361D5: present_clear_window_notifies (present_notify.c:42) + | by 0x534A56: present_destroy_window (present_screen.c:107) + | by 0x41E441: xwl_destroy_window (xwayland-window.c:1959) + | by 0x4F9EC9: compDestroyWindow (compwindow.c:622) + | by 0x51EAC4: damageDestroyWindow (damage.c:1592) + | by 0x4FDC29: DbeDestroyWindow (dbe.c:1291) + | by 0x4EAC55: FreeWindowResources (window.c:1023) + | by 0x4EAF59: DeleteWindow (window.c:1091) + | by 0x4DE59A: doFreeResource (resource.c:890) + | by 0x4DEFB2: FreeClientResources (resource.c:1156) + | by 0x4A9AFB: CloseDownClient (dispatch.c:3567) + | by 0x5DCC78: ClientReady (connection.c:603) + | Address 0x16126200 is 16 bytes inside a block of size 2,048 free'd + | at 0x4841E43: free (vg_replace_malloc.c:989) + | by 0x5363DD: present_destroy_notifies (present_notify.c:111) + | by 0x53638D: present_create_notifies (present_notify.c:100) + | by 0x5368E9: proc_present_pixmap_common (present_request.c:164) + | by 0x536A7D: proc_present_pixmap (present_request.c:189) + | by 0x536FA9: proc_present_dispatch (present_request.c:337) + | by 0x4A1E4E: Dispatch (dispatch.c:561) + | by 0x4B00F1: dix_main (main.c:284) + | by 0x42879D: main (stubmain.c:34) + | Block was alloc'd at + | at 0x48463F3: calloc (vg_replace_malloc.c:1675) + | by 0x5362A1: present_create_notifies (present_notify.c:81) + | by 0x5368E9: proc_present_pixmap_common (present_request.c:164) + | by 0x536A7D: proc_present_pixmap (present_request.c:189) + | by 0x536FA9: proc_present_dispatch (present_request.c:337) + | by 0x4A1E4E: Dispatch (dispatch.c:561) + | by 0x4B00F1: dix_main (main.c:284) + | by 0x42879D: main (stubmain.c:34) + +To fix the issue, count and remove the actual number of notify elements +added in case of error. + +CVE-2025-62229, ZDI-CAN-27238 + +This vulnerability was discovered by: +Jan-Niklas Sohn working with Trend Micro Zero Day Initiative + +Signed-off-by: Olivier Fourdan +(cherry picked from commit 5a4286b13f631b66c20f5bc8db7b68211dcbd1d0) + +Part-of: + +CVE: CVE-2025-62229 +Upstream-Status: Backport +Signed-off-by: Ross Burton +--- + present/present_notify.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/present/present_notify.c b/present/present_notify.c +index 445954998..00b3b68bd 100644 +--- a/present/present_notify.c ++++ b/present/present_notify.c +@@ -90,7 +90,7 @@ present_create_notifies(ClientPtr client, int num_notifies, xPresentNotify *x_no + if (status != Success) + goto bail; + +- added = i; ++ added++; + } + return Success; + +-- +2.43.0 + diff --git a/meta/recipes-graphics/xorg-xserver/xserver-xorg/0002-xkb-Make-the-RT_XKBCLIENT-resource-private.patch b/meta/recipes-graphics/xorg-xserver/xserver-xorg/0002-xkb-Make-the-RT_XKBCLIENT-resource-private.patch new file mode 100644 index 0000000000..ed25f4b58e --- /dev/null +++ b/meta/recipes-graphics/xorg-xserver/xserver-xorg/0002-xkb-Make-the-RT_XKBCLIENT-resource-private.patch @@ -0,0 +1,63 @@ +From a3d5c76ee8925ef9846c72e2327674b84e3fcdb3 Mon Sep 17 00:00:00 2001 +From: Olivier Fourdan +Date: Wed, 10 Sep 2025 15:55:06 +0200 +Subject: [PATCH 2/4] xkb: Make the RT_XKBCLIENT resource private +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Currently, the resource in only available to the xkb.c source file. + +In preparation for the next commit, to be able to free the resources +from XkbRemoveResourceClient(), make that variable private instead. + +This is related to: + +CVE-2025-62230, ZDI-CAN-27545 + +This vulnerability was discovered by: +Jan-Niklas Sohn working with Trend Micro Zero Day Initiative + +Signed-off-by: Olivier Fourdan +Reviewed-by: Michel Dänzer +(cherry picked from commit 99790a2c9205a52fbbec01f21a92c9b7f4ed1d8f) + +Part-of: + +CVE: CVE-2025-62230 +Upstream-Status: Backport +Signed-off-by: Ross Burton +--- + include/xkbsrv.h | 2 ++ + xkb/xkb.c | 2 +- + 2 files changed, 3 insertions(+), 1 deletion(-) + +diff --git a/include/xkbsrv.h b/include/xkbsrv.h +index fbb5427e1..b2766277c 100644 +--- a/include/xkbsrv.h ++++ b/include/xkbsrv.h +@@ -58,6 +58,8 @@ THE USE OR PERFORMANCE OF THIS SOFTWARE. + #include "inputstr.h" + #include "events.h" + ++extern RESTYPE RT_XKBCLIENT; ++ + typedef struct _XkbInterest { + DeviceIntPtr dev; + ClientPtr client; +diff --git a/xkb/xkb.c b/xkb/xkb.c +index 5131bfcdf..26d965d48 100644 +--- a/xkb/xkb.c ++++ b/xkb/xkb.c +@@ -51,7 +51,7 @@ int XkbKeyboardErrorCode; + CARD32 xkbDebugFlags = 0; + static CARD32 xkbDebugCtrls = 0; + +-static RESTYPE RT_XKBCLIENT; ++RESTYPE RT_XKBCLIENT = 0; + + /***====================================================================***/ + +-- +2.43.0 + diff --git a/meta/recipes-graphics/xorg-xserver/xserver-xorg/0003-xkb-Free-the-XKB-resource-when-freeing-XkbInterest.patch b/meta/recipes-graphics/xorg-xserver/xserver-xorg/0003-xkb-Free-the-XKB-resource-when-freeing-XkbInterest.patch new file mode 100644 index 0000000000..f55e3d4126 --- /dev/null +++ b/meta/recipes-graphics/xorg-xserver/xserver-xorg/0003-xkb-Free-the-XKB-resource-when-freeing-XkbInterest.patch @@ -0,0 +1,92 @@ +From 32b12feb6f9f3d32532ff75c7434a7426b85e0c3 Mon Sep 17 00:00:00 2001 +From: Olivier Fourdan +Date: Wed, 10 Sep 2025 15:58:57 +0200 +Subject: [PATCH 3/4] xkb: Free the XKB resource when freeing XkbInterest +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +XkbRemoveResourceClient() would free the XkbInterest data associated +with the device, but not the resource associated with it. + +As a result, when the client terminates, the resource delete function +gets called and accesses already freed memory: + + | Invalid read of size 8 + | at 0x5BC0C0: XkbRemoveResourceClient (xkbEvents.c:1047) + | by 0x5B3391: XkbClientGone (xkb.c:7094) + | by 0x4DF138: doFreeResource (resource.c:890) + | by 0x4DFB50: FreeClientResources (resource.c:1156) + | by 0x4A9A59: CloseDownClient (dispatch.c:3550) + | by 0x5E0A53: ClientReady (connection.c:601) + | by 0x5E4FEF: ospoll_wait (ospoll.c:657) + | by 0x5DC834: WaitForSomething (WaitFor.c:206) + | by 0x4A1BA5: Dispatch (dispatch.c:491) + | by 0x4B0070: dix_main (main.c:277) + | by 0x4285E7: main (stubmain.c:34) + | Address 0x1893e278 is 184 bytes inside a block of size 928 free'd + | at 0x4842E43: free (vg_replace_malloc.c:989) + | by 0x49C1A6: CloseDevice (devices.c:1067) + | by 0x49C522: CloseOneDevice (devices.c:1193) + | by 0x49C6E4: RemoveDevice (devices.c:1244) + | by 0x5873D4: remove_master (xichangehierarchy.c:348) + | by 0x587921: ProcXIChangeHierarchy (xichangehierarchy.c:504) + | by 0x579BF1: ProcIDispatch (extinit.c:390) + | by 0x4A1D85: Dispatch (dispatch.c:551) + | by 0x4B0070: dix_main (main.c:277) + | by 0x4285E7: main (stubmain.c:34) + | Block was alloc'd at + | at 0x48473F3: calloc (vg_replace_malloc.c:1675) + | by 0x49A118: AddInputDevice (devices.c:262) + | by 0x4A0E58: AllocDevicePair (devices.c:2846) + | by 0x5866EE: add_master (xichangehierarchy.c:153) + | by 0x5878C2: ProcXIChangeHierarchy (xichangehierarchy.c:493) + | by 0x579BF1: ProcIDispatch (extinit.c:390) + | by 0x4A1D85: Dispatch (dispatch.c:551) + | by 0x4B0070: dix_main (main.c:277) + | by 0x4285E7: main (stubmain.c:34) + +To avoid that issue, make sure to free the resources when freeing the +device XkbInterest data. + +CVE-2025-62230, ZDI-CAN-27545 + +This vulnerability was discovered by: +Jan-Niklas Sohn working with Trend Micro Zero Day Initiative + +Signed-off-by: Olivier Fourdan +Reviewed-by: Michel Dänzer +(cherry picked from commit 10c94238bdad17c11707e0bdaaa3a9cd54c504be) + +Part-of: + +CVE: CVE-2025-62230 +Upstream-Status: Backport +Signed-off-by: Ross Burton +--- + xkb/xkbEvents.c | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/xkb/xkbEvents.c b/xkb/xkbEvents.c +index 0bbd66186..3d04ecf0c 100644 +--- a/xkb/xkbEvents.c ++++ b/xkb/xkbEvents.c +@@ -1056,6 +1056,7 @@ XkbRemoveResourceClient(DevicePtr inDev, XID id) + autoCtrls = interest->autoCtrls; + autoValues = interest->autoCtrlValues; + client = interest->client; ++ FreeResource(interest->resource, RT_XKBCLIENT); + free(interest); + found = TRUE; + } +@@ -1067,6 +1068,7 @@ XkbRemoveResourceClient(DevicePtr inDev, XID id) + autoCtrls = victim->autoCtrls; + autoValues = victim->autoCtrlValues; + client = victim->client; ++ FreeResource(victim->resource, RT_XKBCLIENT); + free(victim); + found = TRUE; + } +-- +2.43.0 + diff --git a/meta/recipes-graphics/xorg-xserver/xserver-xorg/0004-xkb-Prevent-overflow-in-XkbSetCompatMap.patch b/meta/recipes-graphics/xorg-xserver/xserver-xorg/0004-xkb-Prevent-overflow-in-XkbSetCompatMap.patch new file mode 100644 index 0000000000..5036f0c9f0 --- /dev/null +++ b/meta/recipes-graphics/xorg-xserver/xserver-xorg/0004-xkb-Prevent-overflow-in-XkbSetCompatMap.patch @@ -0,0 +1,53 @@ +From 364f06788f1de4edc0547c7f29d338e6deffc138 Mon Sep 17 00:00:00 2001 +From: Olivier Fourdan +Date: Wed, 10 Sep 2025 16:30:29 +0200 +Subject: [PATCH 4/4] xkb: Prevent overflow in XkbSetCompatMap() +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +The XkbCompatMap structure stores its "num_si" and "size_si" fields +using an unsigned short. + +However, the function _XkbSetCompatMap() will store the sum of the +input data "firstSI" and "nSI" in both XkbCompatMap's "num_si" and +"size_si" without first checking if the sum overflows the maximum +unsigned short value, leading to a possible overflow. + +To avoid the issue, check whether the sum does not exceed the maximum +unsigned short value, or return a "BadValue" error otherwise. + +CVE-2025-62231, ZDI-CAN-27560 + +This vulnerability was discovered by: +Jan-Niklas Sohn working with Trend Micro Zero Day Initiative + +Signed-off-by: Olivier Fourdan +Reviewed-by: Michel Dänzer +(cherry picked from commit 475d9f49acd0e55bc0b089ed77f732ad18585470) + +Part-of: + +CVE: CVE-2025-62231 +Upstream-Status: Backport +Signed-off-by: Ross Burton +--- + xkb/xkb.c | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/xkb/xkb.c b/xkb/xkb.c +index 26d965d48..137d70da2 100644 +--- a/xkb/xkb.c ++++ b/xkb/xkb.c +@@ -2992,6 +2992,8 @@ _XkbSetCompatMap(ClientPtr client, DeviceIntPtr dev, + XkbSymInterpretPtr sym; + unsigned int skipped = 0; + ++ if ((unsigned) (req->firstSI + req->nSI) > USHRT_MAX) ++ return BadValue; + if ((unsigned) (req->firstSI + req->nSI) > compat->size_si) { + compat->num_si = compat->size_si = req->firstSI + req->nSI; + compat->sym_interpret = reallocarray(compat->sym_interpret, +-- +2.43.0 + diff --git a/meta/recipes-graphics/xorg-xserver/xserver-xorg_21.1.18.bb b/meta/recipes-graphics/xorg-xserver/xserver-xorg_21.1.18.bb index 1e341553f9..7f6197a0b4 100644 --- a/meta/recipes-graphics/xorg-xserver/xserver-xorg_21.1.18.bb +++ b/meta/recipes-graphics/xorg-xserver/xserver-xorg_21.1.18.bb @@ -1,6 +1,11 @@ require xserver-xorg.inc -SRC_URI += "file://0001-xf86pciBus.c-use-Intel-ddx-only-for-pre-gen4-hardwar.patch" +SRC_URI += "file://0001-xf86pciBus.c-use-Intel-ddx-only-for-pre-gen4-hardwar.patch \ + file://0001-present-Fix-use-after-free-in-present_create_notifie.patch \ + file://0002-xkb-Make-the-RT_XKBCLIENT-resource-private.patch \ + file://0003-xkb-Free-the-XKB-resource-when-freeing-XkbInterest.patch \ + file://0004-xkb-Prevent-overflow-in-XkbSetCompatMap.patch \ + " SRC_URI[sha256sum] = "c878d1930d87725d4a5bf498c24f4be8130d5b2646a9fd0f2994deff90116352" # These extensions are now integrated into the server, so declare the migration From patchwork Sat Nov 22 22:14:12 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75230 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 C6344CFD302 for ; Sat, 22 Nov 2025 22:14:53 +0000 (UTC) Received: from mail-pj1-f51.google.com (mail-pj1-f51.google.com [209.85.216.51]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.3753.1763849685303655565 for ; Sat, 22 Nov 2025 14:14:45 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=VzjGt5Tk; spf=softfail (domain: sakoman.com, ip: 209.85.216.51, mailfrom: steve@sakoman.com) Received: by mail-pj1-f51.google.com with SMTP id 98e67ed59e1d1-34585428e33so3133952a91.3 for ; Sat, 22 Nov 2025 14:14:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849684; x=1764454484; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=VCgl0Cl/qcIjFazLk15gg1DahK1vWogkZe4DxmSkXH8=; b=VzjGt5TkM/CwGjCXErRBbnB+v0oUTmc9E4OC/gXKLxhPh/NYuos6rlHMdiWkuI1elZ 5V8L+usrO6YrD+PSiCOZgsG6U5aZGD84v4u2p7MwsKNQcRiv1FSILtHBbxLmHzK2tjBo Bk70FlPX+OImJ3FTp/mbeoXr/bM98AB8Z+B7j9nSWY8ejvpNhO+5MsRJARa6QcSC7Kes nROEvmxTKkB0A0KAnWI7qa63srYrRB+BqviChKYNgaz1AUwkROukvv4TO9RG5Fj++14P X1B+iOpmuvCUgA4RXzNaiVIi4cRljnvzLxOfjyKD/shlw+yxGki9Zo4lwL9K2qeezS+K 36nw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849684; x=1764454484; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=VCgl0Cl/qcIjFazLk15gg1DahK1vWogkZe4DxmSkXH8=; b=RIQTwJzKl9labLxKc1v6+z0QFRqnY+08yrgeSN0sg3l5I7shAO/+auf5MZwSwYBAKt i0kz5U2AQAaWQRTlgOoqxDN8W4TI62oPGEgpNFEQU4ibAFjoOx6+AL/U4OaT7Jnpt5vr Yr87STJs1K9lxHDpKKgVibTQEq/PtGGkiuUiy2OIxEAri3nINsXpqoVayl21ltdvgSl8 5YfPIsLJayRsEnXtkXzUNg/cjtiW3eLFiF8JOYvDEPsiCkmYv8gGIDu7N6zvEvgQZsnA g8FAOAVvXC65DphBPKcIv2nDez6Pswyr7+wTF/YXwa0ovTmfYNETRXJ90CkoNKxIkdcR mOUw== X-Gm-Message-State: AOJu0YwEetJ9nSxAmqhfN+rXEHq8siCRYXyIh9evuOXqcAte1Zo7irwY ZJlFt8Wm2fuRZP1/X3yLcoHjb+SKt5bpQXnC2sXC2H4/UKA+C9AoNtjDD1uWXqBtgV4c/j1Y2Ge uJ2Rg X-Gm-Gg: ASbGnctaJnfMTQR3L+bTSbYCk91M/cx7iMK/pyz7IDHwb78iaemV7xJETC7WDbaqefO K1fyG1rtoPV9S4F+wGti5V4UzRwklyBUpeUGOF5/X11OcYx/VkCYq5cb8sPdjLfph6GT4FEOa8V 9pDGYCIK3WkntLvXofUhIr9VOfF3C1bcMhV/CiRcPCxQqblvoDmierITUvyU/D/tvZNh7kNlYWL gDPNAzbgz9p9sQtJZxYoWqT0Oj5dVxhXT1W31F8YldQ8VQXXUeHG7v0VJQFkSdJFikBwNiaLi3g xb/bjdlceM1VQVE6KP4ljXRsMzRqbGv4oItpiA7DE9q3hMS3A7cWhv8eK5Nz1dpkXuFyR3xj1Eu 3Uihwf7XEx23YIPDAUNG5fR8eUyxQinO648GwLGWx2BDf0JbhCPyymDsc2DkAapJ5+osT5TbJA8 ZYhA== X-Google-Smtp-Source: AGHT+IFw/uDb5Z3+hLXjYpxvuMYrgwhgRVf6ZrrdJ+zGBPO5CWIidWpk/qgSOv7sP62es+g4l23C9g== X-Received: by 2002:a17:90b:4b03:b0:343:747e:2cab with SMTP id 98e67ed59e1d1-34733e2d39emr6966193a91.8.1763849684519; Sat, 22 Nov 2025 14:14:44 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.14.43 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:14:44 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 06/21] xwayland: fix CVE-2025-62229 Date: Sat, 22 Nov 2025 14:14:12 -0800 Message-ID: <3d606cc94e5ce42b836878578fa271a72bc76015.1763849517.git.steve@sakoman.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:14:53 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226704 From: Yogita Urade A flaw was found in the X.Org X server and Xwayland when processing X11 Present extension notifications. Improper error handling during notification creation can leave dangling pointers that lead to a use-after-free condition. This can cause memory corruption or a crash, potentially allowing an attacker to execute arbitrary code or cause a denial of service. Reference: https://nvd.nist.gov/vuln/detail/CVE-2025-62229 Upstream patch: https://gitlab.freedesktop.org/xorg/xserver/-/commit/5a4286b13f631b66c20f5bc8db7b68211dcbd1d0 Signed-off-by: Yogita Urade Signed-off-by: Steve Sakoman --- .../xwayland/xwayland/CVE-2025-62229.patch | 89 +++++++++++++++++++ .../xwayland/xwayland_23.2.5.bb | 1 + 2 files changed, 90 insertions(+) create mode 100644 meta/recipes-graphics/xwayland/xwayland/CVE-2025-62229.patch diff --git a/meta/recipes-graphics/xwayland/xwayland/CVE-2025-62229.patch b/meta/recipes-graphics/xwayland/xwayland/CVE-2025-62229.patch new file mode 100644 index 0000000000..f27bd00434 --- /dev/null +++ b/meta/recipes-graphics/xwayland/xwayland/CVE-2025-62229.patch @@ -0,0 +1,89 @@ +From 5a4286b13f631b66c20f5bc8db7b68211dcbd1d0 Mon Sep 17 00:00:00 2001 +From: Olivier Fourdan +Date: Wed, 2 Jul 2025 09:46:22 +0200 +Subject: [PATCH] present: Fix use-after-free in present_create_notifies() + +Using the Present extension, if an error occurs while processing and +adding the notifications after presenting a pixmap, the function +present_create_notifies() will clean up and remove the notifications +it added. + +However, there are two different code paths that can lead to an error +creating the notify, one being before the notify is being added to the +list, and another one after the notify is added. + +When the error occurs before it's been added, it removes the elements up +to the last added element, instead of the actual number of elements +which were added. + +As a result, in case of error, as with an invalid window for example, it +leaves a dangling pointer to the last element, leading to a use after +free case later: + + | Invalid write of size 8 + | at 0x5361D5: present_clear_window_notifies (present_notify.c:42) + | by 0x534A56: present_destroy_window (present_screen.c:107) + | by 0x41E441: xwl_destroy_window (xwayland-window.c:1959) + | by 0x4F9EC9: compDestroyWindow (compwindow.c:622) + | by 0x51EAC4: damageDestroyWindow (damage.c:1592) + | by 0x4FDC29: DbeDestroyWindow (dbe.c:1291) + | by 0x4EAC55: FreeWindowResources (window.c:1023) + | by 0x4EAF59: DeleteWindow (window.c:1091) + | by 0x4DE59A: doFreeResource (resource.c:890) + | by 0x4DEFB2: FreeClientResources (resource.c:1156) + | by 0x4A9AFB: CloseDownClient (dispatch.c:3567) + | by 0x5DCC78: ClientReady (connection.c:603) + | Address 0x16126200 is 16 bytes inside a block of size 2,048 free'd + | at 0x4841E43: free (vg_replace_malloc.c:989) + | by 0x5363DD: present_destroy_notifies (present_notify.c:111) + | by 0x53638D: present_create_notifies (present_notify.c:100) + | by 0x5368E9: proc_present_pixmap_common (present_request.c:164) + | by 0x536A7D: proc_present_pixmap (present_request.c:189) + | by 0x536FA9: proc_present_dispatch (present_request.c:337) + | by 0x4A1E4E: Dispatch (dispatch.c:561) + | by 0x4B00F1: dix_main (main.c:284) + | by 0x42879D: main (stubmain.c:34) + | Block was alloc'd at + | at 0x48463F3: calloc (vg_replace_malloc.c:1675) + | by 0x5362A1: present_create_notifies (present_notify.c:81) + | by 0x5368E9: proc_present_pixmap_common (present_request.c:164) + | by 0x536A7D: proc_present_pixmap (present_request.c:189) + | by 0x536FA9: proc_present_dispatch (present_request.c:337) + | by 0x4A1E4E: Dispatch (dispatch.c:561) + | by 0x4B00F1: dix_main (main.c:284) + | by 0x42879D: main (stubmain.c:34) + +To fix the issue, count and remove the actual number of notify elements +added in case of error. + +CVE-2025-62229, ZDI-CAN-27238 + +This vulnerability was discovered by: +Jan-Niklas Sohn working with Trend Micro Zero Day Initiative + +Signed-off-by: Olivier Fourdan +Part-of: + +CVE: CVE-2025-62229 +Upstream-Status: Backport [https://gitlab.freedesktop.org/xorg/xserver/-/commit/5a4286b13f631b66c20f5bc8db7b68211dcbd1d0] + +Signed-off-by: Yogita Urade +--- + present/present_notify.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/present/present_notify.c b/present/present_notify.c +index 4459549..00b3b68 100644 +--- a/present/present_notify.c ++++ b/present/present_notify.c +@@ -90,7 +90,7 @@ present_create_notifies(ClientPtr client, int num_notifies, xPresentNotify *x_no + if (status != Success) + goto bail; + +- added = i; ++ added++; + } + return Success; + +-- +2.40.0 diff --git a/meta/recipes-graphics/xwayland/xwayland_23.2.5.bb b/meta/recipes-graphics/xwayland/xwayland_23.2.5.bb index 49e35ca442..1ed5df8a2e 100644 --- a/meta/recipes-graphics/xwayland/xwayland_23.2.5.bb +++ b/meta/recipes-graphics/xwayland/xwayland_23.2.5.bb @@ -31,6 +31,7 @@ SRC_URI = "https://www.x.org/archive/individual/xserver/xwayland-${PV}.tar.xz \ file://CVE-2025-49178.patch \ file://CVE-2025-49179.patch \ file://CVE-2025-49180.patch \ + file://CVE-2025-62229.patch \ " SRC_URI[sha256sum] = "33ec7ff2687a59faaa52b9b09aa8caf118e7ecb6aed8953f526a625ff9f4bd90" From patchwork Sat Nov 22 22:14:13 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75231 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 DA84DCFD308 for ; Sat, 22 Nov 2025 22:14:53 +0000 (UTC) Received: from mail-pl1-f170.google.com (mail-pl1-f170.google.com [209.85.214.170]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.3754.1763849687108426472 for ; Sat, 22 Nov 2025 14:14:47 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=DBYcYAHg; spf=softfail (domain: sakoman.com, ip: 209.85.214.170, mailfrom: steve@sakoman.com) Received: by mail-pl1-f170.google.com with SMTP id d9443c01a7336-297d4a56f97so46062155ad.1 for ; Sat, 22 Nov 2025 14:14:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849686; x=1764454486; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=xr347e5oeu24MJTtkJu9uTi1cCW/LkvNyt6ZSXKIOYw=; b=DBYcYAHgTSoaPsWS2t4b9Jw/125FTQtarz52OcTQ56XwU0jvz5Alzbr6C+UvT+Rllo En3YdOaoJ+F0YNzfYM6N8nJwO6SWtIu8IOEqPs3DXvD713TYXeqeZDKSDb+wOr4EARfx /sr57tmV7LXutHRPJ+T9/PjFVHLoo5RCMOzekAMouid6lHVzd6vXiBTcx2O0k+BwLSpg TZ3pO4sa25jC6lc51wwGR3O0gTCnLsY6L9rjqFbHV12nn7UKhAoxRJwbfMPK60AcUfHX gEpJxIPSuJ44uTVY4e7tHH/DtT74CPt4ZjRksce4V/uKjCUj1KcwQNt+uVj6qM2VKBJq aJ6w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849686; x=1764454486; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=xr347e5oeu24MJTtkJu9uTi1cCW/LkvNyt6ZSXKIOYw=; b=TDTMmyAmdw6Jbhmc98J8uv+dcsiBk2OdMmtAi/KJwJXuz+N2dwdZ4khUOy3ieS9hIe rFP83zUOiMqw5J5H//VyCoDURLyI+b2FGmf3eLXb8So/vpU8J7bDHSc66czwohyzIHnA HGo5QXct1qb+ORyptpAMfXfY1P34W6DfuwuwHGZcSdzk5ptyxHiJZFKkP84LXdfT7slF 9B2ueX7HrlE9kc1Yg4IblLaieBISJ8MRgI6hlPVxVsuMT7W+S2AeNIYA1KTDnrspFN0M yzGSchvrq7QEg5YgSL6kI7lL6B5IAA+VjfhoXvX2whSiJQg/oGMrUM2rJPKkox/M3XHu bEUg== X-Gm-Message-State: AOJu0YwZaJEgw232zkmYtqBM3iaW8o3tHBda6dlqOln0Q8WbvAW7MP90 qWIGzPKrQAXwwq0wsJF/aTT9EmewOgvqrVShoJQz1biVr40zbpXWuw9R6ORvB6XbzM71Xr1m0Rn +xudk X-Gm-Gg: ASbGncscEOqWnbaaef6O3KgHDhvm+8GhtPcVAD67uWDXKpbhFY1CsNM5L0Hvo1PIMHF PuWZhAgcCS5f1o7pplRRxtlhhkMjzpjRejLFzDx0xQWVEoFkDHTprNMpDYcQnXwAJk5UajxTq+a dtfqrbS2H+9k8XoPjdigfzqLq4ULtwLR2A0VvQyBChDTy0KRn89jCCceg3v4CEdV0i0+fqmXjuP HYp7EwkKyAeu8/CsT7r0rN8l+sAukKKhOwT8qcCi4P3EESFffwdVO+4Ve90ar1Ww8VSEyWZ6gnX tEOiPmiTNE0gCtp2DB1XFreQbjklgnJqWWX0y6I+6KOLwJ8PC/+E/BkKUaIoezcifd1vccckjVL 8tajUuAiQXbtZYhtkhza6eyuL5zqpgMHZYARTFRtn5aZDaM5lJwP0RrBO6DwGbnjy5psw6rQFNE RXlg== X-Google-Smtp-Source: AGHT+IHEhc+G/YAHYTXF8y2MfDpQfRb1yi9gwd2C0xkoq4dwTsqu5laZ0bl7JdZYpJxbqm8IcCyV2g== X-Received: by 2002:a17:90b:3d90:b0:33e:2d0f:4793 with SMTP id 98e67ed59e1d1-34733e4c735mr6852068a91.11.1763849686254; Sat, 22 Nov 2025 14:14:46 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.14.45 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:14:45 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 07/21] xwayland: fix CVE-2025-62230 Date: Sat, 22 Nov 2025 14:14:13 -0800 Message-ID: <5d98bca7ca76964a6bf7efb7cf8331b9f518ad00.1763849517.git.steve@sakoman.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:14:53 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226705 From: Yogita Urade A flaw was discovered in the X.Org X serverâ\x80\x99s X Keyboard (Xkb) extension when handling client resource cleanup. The software frees certain data structures without properly detaching related resources, leading to a use-after-free condition. This can cause memory corruption or a crash when affected clients disconnect. Reference: https://gitlab.freedesktop.org/xorg/xserver/-/commit/3baad99f9c15028ed8c3e3d8408e5ec35db155aa Upstream patches: https://gitlab.freedesktop.org/xorg/xserver/-/commit/865089ca70840c0f13a61df135f7b44a9782a175 https://gitlab.freedesktop.org/xorg/xserver/-/commit/87fe2553937a99fd914ad0cde999376a3adc3839 Signed-off-by: Yogita Urade Signed-off-by: Steve Sakoman --- .../xwayland/CVE-2025-62230-0001.patch | 60 +++++++++++++ .../xwayland/CVE-2025-62230-0002.patch | 89 +++++++++++++++++++ .../xwayland/xwayland_23.2.5.bb | 2 + 3 files changed, 151 insertions(+) create mode 100644 meta/recipes-graphics/xwayland/xwayland/CVE-2025-62230-0001.patch create mode 100644 meta/recipes-graphics/xwayland/xwayland/CVE-2025-62230-0002.patch diff --git a/meta/recipes-graphics/xwayland/xwayland/CVE-2025-62230-0001.patch b/meta/recipes-graphics/xwayland/xwayland/CVE-2025-62230-0001.patch new file mode 100644 index 0000000000..a26d13e712 --- /dev/null +++ b/meta/recipes-graphics/xwayland/xwayland/CVE-2025-62230-0001.patch @@ -0,0 +1,60 @@ +From 865089ca70840c0f13a61df135f7b44a9782a175 Mon Sep 17 00:00:00 2001 +From: Olivier Fourdan +Date: Wed, 10 Sep 2025 15:55:06 +0200 +Subject: [PATCH] xkb: Make the RT_XKBCLIENT resource private + +Currently, the resource in only available to the xkb.c source file. + +In preparation for the next commit, to be able to free the resources +from XkbRemoveResourceClient(), make that variable private instead. + +This is related to: + +CVE-2025-62230, ZDI-CAN-27545 + +This vulnerability was discovered by: +Jan-Niklas Sohn working with Trend Micro Zero Day Initiative + +Signed-off-by: Olivier Fourdan +Reviewed-by: Michel Dänzer +(cherry picked from commit 99790a2c9205a52fbbec01f21a92c9b7f4ed1d8f) + +Part-of: + +CVE: CVE-2025-62230 +Upstream-Status: Backport [https://gitlab.freedesktop.org/xorg/xserver/-/commit/865089ca70840c0f13a61df135f7b44a9782a175] + +Signed-off-by: Yogita Urade +--- + include/xkbsrv.h | 2 ++ + xkb/xkb.c | 2 +- + 2 files changed, 3 insertions(+), 1 deletion(-) + +diff --git a/include/xkbsrv.h b/include/xkbsrv.h +index 21cd876..24fdfb4 100644 +--- a/include/xkbsrv.h ++++ b/include/xkbsrv.h +@@ -58,6 +58,8 @@ THE USE OR PERFORMANCE OF THIS SOFTWARE. + #include "inputstr.h" + #include "events.h" + ++extern RESTYPE RT_XKBCLIENT; ++ + typedef struct _XkbInterest { + DeviceIntPtr dev; + ClientPtr client; +diff --git a/xkb/xkb.c b/xkb/xkb.c +index 3210ff9..b7877f5 100644 +--- a/xkb/xkb.c ++++ b/xkb/xkb.c +@@ -51,7 +51,7 @@ int XkbKeyboardErrorCode; + CARD32 xkbDebugFlags = 0; + static CARD32 xkbDebugCtrls = 0; + +-static RESTYPE RT_XKBCLIENT; ++RESTYPE RT_XKBCLIENT = 0; + + /***====================================================================***/ + +-- +2.40.0 diff --git a/meta/recipes-graphics/xwayland/xwayland/CVE-2025-62230-0002.patch b/meta/recipes-graphics/xwayland/xwayland/CVE-2025-62230-0002.patch new file mode 100644 index 0000000000..b5230359ba --- /dev/null +++ b/meta/recipes-graphics/xwayland/xwayland/CVE-2025-62230-0002.patch @@ -0,0 +1,89 @@ +From 87fe2553937a99fd914ad0cde999376a3adc3839 Mon Sep 17 00:00:00 2001 +From: Olivier Fourdan +Date: Wed, 10 Sep 2025 15:58:57 +0200 +Subject: [PATCH] xkb: Free the XKB resource when freeing XkbInterest + +XkbRemoveResourceClient() would free the XkbInterest data associated +with the device, but not the resource associated with it. + +As a result, when the client terminates, the resource delete function +gets called and accesses already freed memory: + + | Invalid read of size 8 + | at 0x5BC0C0: XkbRemoveResourceClient (xkbEvents.c:1047) + | by 0x5B3391: XkbClientGone (xkb.c:7094) + | by 0x4DF138: doFreeResource (resource.c:890) + | by 0x4DFB50: FreeClientResources (resource.c:1156) + | by 0x4A9A59: CloseDownClient (dispatch.c:3550) + | by 0x5E0A53: ClientReady (connection.c:601) + | by 0x5E4FEF: ospoll_wait (ospoll.c:657) + | by 0x5DC834: WaitForSomething (WaitFor.c:206) + | by 0x4A1BA5: Dispatch (dispatch.c:491) + | by 0x4B0070: dix_main (main.c:277) + | by 0x4285E7: main (stubmain.c:34) + | Address 0x1893e278 is 184 bytes inside a block of size 928 free'd + | at 0x4842E43: free (vg_replace_malloc.c:989) + | by 0x49C1A6: CloseDevice (devices.c:1067) + | by 0x49C522: CloseOneDevice (devices.c:1193) + | by 0x49C6E4: RemoveDevice (devices.c:1244) + | by 0x5873D4: remove_master (xichangehierarchy.c:348) + | by 0x587921: ProcXIChangeHierarchy (xichangehierarchy.c:504) + | by 0x579BF1: ProcIDispatch (extinit.c:390) + | by 0x4A1D85: Dispatch (dispatch.c:551) + | by 0x4B0070: dix_main (main.c:277) + | by 0x4285E7: main (stubmain.c:34) + | Block was alloc'd at + | at 0x48473F3: calloc (vg_replace_malloc.c:1675) + | by 0x49A118: AddInputDevice (devices.c:262) + | by 0x4A0E58: AllocDevicePair (devices.c:2846) + | by 0x5866EE: add_master (xichangehierarchy.c:153) + | by 0x5878C2: ProcXIChangeHierarchy (xichangehierarchy.c:493) + | by 0x579BF1: ProcIDispatch (extinit.c:390) + | by 0x4A1D85: Dispatch (dispatch.c:551) + | by 0x4B0070: dix_main (main.c:277) + | by 0x4285E7: main (stubmain.c:34) + +To avoid that issue, make sure to free the resources when freeing the +device XkbInterest data. + +CVE-2025-62230, ZDI-CAN-27545 + +This vulnerability was discovered by: +Jan-Niklas Sohn working with Trend Micro Zero Day Initiative + +Signed-off-by: Olivier Fourdan +Reviewed-by: Michel Dänzer +(cherry picked from commit 10c94238bdad17c11707e0bdaaa3a9cd54c504be) + +Part-of: + +CVE: CVE-2025-62230 +Upstream-Status: Backport [https://gitlab.freedesktop.org/xorg/xserver/-/commit/87fe2553937a99fd914ad0cde999376a3adc3839] + +Signed-off-by: Yogita Urade +--- + xkb/xkbEvents.c | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/xkb/xkbEvents.c b/xkb/xkbEvents.c +index f8f65d4..7c669c9 100644 +--- a/xkb/xkbEvents.c ++++ b/xkb/xkbEvents.c +@@ -1055,6 +1055,7 @@ XkbRemoveResourceClient(DevicePtr inDev, XID id) + autoCtrls = interest->autoCtrls; + autoValues = interest->autoCtrlValues; + client = interest->client; ++ FreeResource(interest->resource, RT_XKBCLIENT); + free(interest); + found = TRUE; + } +@@ -1066,6 +1067,7 @@ XkbRemoveResourceClient(DevicePtr inDev, XID id) + autoCtrls = victim->autoCtrls; + autoValues = victim->autoCtrlValues; + client = victim->client; ++ FreeResource(victim->resource, RT_XKBCLIENT); + free(victim); + found = TRUE; + } +-- +2.40.0 diff --git a/meta/recipes-graphics/xwayland/xwayland_23.2.5.bb b/meta/recipes-graphics/xwayland/xwayland_23.2.5.bb index 1ed5df8a2e..9bc67f7761 100644 --- a/meta/recipes-graphics/xwayland/xwayland_23.2.5.bb +++ b/meta/recipes-graphics/xwayland/xwayland_23.2.5.bb @@ -32,6 +32,8 @@ SRC_URI = "https://www.x.org/archive/individual/xserver/xwayland-${PV}.tar.xz \ file://CVE-2025-49179.patch \ file://CVE-2025-49180.patch \ file://CVE-2025-62229.patch \ + file://CVE-2025-62230-0001.patch \ + file://CVE-2025-62230-0002.patch \ " SRC_URI[sha256sum] = "33ec7ff2687a59faaa52b9b09aa8caf118e7ecb6aed8953f526a625ff9f4bd90" From patchwork Sat Nov 22 22:14:14 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75228 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 D2FA0CFD306 for ; Sat, 22 Nov 2025 22:14:53 +0000 (UTC) Received: from mail-pj1-f48.google.com (mail-pj1-f48.google.com [209.85.216.48]) by mx.groups.io with SMTP id smtpd.msgproc01-g2.2709.1763849688780720841 for ; Sat, 22 Nov 2025 14:14:48 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=1kIosgke; spf=softfail (domain: sakoman.com, ip: 209.85.216.48, mailfrom: steve@sakoman.com) Received: by mail-pj1-f48.google.com with SMTP id 98e67ed59e1d1-343ff854297so4550723a91.1 for ; Sat, 22 Nov 2025 14:14:48 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849688; x=1764454488; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=XkOJI6Kf+k0PdeCCmm3KWsblQbv96+CTlJqG2k+c2c8=; b=1kIosgke/WGNker+KAIq6mzCXSLhrxzsPCxeFGfLOvAicTWzWdE/hxLRPhMz7hz1k2 KZc3Ro6p70F9UsoRC+j4OMicDPXwo8ysTzpsrXDURQWdmaAvCv77CsDBpsyE6y1N4BT7 TVjV8nAfm43NEX/1iWV1ohRp+zFkeWjzecDURwl7FXIQhuZNcoikoDtK1SdaQhBoHUcR or7FxctrQdMq6FPqpnvDQEEBz/CaT2QKnFPhe2rX6hocfA29zKJoCAEhvFtas3FBAx2+ MZLZyEIzVbiuapSNB96/G/o72RR0Fxt409UEP4ylfxUXapEhW+pLw7PqmAcog3CJWLg4 a7Qg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849688; x=1764454488; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=XkOJI6Kf+k0PdeCCmm3KWsblQbv96+CTlJqG2k+c2c8=; b=UcD8I9BqMRUrt3vDoMcoxCPrjxX1SmbvPIF4ECt7xzoj0UBtHagDVZRlUjD4pZmE00 iMwB5hxv8uPvaiC+8i85fAy6vbUHYASA2S2YqjPVO1YBZhVh32fQc7wYxw0MM5CIuEN3 KKHDBGWowG9ZSOqfsqgfImwLjHNLfzzlzqiirrl/YElAUE3Zn3KtjqugrPgACXhrTLaG pS3d2B2ak+sE234NplHq17ySJjs+hOQwCWk6qDrOpvcNcbPzmMaR7dqhSJHHs2IQRCah NxtQAlyhRfqZCk9pc5Ybleb4NKlwucJ9MjwDJG4zl17Gy3bFzc0d8GYS4w4b7JQEuZih tQpw== X-Gm-Message-State: AOJu0YzGEPHUd/FpvZwNZ2AJoJSHhQW7z/FTWNNoLIeUFf6FDN7b0j/7 KCSUiOyEvXVk4RVM7P1acbUU59lCFNyJzvVAXHKr68ctw6pOomrA/y3vVkvygTHKYvBRrHJMkFq OBsc1 X-Gm-Gg: ASbGnctu0uRzR/dk7nNhrwfdRaUdIrj3ES4Y4v360qD250ZE/YBJ1zLm616F9cOeH86 PrE8lQtMQZG+gg7gNqdpHD/m6teobssqRfCUoEvFgYcNe4b3656HzWqu7ubQctYCkjl2F+bvjqs bX5WCNC/biYK3QN1X/JxxFxcAGxYfBO6LpIQPeArj1rhsvDnmD2WigzJTyLkkZNUefqahtzgjKZ VLK+aGk/48fWvQ+E4IieynF1ear8CpXAI68uWS5z9HzVhmgNmv8OtOii/jaHAm8dNnn1Ho5FHLr r3gKvUqXetNbnxdW0QSudMzk8TYBd1M0MaKeGKza/5f+lly4OKfcbq+MT9fDPFSSvYlS3eh6pu2 lCMxfs/1Mlj0QQzQ/FP+nhoJCex9RP+YGI6nro2jotIWq4aOzchJrOIPHczfyQW5bkcFmCGY1YJ fu4w== X-Google-Smtp-Source: AGHT+IE02vLyQiDbZT+94zFdlnRWOBFVm2Z8CHpe3WXjooqnjZ79ofX8jk8BmWa3n8ZUuxmqFLKrLw== X-Received: by 2002:a17:90b:3c8e:b0:340:ca7d:936a with SMTP id 98e67ed59e1d1-34733f22173mr8145395a91.18.1763849688031; Sat, 22 Nov 2025 14:14:48 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.14.47 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:14:47 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 08/21] xwayland: fix CVE-2025-62231 Date: Sat, 22 Nov 2025 14:14:14 -0800 Message-ID: <97326be553f3fec8fbda63a8b38d18f656425b2c.1763849517.git.steve@sakoman.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:14:53 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226706 From: Yogita Urade A flaw was identified in the X.Org X serverâ\x80\x99s X Keyboard (Xkb) extension where improper bounds checking in the XkbSetCompatMap() function can cause an unsigned short overflow. If an attacker sends specially crafted input data, the value calculation may overflow, leading to memory corruption or a crash. Reference: https://nvd.nist.gov/vuln/detail/CVE-2025-62231 Upstream patch: https://gitlab.freedesktop.org/xorg/xserver/-/commit/3baad99f9c15028ed8c3e3d8408e5ec35db155aa Signed-off-by: Yogita Urade Signed-off-by: Steve Sakoman --- .../xwayland/xwayland/CVE-2025-62231.patch | 50 +++++++++++++++++++ .../xwayland/xwayland_23.2.5.bb | 1 + 2 files changed, 51 insertions(+) create mode 100644 meta/recipes-graphics/xwayland/xwayland/CVE-2025-62231.patch diff --git a/meta/recipes-graphics/xwayland/xwayland/CVE-2025-62231.patch b/meta/recipes-graphics/xwayland/xwayland/CVE-2025-62231.patch new file mode 100644 index 0000000000..8095c3d82c --- /dev/null +++ b/meta/recipes-graphics/xwayland/xwayland/CVE-2025-62231.patch @@ -0,0 +1,50 @@ +From 3baad99f9c15028ed8c3e3d8408e5ec35db155aa Mon Sep 17 00:00:00 2001 +From: Olivier Fourdan +Date: Wed, 10 Sep 2025 16:30:29 +0200 +Subject: [PATCH] xkb: Prevent overflow in XkbSetCompatMap() + +The XkbCompatMap structure stores its "num_si" and "size_si" fields +using an unsigned short. + +However, the function _XkbSetCompatMap() will store the sum of the +input data "firstSI" and "nSI" in both XkbCompatMap's "num_si" and +"size_si" without first checking if the sum overflows the maximum +unsigned short value, leading to a possible overflow. + +To avoid the issue, check whether the sum does not exceed the maximum +unsigned short value, or return a "BadValue" error otherwise. + +CVE-2025-62231, ZDI-CAN-27560 + +This vulnerability was discovered by: +Jan-Niklas Sohn working with Trend Micro Zero Day Initiative + +Signed-off-by: Olivier Fourdan +Reviewed-by: Michel Dänzer +(cherry picked from commit 475d9f49acd0e55bc0b089ed77f732ad18585470) + +Part-of: + +CVE: CVE-2025-62231 +Upstream-Status: Backport [https://gitlab.freedesktop.org/xorg/xserver/-/commit/3baad99f9c15028ed8c3e3d8408e5ec35db155aa] + +Signed-off-by: Yogita Urade +--- + xkb/xkb.c | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/xkb/xkb.c b/xkb/xkb.c +index b7877f5..4e585d1 100644 +--- a/xkb/xkb.c ++++ b/xkb/xkb.c +@@ -2992,6 +2992,8 @@ _XkbSetCompatMap(ClientPtr client, DeviceIntPtr dev, + XkbSymInterpretPtr sym; + unsigned int skipped = 0; + ++ if ((unsigned) (req->firstSI + req->nSI) > USHRT_MAX) ++ return BadValue; + if ((unsigned) (req->firstSI + req->nSI) > compat->size_si) { + compat->num_si = compat->size_si = req->firstSI + req->nSI; + compat->sym_interpret = reallocarray(compat->sym_interpret, +-- +2.40.0 diff --git a/meta/recipes-graphics/xwayland/xwayland_23.2.5.bb b/meta/recipes-graphics/xwayland/xwayland_23.2.5.bb index 9bc67f7761..362b110a0b 100644 --- a/meta/recipes-graphics/xwayland/xwayland_23.2.5.bb +++ b/meta/recipes-graphics/xwayland/xwayland_23.2.5.bb @@ -34,6 +34,7 @@ SRC_URI = "https://www.x.org/archive/individual/xserver/xwayland-${PV}.tar.xz \ file://CVE-2025-62229.patch \ file://CVE-2025-62230-0001.patch \ file://CVE-2025-62230-0002.patch \ + file://CVE-2025-62231.patch \ " SRC_URI[sha256sum] = "33ec7ff2687a59faaa52b9b09aa8caf118e7ecb6aed8953f526a625ff9f4bd90" From patchwork Sat Nov 22 22:14:15 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75229 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 CA641CFD2F9 for ; Sat, 22 Nov 2025 22:14:53 +0000 (UTC) Received: from mail-pj1-f54.google.com (mail-pj1-f54.google.com [209.85.216.54]) by mx.groups.io with SMTP id smtpd.msgproc01-g2.2710.1763849690436639751 for ; Sat, 22 Nov 2025 14:14:50 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=MUegMJYH; spf=softfail (domain: sakoman.com, ip: 209.85.216.54, mailfrom: steve@sakoman.com) Received: by mail-pj1-f54.google.com with SMTP id 98e67ed59e1d1-343514c7854so1685360a91.1 for ; Sat, 22 Nov 2025 14:14:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849690; x=1764454490; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=kby8h68VDHTnfgbW6dNePQL/nZ1eDGmSCKDpfspeX3A=; b=MUegMJYH5HOwmVO+j1t1yU3mXOBHJjR+eAl9rLxhMRFH0PKa/FE3ijRxvI9McD3G39 jHW6Tgga0DUxhaS/qlgU1a5y3jGBPU9QKO+GaQ8JXE+DMSK9U5gG2G3q5VgKS6r3FHOf GcJcghPXZKEJJ1gl1qfbYUf0jxJhOswhq6gV8O1ZMBeSbot80s0HzaWF0PcEY3FzxoLS kQT/ffE0sJrkg7kC3YiRM0frV20rZZLMykrI93hnornIvnLJBXTV40QlZnIwu6Zd5B+p hijkFJ1GODLMTeAVL01lHeJ6N6k7SqJY1bzVH+k5sstnUisYKq7zB2Z9l7wshRRQc6yK 0xng== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849690; x=1764454490; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=kby8h68VDHTnfgbW6dNePQL/nZ1eDGmSCKDpfspeX3A=; b=OLKOCsz/N2FhVDmRlgL4y2XwDwqnYU2dlZevPlCqy6hgoQJVed96uvaDzezLn9ovnv rCPAF9920YO8qCMY3Vf3gS6usXwUu6Tr9NTnQVtaRzMtj07CaSB+au7CT4Vg/tr4qLhw tw0OjPNez8fLxx8K8zy2I/rVvRZQy+DgIncBg97tElWsIEMlyTM5oQfn5zx3kKzMto64 dsb2QupwXwOs5Vx7fimQBtansWZYvCDRXCJCriNwjDss7NgHJRL4PxAN3NJYbxqpbwit vVnX+XV9/QX7TiVuY6F7O7Sk22HoxPIEv8R3UD8ElLkIwyHRBCUGlXvILdWE7VPvZX/q 0Q+Q== X-Gm-Message-State: AOJu0YxZstVRSZl34kGsX8uAf6o3UnqKzsCiULQmfN9a9jyCmhHOzuIo sZEk9oD3AiokponToJ8QRGsIfrSMFNhrxOGZ2hbcGK8RBCW7ILJ+CByrsnrqsokBWN3RaQAs4AX 5CxQE X-Gm-Gg: ASbGncvQgHws/4/nV5jVQcF/qZ0Kp4Z0EGaJIuJuKS1M6pBpjk3Qx1HbAIZ9sEAetNy vQ+weym3gQ7mHR/N8RikNCUmk3+agcNjbaOva1vUTIxQiyzSzFe1DtIg6g/Q9jMNUKcsau2Mbq2 T+fgBc6ePyepUkitUcN0xeAJIPHzQuRTXjQ58D+Z39fdI7/2yVPRbCgQ6gOIXpOlNRnENzYzvPv rFZGmBZ6D+yhsgmCpz0aXu8wIFRkxmYeeTQcY0NfWIRflGMSeqwjocKm9FFoAllelD1KgdIvIEB KJlKuG+lbpJ43ZMHHCvpvNO2JRjKBj2YLz9M4WC4FbRSGgHk/k/MAdt5HgNSExfgxlexqA3lj7F QNK5C3hFMhfc7/hhe1WujtSe5pJb0kER2Fy+BIdbfrS9TAKXB0xvEe0LhA/i2zbsNcgtRV8PoBy MvMg== X-Google-Smtp-Source: AGHT+IGhroyGy/9Zn9Ot5tu95e4NZjNV474nDMhxBCAjZlU/FjAxW22LGZXHho791+CpFbuQwZ2rbA== X-Received: by 2002:a17:90a:e7c7:b0:340:6b6f:4bbf with SMTP id 98e67ed59e1d1-347298dacdcmr11888055a91.18.1763849689652; Sat, 22 Nov 2025 14:14:49 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.14.48 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:14:49 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 09/21] musl: patch CVE-2025-26519 Date: Sat, 22 Nov 2025 14:14:15 -0800 Message-ID: X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:14:53 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226707 From: Gyorgy Sarvari Details: https://nvd.nist.gov/vuln/detail/CVE-2025-26519 Pick the patches that are attached to the musl advisory: https://www.openwall.com/lists/musl/2025/02/13/1 Signed-off-by: Gyorgy Sarvari Signed-off-by: Steve Sakoman --- .../musl/musl/CVE-2025-26519-1.patch | 39 +++++++++++++++++++ .../musl/musl/CVE-2025-26519-2.patch | 38 ++++++++++++++++++ meta/recipes-core/musl/musl_git.bb | 4 +- 3 files changed, 80 insertions(+), 1 deletion(-) create mode 100644 meta/recipes-core/musl/musl/CVE-2025-26519-1.patch create mode 100644 meta/recipes-core/musl/musl/CVE-2025-26519-2.patch diff --git a/meta/recipes-core/musl/musl/CVE-2025-26519-1.patch b/meta/recipes-core/musl/musl/CVE-2025-26519-1.patch new file mode 100644 index 0000000000..5583c5f6cc --- /dev/null +++ b/meta/recipes-core/musl/musl/CVE-2025-26519-1.patch @@ -0,0 +1,39 @@ +From 8ebb2a68dfac02e7a83885587a9a5a203147ebbe Mon Sep 17 00:00:00 2001 +From: Rich Felker +Date: Wed, 19 Nov 2025 13:23:38 +0100 +Subject: [PATCH] iconv: fix erroneous input validation in EUC-KR decoder + +as a result of incorrect bounds checking on the lead byte being +decoded, certain invalid inputs which should produce an encoding +error, such as "\xc8\x41", instead produced out-of-bounds loads from +the ksc table. + +in a worst case, the loaded value may not be a valid unicode scalar +value, in which case, if the output encoding was UTF-8, wctomb would +return (size_t)-1, causing an overflow in the output pointer and +remaining buffer size which could clobber memory outside of the output +buffer. + +bug report was submitted in private by Nick Wellnhofer on account of +potential security implications. + +CVE: CVE-2025-26519 +Upstream-Status: Backport [https://git.musl-libc.org/cgit/musl/commit/?id=e5adcd97b5196e29991b524237381a0202a60659] +Signed-off-by: Gyorgy Sarvari +--- + src/locale/iconv.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/locale/iconv.c b/src/locale/iconv.c +index 3047c27b..1fb66bc8 100644 +--- a/src/locale/iconv.c ++++ b/src/locale/iconv.c +@@ -495,7 +495,7 @@ size_t iconv(iconv_t cd, char **restrict in, size_t *restrict inb, char **restri + if (c >= 93 || d >= 94) { + c += (0xa1-0x81); + d += 0xa1; +- if (c >= 93 || c>=0xc6-0x81 && d>0x52) ++ if (c > 0xc6-0x81 || c==0xc6-0x81 && d>0x52) + goto ilseq; + if (d-'A'<26) d = d-'A'; + else if (d-'a'<26) d = d-'a'+26; diff --git a/meta/recipes-core/musl/musl/CVE-2025-26519-2.patch b/meta/recipes-core/musl/musl/CVE-2025-26519-2.patch new file mode 100644 index 0000000000..7d193ab241 --- /dev/null +++ b/meta/recipes-core/musl/musl/CVE-2025-26519-2.patch @@ -0,0 +1,38 @@ +From 7e7052e17e900194a588d337ff4a8e646133afed Mon Sep 17 00:00:00 2001 +From: Rich Felker +Date: Wed, 19 Nov 2025 13:27:15 +0100 +Subject: [PATCH] iconv: harden UTF-8 output code path against input decoder + bugs + +the UTF-8 output code was written assuming an invariant that iconv's +decoders only emit valid Unicode Scalar Values which wctomb can encode +successfully, thereby always returning a value between 1 and 4. + +if this invariant is not satisfied, wctomb returns (size_t)-1, and the +subsequent adjustments to the output buffer pointer and remaining +output byte count overflow, moving the output position backwards, +potentially past the beginning of the buffer, without storing any +bytes. + +CVE: CVE-2025-26519 +Upstream-Status: Backport [https://git.musl-libc.org/cgit/musl/commit/?id=c47ad25ea3b484e10326f933e927c0bc8cded3da] +Signed-off-by: Gyorgy Sarvari +--- + src/locale/iconv.c | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/src/locale/iconv.c b/src/locale/iconv.c +index 1fb66bc8..fb1d3217 100644 +--- a/src/locale/iconv.c ++++ b/src/locale/iconv.c +@@ -538,6 +538,10 @@ size_t iconv(iconv_t cd, char **restrict in, size_t *restrict inb, char **restri + if (*outb < k) goto toobig; + memcpy(*out, tmp, k); + } else k = wctomb_utf8(*out, c); ++ /* This failure condition should be unreachable, but ++ * is included to prevent decoder bugs from translating ++ * into advancement outside the output buffer range. */ ++ if (k>4) goto ilseq; + *out += k; + *outb -= k; + break; diff --git a/meta/recipes-core/musl/musl_git.bb b/meta/recipes-core/musl/musl_git.bb index 324269a968..bc516b6183 100644 --- a/meta/recipes-core/musl/musl_git.bb +++ b/meta/recipes-core/musl/musl_git.bb @@ -14,7 +14,9 @@ SRC_URI = "git://git.etalabs.net/git/musl;branch=master;protocol=https \ file://0001-Make-dynamic-linker-a-relative-symlink-to-libc.patch \ file://0002-ldso-Use-syslibdir-and-libdir-as-default-pathes-to-l.patch \ file://0003-elf.h-add-typedefs-for-Elf64_Relr-and-Elf32_Relr.patch \ - " + file://CVE-2025-26519-1.patch \ + file://CVE-2025-26519-2.patch \ + " S = "${WORKDIR}/git" From patchwork Sat Nov 22 22:14:16 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75227 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 C622BCFD301 for ; Sat, 22 Nov 2025 22:14:53 +0000 (UTC) Received: from mail-pj1-f47.google.com (mail-pj1-f47.google.com [209.85.216.47]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.3756.1763849691975204240 for ; Sat, 22 Nov 2025 14:14:52 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=BUnxn9Lf; spf=softfail (domain: sakoman.com, ip: 209.85.216.47, mailfrom: steve@sakoman.com) Received: by mail-pj1-f47.google.com with SMTP id 98e67ed59e1d1-3436d6aa66dso2079449a91.1 for ; Sat, 22 Nov 2025 14:14:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849691; x=1764454491; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=O5w/xsOph5MqaJ52W0khjcqyjUyULQq1fQKx1UlYGAE=; b=BUnxn9LfZLaDCntK3Pr4ltkzd5xASkBp42P9doy+5IhFoCwGKeA6aBSST13jErvofN mL0wv4jC8nqmjQ9dMiAMmSlHkwaVErT8BeQo49PVQp6bEAC/t20ifXu0SQxrPmnDT3dg GKPLue4HJWvgphRADnMG2BoIG/Gf8o+TxzovNG3JDXeqERhh25tGyJfj1XFYpRnnvh8P rl8QTX+2+OnqTj8UOWl2eKF7kCyZKuuGrPEumBZZo5Wa0aRKpUzD7MXgIlkyFIjjl+55 WZrVu8aqH87riAYRHkrUedxWkUAhzMTD/EVZFTK1KdHGhqExLAHuIAq+7PanLnEvA+ym 1vvg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849691; x=1764454491; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=O5w/xsOph5MqaJ52W0khjcqyjUyULQq1fQKx1UlYGAE=; b=sWcNxyC+yzGeGfDcRSbDJdDUZCPuhzW3gYJSESpQqILCqOgF755JR7vlWV11FTDixA gYd2y7+gS5oqzTc7DNFNUq+f1MTWjor0SoI7znnSbCkFO3kJI8s0ndBItk8iP1c8CiK5 eRa2dfcP17NlHpO8X4MI6kZeqVgMuHfGSR1j4Z7yzdbBvRyrz7nLa50D1CMPIvODAfzv 0Ov+vm/SMdXVTdfZXI+CBrzepymboGU6jKXZGOVLM6SW3rEgzw9Zxg9wz5rvprKea6bW 1vKaeFW+NtMpVPOV6iAt2AmCKWBpVg9DPP9yRtd0Uby2tDkk1HUi6eYoGKFEw3jxNrdz LPow== X-Gm-Message-State: AOJu0YyrP0a6QWPG2bahkAv+U0QyA9RM12V30BTb4pGLggVz75aayR0d 2bp9GQuG2fIyRR1NFTjVDGee61Oy2p0XoMapKgiRcau9DNQ1zHddnrvOYnrsUYTIxLznjGFqvzQ DUHFA X-Gm-Gg: ASbGncunJJbNu79fFHSSK8HDTWaKQGqGTrevs0gXsdNYJRs1EjaP5pKQ/niSV2wQe/m UnpqoPIls6eAfKIlm6X4N7iyKQL2U5aQ/jlbcdAMBVrWGk/mdxNbW6QOvyZdlDcBqhMynsaA6Te V6lWhVzkM1oCfXkiAf9LJOTYtXswl88xlKEw0v3wY1InPTw/Lh6z7PhRq2TmlbKB3cTH9Kkmjg3 hekFPGMHXa2MTuZ3GquvRp+QvKR75ZQuGg90FFwMYYVwUIGQqKmyW5MaONSbp7I70eiQMaC8uUf Y6Er0+e/3KW9UFVXdQLpEvq4el0QwoRIP8u+kPU4Ankm14ThXWBa7qclJSGF5a6yJnqeW8/eO4G +819K7X3HkZoiNo3cdZsImIKr4OPym3VlScMInf83TAuFqYk0jNLozLfkUo4wy8mhWIc7MYctUf +niw== X-Google-Smtp-Source: AGHT+IGBwsF/JP0jrFpxwQc0LEHE6E65H/iAyrGjMw7V2gQLwFvu46lbMJ9F35I1MvilY23nQ6WsyQ== X-Received: by 2002:a17:90b:33c2:b0:340:68ee:ae5e with SMTP id 98e67ed59e1d1-347331a7cbfmr7047169a91.4.1763849691172; Sat, 22 Nov 2025 14:14:51 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.14.50 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:14:50 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 10/21] rust-target-config: fix nativesdk-libstd-rs build with baremetal Date: Sat, 22 Nov 2025 14:14:16 -0800 Message-ID: <4c3f321304f2aa8b75cb58699b59fea80a23690c.1763849517.git.steve@sakoman.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:14:53 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226708 From: Ovidiu Panait If TCLIBC='baremetal' is set in local.conf, nativesdk-libstd-rs build fails with: | error[E0412]: cannot find type `c_char` in the crate root | --> /usr/src/debug/libstd-rs/1.75.0/rustc-1.75.0-src/vendor/libc/src/unix/mod.rs:56:29 | | | 6 | pub type c_schar = i8; | | ---------------------- similarly named type alias `c_schar` defined here | ... | 56 | pub gr_name: *mut ::c_char, | | ^^^^^^ This happens because rust_gen_target() sets os="none" when TCLIBC is 'baremetal' - even for nativesdk targets. However, nativesdk packages are built against glibc, so the correct 'os' value should be "linux". Fix this by setting the os field based on {TARGET,HOST,BUILD}_OS variables, as it is already done in rust_base_triple(), instead of relying on TCLIBC. Signed-off-by: Ovidiu Panait Signed-off-by: Mathieu Dubois-Briand Signed-off-by: Richard Purdie (master rev: 3eaf2cd5647585a1e6df03fc20e2753da27bb692) -- backport Signed-off-by: Stefan Ghinea Signed-off-by: Steve Sakoman --- meta/classes-recipe/rust-target-config.bbclass | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/meta/classes-recipe/rust-target-config.bbclass b/meta/classes-recipe/rust-target-config.bbclass index 1bd7626bd8..31b4bd9afd 100644 --- a/meta/classes-recipe/rust-target-config.bbclass +++ b/meta/classes-recipe/rust-target-config.bbclass @@ -329,6 +329,7 @@ def rust_gen_target(d, thing, wd, arch): sys = d.getVar('{}_SYS'.format(thing)) prefix = d.getVar('{}_PREFIX'.format(thing)) rustsys = d.getVar('RUST_{}_SYS'.format(thing)) + os = d.getVar('{}_OS'.format(thing)) abi = None cpu = "generic" @@ -368,7 +369,7 @@ def rust_gen_target(d, thing, wd, arch): tspec['target-c-int-width'] = d.getVarFlag('TARGET_C_INT_WIDTH', arch_abi) tspec['target-endian'] = d.getVarFlag('TARGET_ENDIAN', arch_abi) tspec['arch'] = arch_to_rust_target_arch(rust_arch) - if "baremetal" in d.getVar('TCLIBC'): + if "elf" in os: tspec['os'] = "none" else: tspec['os'] = "linux" From patchwork Sat Nov 22 22:14:17 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75232 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 DA696CFD306 for ; Sat, 22 Nov 2025 22:15:03 +0000 (UTC) Received: from mail-pj1-f45.google.com (mail-pj1-f45.google.com [209.85.216.45]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.3757.1763849694281912262 for ; Sat, 22 Nov 2025 14:14:54 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=QDIKd+dO; spf=softfail (domain: sakoman.com, ip: 209.85.216.45, mailfrom: steve@sakoman.com) Received: by mail-pj1-f45.google.com with SMTP id 98e67ed59e1d1-340bcc92c7dso2534536a91.0 for ; Sat, 22 Nov 2025 14:14:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849693; x=1764454493; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=5LA3KRtSe4TPlAYsxPz0Vp8mdnzB6kqPgnEur2GUJw4=; b=QDIKd+dOwkDtWIoSDsfCjFICuCLxMrlpxAb+QIdD3IeqrijumCk5RzWPEct/3IIXx4 9IUjrae0UwYpPGbsQM2+MKL5MbAPOjO/jNkYmUZ4XA/uG2BFqRCaO4ERBV1LIvqzSE/E E1OYMBIAK9102GyIzPlUdz8VbgjG/V9mDUHqr74xhCY8rX8fi58RKQcoYOy7v8Nu+5yi mMcbieTLxk62VlhuPxtDxRykAejYgeop/H07jFe7eRJe7Aky1QZeCb9UB9YdpambXc4r PmZaGoTjBuyFIum19sHg4kPaWKbGGfECjwdZOCzPDY5qSAxAasTxLgFWeCf50PJ7pCtw gyvw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849693; x=1764454493; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=5LA3KRtSe4TPlAYsxPz0Vp8mdnzB6kqPgnEur2GUJw4=; b=veL2beaT13SgOf0/KjaR9Be84livk/Ws5xze7vwUvDSaLX3QAz73Bz0of2x/fp1/af vRoOp8R4jW/HkttObk28TvalkCUSav3NHQMWo6T+QruPRJtSUDDfjbvcYXkdEkuN8aQf +THb8RQ4FzCMg1arPpMfhryxosDgUofVhlXaYCD4kD0QZ+QHQYUfFG1W7+uBCOmGjjB+ IA+ABeIY2CZPdt2EdPYWr5evT474ROmvsdWyb0CY/eF5ahw/lvsdkaNYJ6SqihrQ+cie qO0Vv1K4i5pSA3fOtKvzHdK8BgpO3W6Xq2S4cXt8R8s8CoTe9jiiWnKniAvaYx6XEZ2l RxWQ== X-Gm-Message-State: AOJu0Yx9vT4BI/lXAI5tuhU4QMtNCGG/q6mpR4upHDn/HH5jxsqAuiOQ Rn2tYtwMPQtlr9HzFLYvjwufdUuT3X1qphwBn71cqlyn5SsbPzLr0v24Xmyz6SAW1TBII1uvZBe 5AT6c X-Gm-Gg: ASbGnctlKp9yPW3ls33brpfTJYVwFnG8q2LmnWgiZ5/RzxbQ0M9VMol5H/WQiCKL48n Pv1f2WDgNW53QshZK2eTZQpebrVFW0nHUJOiaxqib4CHFYsICPjSyihAi0g1bQNWAu/rsz6/uqR PNkzxKbulv7JMkYYI6hIUcy0DiDEDgxWNG7V0CwQ5S4KUlWb4HL6IR+KeqXGfOn5btGgeatAxk1 YING4fqgpDwd83PoQ9DJ30ihUmOFYM8rRj0gNKRSoEFIK1oZDtMrTSf0AeBxz9IEUjokmz933c5 bwXq8W1mm0+L/DBrIaNxVaFMokhFpJUCzocVDSSoR1rbwdm0KeC2Tkk9oBuchGtdx3tqYxJTRFb UB8Oo4/9HM4LpTwCCOJJp9JEN4VrH33OEWZDPE0UgM1PvNUK0CHrPrHFP1UHuqWfSNr/00LvFS7 e5BQ== X-Google-Smtp-Source: AGHT+IFxxjpI2DuA09hQ+rKZVeNRyKtgpBkurZmvGs68SMcsnL8Tkrzj/LozPG5szNEJ5/GUYmtEsQ== X-Received: by 2002:a17:90a:dfcb:b0:343:7711:127d with SMTP id 98e67ed59e1d1-347298a9fabmr11333183a91.9.1763849693535; Sat, 22 Nov 2025 14:14:53 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.14.52 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:14:52 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 11/21] glslang: fix compiling with gcc15 Date: Sat, 22 Nov 2025 14:14:17 -0800 Message-ID: X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:15:03 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226709 From: Gyorgy Sarvari Backport a patch that fixes a compilation failure with gcc15: | .../git/SPIRV/SpvBuilder.h:238:30: error: ‘uint32_t’ has not been declared | 238 | Id makeDebugLexicalBlock(uint32_t line); | | ^~~~~~~~ | .../git/SPIRV/SpvBuilder.h:64:1: note: ‘uint32_t’ is defined in header ‘’; this is probably fixable by adding ‘#include ’ Signed-off-by: Gyorgy Sarvari Signed-off-by: Steve Sakoman --- ...uilder.h-add-missing-cstdint-include.patch | 30 +++++++++++++++++++ .../glslang/glslang_1.3.275.0.bb | 1 + 2 files changed, 31 insertions(+) create mode 100644 meta/recipes-graphics/glslang/glslang/0001-SPIRV-SpvBuilder.h-add-missing-cstdint-include.patch diff --git a/meta/recipes-graphics/glslang/glslang/0001-SPIRV-SpvBuilder.h-add-missing-cstdint-include.patch b/meta/recipes-graphics/glslang/glslang/0001-SPIRV-SpvBuilder.h-add-missing-cstdint-include.patch new file mode 100644 index 0000000000..02b072c56a --- /dev/null +++ b/meta/recipes-graphics/glslang/glslang/0001-SPIRV-SpvBuilder.h-add-missing-cstdint-include.patch @@ -0,0 +1,30 @@ +From e40c14a3e007fac0e4f2e4164fdf14d1712355bd Mon Sep 17 00:00:00 2001 +From: Sergei Trofimovich +Date: Fri, 2 Aug 2024 22:44:21 +0100 +Subject: [PATCH] SPIRV/SpvBuilder.h: add missing include + +Without the change `glslang` build fails on upcoming `gcc-15` as: + + In file included from /build/source/SPIRV/GlslangToSpv.cpp:45: + SPIRV/SpvBuilder.h:248:30: error: 'uint32_t' has not been declared + 248 | Id makeDebugLexicalBlock(uint32_t line); + | ^~~~~~~~ + +Upstream-Status: Backport [https://github.com/KhronosGroup/glslang/commit/e40c14a3e007fac0e4f2e4164fdf14d1712355bd] +Signed-off-by: Gyorgy Sarvari +--- + SPIRV/SpvBuilder.h | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/SPIRV/SpvBuilder.h b/SPIRV/SpvBuilder.h +index b1ca6ce1..00b2e53a 100644 +--- a/SPIRV/SpvBuilder.h ++++ b/SPIRV/SpvBuilder.h +@@ -56,6 +56,7 @@ namespace spv { + } + + #include ++#include + #include + #include + #include diff --git a/meta/recipes-graphics/glslang/glslang_1.3.275.0.bb b/meta/recipes-graphics/glslang/glslang_1.3.275.0.bb index 2fd1e72a26..b688b3df48 100644 --- a/meta/recipes-graphics/glslang/glslang_1.3.275.0.bb +++ b/meta/recipes-graphics/glslang/glslang_1.3.275.0.bb @@ -11,6 +11,7 @@ LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=2a2b5acd7bc4844964cfda45fe807dc3" SRCREV = "a91631b260cba3f22858d6c6827511e636c2458a" SRC_URI = "git://github.com/KhronosGroup/glslang.git;protocol=https;branch=main \ file://0001-generate-glslang-pkg-config.patch \ + file://0001-SPIRV-SpvBuilder.h-add-missing-cstdint-include.patch \ " PE = "1" # These recipes need to be updated in lockstep with each other: From patchwork Sat Nov 22 22:14:18 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75234 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 F0EBDCFD30D for ; Sat, 22 Nov 2025 22:15:03 +0000 (UTC) Received: from mail-pl1-f173.google.com (mail-pl1-f173.google.com [209.85.214.173]) by mx.groups.io with SMTP id smtpd.msgproc01-g2.2713.1763849696486635896 for ; Sat, 22 Nov 2025 14:14:56 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=z6glJBsQ; spf=softfail (domain: sakoman.com, ip: 209.85.214.173, mailfrom: steve@sakoman.com) Received: by mail-pl1-f173.google.com with SMTP id d9443c01a7336-297d4ac44fbso22058625ad.0 for ; Sat, 22 Nov 2025 14:14:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849696; x=1764454496; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=4nRXQHFaeYOURFecxtFFrJY2AtQmjLL41cHBS3ZA6dU=; b=z6glJBsQsfWiRbhMbG1Z8r9cgaNQ/5fCffW5BO1BT6JXxgttSAQFxyXj7bbeiKJdce l/WM3s8zeEWdPOVIFFk5n/oQ83WOgUGYyNHyrXASHP9hlU9vbISpjAVY/dSW5XQ6jT7U vRyLXs0E4uRxkTWVfUAq90CLOrA4j6b9v3ApXOiSijtBIcCYZ2yXfCozW+Bb59O8YYha nBuVc0HsCT+uWCMJVW32IMA+qu0QvnIk/7ttrf6eLe7143RzIlcMND1r+K2+pcvBBueL MmrS6bOhvrK3/OxoNiYqLK9ihX0r+gWcEPeFgP8vqLy7v4zIjdgZl5Nn/6ch1bew/axs rMZg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849696; x=1764454496; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=4nRXQHFaeYOURFecxtFFrJY2AtQmjLL41cHBS3ZA6dU=; b=g5FtE48q8dWRETqlHb6qtkrGDbdJLjYNQ9noqV3zOZdnKMGBQ8xL7itR/6vg7stse9 YkBppWXXmasb77KEesuVfqibKt1b8GpHXldzD6PbKD+teBfwjshVz1X+05xagptpflPm AyxFu9ZztlwnSXSmApB81/+aE95RSLL13L14PDOv99ZtlfHKfKYENFgGi989oSUT3K2e XhCFfUApqm0XLCn4JaRcywWN77ULe0oy1m3qz77MyCtvhdgpX1qWMhWsaAlBUfy2jB8s +pmW1PuvC2w9pc8EzoGLUg42/JSeoxy1NLGq/65FRPSHgAqx8X9Cg6OA0e6ZVvJ35JSg SUng== X-Gm-Message-State: AOJu0YzPhaASfiHZ6cUFg54u/Q+6XiJiU4pCH3MhSYNnhr5vfYcWEcLk ZhVFz5sS19kka4lbFAUREIZu1iO4JamNfCU4L5Tnyu15I8J91KCwBlcIVr/uQSEAn5Id5ejVO/b jTGAn X-Gm-Gg: ASbGncvzLqpnAblZhH4Rmlb6MDLbvUTgJXjp3VwlEIt/MRBwunGdFMzL8vYmPurgYLv BL5kEe+e2+mFFW/0FxT0yUCHz6yg7GuTTSi0Irkp14AwjDMWBxM8z4Pk1YDNRmho11279BSTqPP EDAQD8OsjG6Gyuz7jAYyoF4Tae3qEKtcTkjPuShXrgazegiPxkFbpuspAZApwHcJDgik9kRvu30 yLvgKhk7rOo1Vt0O1EGtKoiueNUb+ck4vYEfko28jjhcEoXMPbGz7aEXQJcXVB7gnCsGrEriZgN R6PSdLkjSmIpGGFIwMGTKLRsp/uhzN/MO2zduXPZ/cpG8kQU6T/C+VPP+87vlpAZ1OmLMw4PD3B fNSRty6l5kU2GAC8iluio3/E9NZYk4e/Fr+GYyNZzQZSVJ1ggtJl43gnjnwSkIylVO7P51S6rhg 1zKQ== X-Google-Smtp-Source: AGHT+IFg/jeU41trBpvDGDApbp7DLlJMpxRk/6fXvAi8Yt2f+eVD19ohl/9hIxDh0ynB+vsvUnOxYg== X-Received: by 2002:a17:903:2450:b0:295:55fc:67a0 with SMTP id d9443c01a7336-29b5e2cdfa5mr127573605ad.2.1763849695720; Sat, 22 Nov 2025 14:14:55 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.14.54 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:14:55 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 12/21] testsdk: allow user to specify which tests to run Date: Sat, 22 Nov 2025 14:14:18 -0800 Message-ID: X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:15:03 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226710 From: Ross Burton Following the usage of TEST_SUITES in testimage, add TESTSDK_SUITES to specify the list of tests to execute. By default the variable is empty, which means to run all discovered tests. This makes it easier to work on a single test without having to run all of the tests. (From OE-Core rev: 28d437c52c77889b2ede0fc2f2d6777c5b0a553d) Signed-off-by: Ross Burton Signed-off-by: Richard Purdie Signed-off-by: Peter Marko Signed-off-by: Steve Sakoman --- meta/classes-recipe/testsdk.bbclass | 3 +++ meta/lib/oeqa/sdk/testsdk.py | 3 ++- meta/lib/oeqa/sdkext/testsdk.py | 3 ++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/meta/classes-recipe/testsdk.bbclass b/meta/classes-recipe/testsdk.bbclass index fd82e6ef41..59d2834c99 100644 --- a/meta/classes-recipe/testsdk.bbclass +++ b/meta/classes-recipe/testsdk.bbclass @@ -14,6 +14,9 @@ # # where "" is an image like core-image-sato. +# List of test modules to run, or run all that can be found if unset +TESTSDK_SUITES ?= "" + TESTSDK_CLASS_NAME ?= "oeqa.sdk.testsdk.TestSDK" TESTSDKEXT_CLASS_NAME ?= "oeqa.sdkext.testsdk.TestSDKExt" diff --git a/meta/lib/oeqa/sdk/testsdk.py b/meta/lib/oeqa/sdk/testsdk.py index 518b09febb..52b702b6a2 100644 --- a/meta/lib/oeqa/sdk/testsdk.py +++ b/meta/lib/oeqa/sdk/testsdk.py @@ -114,7 +114,8 @@ class TestSDK(TestSDKBase): host_pkg_manifest=host_pkg_manifest, **context_args) try: - tc.loadTests(self.context_executor_class.default_cases) + modules = (d.getVar("TESTSDK_SUITES") or "").split() + tc.loadTests(self.context_executor_class.default_cases, modules) except Exception as e: import traceback bb.fatal("Loading tests failed:\n%s" % traceback.format_exc()) diff --git a/meta/lib/oeqa/sdkext/testsdk.py b/meta/lib/oeqa/sdkext/testsdk.py index 9d5a99d900..6dc23065a4 100644 --- a/meta/lib/oeqa/sdkext/testsdk.py +++ b/meta/lib/oeqa/sdkext/testsdk.py @@ -82,7 +82,8 @@ class TestSDKExt(TestSDKBase): host_pkg_manifest=host_pkg_manifest) try: - tc.loadTests(OESDKExtTestContextExecutor.default_cases) + modules = (d.getVar("TESTSDK_SUITES") or "").split() + tc.loadTests(OESDKExtTestContextExecutor.default_cases, modules) except Exception as e: import traceback bb.fatal("Loading tests failed:\n%s" % traceback.format_exc()) From patchwork Sat Nov 22 22:14:19 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75236 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 E4B70CFD30B for ; Sat, 22 Nov 2025 22:15:03 +0000 (UTC) Received: from mail-pj1-f52.google.com (mail-pj1-f52.google.com [209.85.216.52]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.3758.1763849698323254184 for ; Sat, 22 Nov 2025 14:14:58 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=txvIvm8p; spf=softfail (domain: sakoman.com, ip: 209.85.216.52, mailfrom: steve@sakoman.com) Received: by mail-pj1-f52.google.com with SMTP id 98e67ed59e1d1-340ba29d518so1875401a91.3 for ; Sat, 22 Nov 2025 14:14:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849697; x=1764454497; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=xQH3POWnsEtmguhWdq4cXxWSSGkWEiQvKzpghcI3+EU=; b=txvIvm8pRXMuiOo9bzwA/bRlm3tGZjke3hs6RdIMH8TNdiBuMe9h5VMHGdhHcol/nC KGiuc4Oq41FM4v343T5jDWtxmJ2HW+LU6RArd5adEXwfzlYqTvhoc8XPEYhzOV/boiBa TL5wnGK3U4MEg1ybgl7jW82k/elT67OAG+WjAYW9x1nCc9IucXoV7JfVrU8u3nGdaI0d Wj6CxYfbaA5Im9B7IMh6ebKhtMSirh3I9y4k1+nNDV6/HlhIBxZHyRMYuE8QQDm8ktdV QmLcqOyTE1F5T84Z/UMfFeqQ+xiovn6L7BvEY+8JW96J/0OjpqtEWidt0uCVPszxxtAm qMNw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849697; x=1764454497; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=xQH3POWnsEtmguhWdq4cXxWSSGkWEiQvKzpghcI3+EU=; b=MCWVWLtabuGShA/TPWIBDzEMuX8ODIS3rfG1ElKpiSZ4lC9jxjXA7vazRSkGJRecDD PciEAfcu9mqfmmkpYv78EWWbJIOInmxOGDKmHyb2HFhesomfm9X93qCNowk2dmoyRCLG AkwVYPSq10zfmllilQzAVEd0+UtJrFde2fJ9UYbkbyJhfbKmT2f7A68rD3E+ptVAmfK7 9LzuWJLoH8Li2hjnJUUSRArCLpmi1mBkENpCiwomYWXVtjpkVpm4q1exXLfNvO3sZ3h3 yzBBqgcQgJshOyHw4WXVqANiHx3roNtnAXmENBXHAbqIOQYMJA/epNqFOAkdYPpqdFJY s6Ig== X-Gm-Message-State: AOJu0YwveTf3MymgfH0mu97t8Kzpin3176tHS58arL0SvHBfdNCtbnpD H/8bXs0RbQBJxEiTvNM7SzRlA7HCiPMLs9NxTjnAyGB+1AiAiU6R2KmIlqz0RoeFiHffFiQ00t4 HSMkT X-Gm-Gg: ASbGncujtPpdkIP6t7jE4ikCzPQTrygSHq8AAxv037ZPi788A91f62Y9SUgFk5fxbVT WhRPWNR/3X7/LsR2KcHyKh0e58NEubK03lbdUIIrK8frZ0r2FdqU6YevlMYUJiefkLDDbar36Ko j7qAeVDhQ734EqdjFsSTLuRDKlFgS5grUd2Wz6S05vr5Ty+nlr7iz395eHLlEaxvN3PoZCu/LsM k80+qxh09tLXZjTuDVG4pKDh3kSuPLFpQYyTKCdYUJVzlJJRrnbXoETNQyjE1u9IKPr642RxG61 Nh3t7oSyffDQEx406Uvnunc6YbLrV9HFsJZF+kd0iPHXqQy6Fm1O7a7JQpnd5gy/wIZ1I7WcQxS GKMje2Fby9RSJkv6wkKlYhwCqOECVhDo6CGt83SU4+ebI1ngtfbwNCmewDbDTx9+1TO68Kn8MEA sLYQ== X-Google-Smtp-Source: AGHT+IFnnvfvIXAXw5RsUOo+LTqpn9ViEPEuBQEw480MB7HpsnbqzP0mH6CZRTBZmVvTGRZl/woTdA== X-Received: by 2002:a17:90b:4c0f:b0:32e:9da9:3e60 with SMTP id 98e67ed59e1d1-34733f54393mr7288847a91.36.1763849697491; Sat, 22 Nov 2025 14:14:57 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.14.56 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:14:57 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 13/21] oe/sdk: fix empty SDK manifests Date: Sat, 22 Nov 2025 14:14:19 -0800 Message-ID: <062a525bd36c672f372dabe8d9f0fbe355c7e58b.1763849517.git.steve@sakoman.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:15:03 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226711 From: Ross Burton The SDK manifests are generated by listing the sstate was that used, but it hardcodes that the sstate data filenames end in .tgz. This has not been the case since sstate switched to Zstd[1] in 2021, which meant that all of the tests which checked for packages existing were being skipped as the manifests were empty. For example, see a representative core-image-sato eSDK test run[2]: RESULTS - cmake.CMakeTest.test_assimp: SKIPPED (0.00s) RESULTS - gtk3.GTK3Test.test_galculator: SKIPPED (0.00s) RESULTS - kmod.KernelModuleTest.test_cryptodev: SKIPPED (0.00s) RESULTS - maturin.MaturinDevelopTest.test_maturin_develop: SKIPPED (0.00s) RESULTS - maturin.MaturinTest.test_maturin_list_python: SKIPPED (0.00s) RESULTS - meson.MesonTest.test_epoxy: SKIPPED (0.00s) RESULTS - perl.PerlTest.test_perl: SKIPPED (0.00s) RESULTS - python.Python3Test.test_python3: SKIPPED (0.00s) All of those tests should have been ran. Solve this by generalising the filename check so that it doesn't care what specfic compression algorithm is used. [1] oe-core 0710e98f40e ("sstate: Switch to ZStandard compressor support") [2] https://autobuilder.yoctoproject.org/valkyrie/#/builders/16/builds/1517/steps/15/logs/stdio Signed-off-by: Ross Burton Signed-off-by: Richard Purdie Signed-off-by: Peter Marko Signed-off-by: Steve Sakoman --- meta/lib/oe/sdk.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/meta/lib/oe/sdk.py b/meta/lib/oe/sdk.py index 3dc3672210..588c74bb44 100644 --- a/meta/lib/oe/sdk.py +++ b/meta/lib/oe/sdk.py @@ -148,7 +148,8 @@ def get_extra_sdkinfo(sstate_dir): extra_info['filesizes'] = {} for root, _, files in os.walk(sstate_dir): for fn in files: - if fn.endswith('.tgz'): + # Note that this makes an assumption about the sstate filenames + if '.tar.' in fn and not fn.endswith('.siginfo'): fsize = int(math.ceil(float(os.path.getsize(os.path.join(root, fn))) / 1024)) task = fn.rsplit(':',1)[1].split('_',1)[1].split(',')[0] origtotal = extra_info['tasksizes'].get(task, 0) From patchwork Sat Nov 22 22:14:20 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75235 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 E4B1ECFD30A for ; Sat, 22 Nov 2025 22:15:03 +0000 (UTC) Received: from mail-pj1-f42.google.com (mail-pj1-f42.google.com [209.85.216.42]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.3760.1763849700169161339 for ; Sat, 22 Nov 2025 14:15:00 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=rgMo99k0; spf=softfail (domain: sakoman.com, ip: 209.85.216.42, mailfrom: steve@sakoman.com) Received: by mail-pj1-f42.google.com with SMTP id 98e67ed59e1d1-343ff854297so4550816a91.1 for ; Sat, 22 Nov 2025 14:15:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849699; x=1764454499; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=HQQkxxwegfgWVnTuDSPtAgw+CpT9zuVIxxU/Lb1lJ2U=; b=rgMo99k0XmKmz8EsWPonIpQj4xXAbsEEcfpTX/XZl9Gqm9ngSGkONRAnjlh1mWhACT OrndZ8tg6x6Sn8/DHgzVUpPCuGi2cSjSUlyDVsKKR0K8eRsrm6E0YgJbeyoDedrB7Raj VGUPz3QpWR2hryXnNQM1msdqZQUz7DSnKoL4cLvaagvtoDYld6OHL0sPLpR64prZS1tb retiwvvUVjiYoPPyvqVqEk9uFtTnaPWR7c8kdev4TRYm0ltylwMc0gbONZt/Jko+TFkh W3cKEG9BFPKJMiqP6sUaKQBuWXvNqroFI44Il8sQrk3pwQdbVB5ee1uln0Wln7wmn9xq aKkw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849699; x=1764454499; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=HQQkxxwegfgWVnTuDSPtAgw+CpT9zuVIxxU/Lb1lJ2U=; b=JvgWi7ud6Pmcv/yy96IZsCtPhXNv5t4oKG/Aai7uQu4ukUhmwM4bXNFenXCuk0SHyQ k2fLHMtA+tIzDWJicTgI121El8zgMbeB5i0SmiQhfcMpTlkMSOuoq/Yk31Lwa2yNp3LR ZDDkZt2SKRafB53Xif0PIec1S76L4OtJHXFPyBNEdgH20xoonWKgFzIEX9tyeh5JV+P1 JaTD034iczVXxcu1/hBZ8l6KN1VQQxCVkzmQYUpVS419NFwEZzIpZJ+PTndkVoEFMW1S W0gJK/0RR5facbQ5lIMm6AJ8Rc20HhERLevmqbVsNCKbbrre1r3SwKiIFkbkoDYT4v9Y WJ4A== X-Gm-Message-State: AOJu0YxBuF4MiAT60YOeYZ9ZOTqoWYoob6LIvgMMdAQOMnaafdz56oag sn9j1Y5uPF7tTLsx7t7Y4DvT4YhSiykxRwNslF/lWsjz3xmgKnhrzs+e3PqeFKyfT97mjEHYtI8 R9dxE X-Gm-Gg: ASbGnctxgu9jHBs1uSC1lPucxCAUb/krygzWTjDgHHifklKgvAvHKgYeJTNTjoUic1A DY8Ogp0y3V3xEVQxsmBzAz0sfffS5IN/r3i2kQiERIu+eXF5uytB9JjL3EOA3owJ2zmwnIz2ezA 4nvloWtfUfCXncDFhBOLYIjVsIIu9z/xidYioQ06kqGJQjnnt1HlIMvx02F4UKBXShrzTyWcI+L HhmnRHV45w0LgCfiVHCq+s9Jchwpt13HqGywFByuap4JwZAJPX4wRu8rSq25LKooniNvZfvdXYd oVXq3jsvn1KX93yVSzU2AGDv+Iw90uQjSIYUHLS+eaeMYwpy2HOI/rr2H16O6lch2EUvfSUr07i euvXAsbSshtRzTYs2qUksCq5jszbC1kKITIpCwEUx4kqkl/3UXjvpMTQnTTR+EruYIvDETGbP0N wsDQ== X-Google-Smtp-Source: AGHT+IHfs3TcXoIReOAjG1QcGbxjUYbgYahLTupWQvzrvBLaRPyPPbQyu65aVqwbMLhf7e8Y+HOCGQ== X-Received: by 2002:a17:90b:524b:b0:340:b86b:39c7 with SMTP id 98e67ed59e1d1-34733e725c9mr7010567a91.11.1763849699422; Sat, 22 Nov 2025 14:14:59 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.14.58 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:14:58 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 14/21] lib/oe/go: document map_arch, and raise an error on unknown architecture Date: Sat, 22 Nov 2025 14:14:20 -0800 Message-ID: X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:15:03 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226712 From: Ross Burton Add a comment explaining what this function does and where the values come from. If the architecture isn't know, instead of returning an empty string which could fail mysteriously, raise a KeyError so it fails quickly. (From OE-Core rev: 025414c16319b068df1cd757ad9a3c987a6b871d) Signed-off-by: Ross Burton Signed-off-by: Richard Purdie Signed-off-by: Peter Marko Signed-off-by: Steve Sakoman --- meta/lib/oe/go.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/meta/lib/oe/go.py b/meta/lib/oe/go.py index dfd957d157..4559dc63b2 100644 --- a/meta/lib/oe/go.py +++ b/meta/lib/oe/go.py @@ -7,6 +7,10 @@ import re def map_arch(a): + """ + Map our architecture names to Go's GOARCH names. + See https://github.com/golang/go/blob/master/src/internal/syslist/syslist.go for the complete list. + """ if re.match('i.86', a): return '386' elif a == 'x86_64': @@ -31,4 +35,4 @@ def map_arch(a): return 'riscv64' elif a == 'loongarch64': return 'loong64' - return '' + raise KeyError(f"Cannot map architecture {a}") From patchwork Sat Nov 22 22:14:21 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75233 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 DA6D6CFD307 for ; Sat, 22 Nov 2025 22:15:03 +0000 (UTC) Received: from mail-pj1-f41.google.com (mail-pj1-f41.google.com [209.85.216.41]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.3762.1763849702087816495 for ; Sat, 22 Nov 2025 14:15:02 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=Cq8XDsmo; spf=softfail (domain: sakoman.com, ip: 209.85.216.41, mailfrom: steve@sakoman.com) Received: by mail-pj1-f41.google.com with SMTP id 98e67ed59e1d1-343ff854297so4550840a91.1 for ; Sat, 22 Nov 2025 14:15:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849701; x=1764454501; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=U+gzd/DMuSGBeEynG30623maZXbrdVrV1SoCupExdwA=; b=Cq8XDsmoRFZmqterhvaJ9Z3a9FOYgexD1xijgXLIjNhLza/Kj5BJ9+CL1IsICMe8+K KRfWAiBCqkRvVg2slULIPwJE5aRGDGYlUeTHMGVaobwvCfgG3aA87HKMTBW59N/omX5l 7CtRDkYdKjzI5uzp0mx34p8KL/CWR8ciYnHE7tnRhk/ioqqiJgu7xpaIYMjBSi1lAAs/ YxD/1qmIktDGtaqtvaN5FSDkDmSD2tQopyQsyPgToXJwvRHX5FinPkRBwAUWyZoLiE+Y RbNE1ZuToX4hq1AH+KthQ5FBX9WHVSh1mQ+X4LkTTN8l3cdUQjdb4mI51MzMC0VqD8Dt OdrQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849701; x=1764454501; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=U+gzd/DMuSGBeEynG30623maZXbrdVrV1SoCupExdwA=; b=nUaJkY6JUdlbcElN/1rsalNNOAEoPTWQrcN7tQdBRuPXqf8satD/X8LCeOJZBm1+CU 0XswN6WKTNrOQywjQ4FtssnXN959gpUXlOqE2G+2ywrBwZdwKAa8w6hDgrdi1fhRCP5v U8S2GL7cOGCyklfhR9u3LwRRHJH0lkKkBydH1aijJzykCY6gtY/SZl+KoT+VdWs8fkKp oN26W7zIvdeE48XdMbb40Y9mi/B53R1K4hayKKY9eJFlBFrspqiKed/LSH5pezrofovT Mh2FPvWVR7iT2Y1s6HdxmSff7kVuDNO7ugf+fVyI5a1/1ufZ0jLGsPbnOrHZZJsveXx5 3D+Q== X-Gm-Message-State: AOJu0YxYevNWBg2tGBWALDAKe08dinMK3Ocb4kX7EleGkDbgrlcOBLUW +VTB04DCjcNXi+NYDcQ5x11/V2INwhHohZ26/i8l2bdh5ypruqhC2Umg6DDkjV+H9NvEhSyOBNn GJojZ X-Gm-Gg: ASbGncs3TtX3mko3YzPHDUCsxT3SWQljm+oL4YsFvpjT6Dtfr+lRaq5X9mbxOISH/eg KEwyoDvLqD9g8GaMZ4c/QNPYqBBxCyJfnQCxSbXtNQ47xS/tI28Ueih2v2WguKprFbiUoQL5+Iz YyOgUBwE2yOQ4EGkpIEVERdI8GYo3yLDvH6Vuo0NBVJ488WdIMxXcvq3C5OH+Z6e6hCbMTdChSd AsB+e3/m/jWHY06ATpbKr13/6Oe73ShpSRNwP/8aRTGI1KwCclRmuAeFUD8STgbTuVodQBwW0aV iRWIUBMR894seNL3bl+U/HsafAkmTnvBmFplo9rpvcYdOloN9eXPQN3XI0T0evImw3Fjt5KW3b4 bL8WCTh2Rj789E7dfebqai4BPnwszVDdVGWb9bpjyrwLtH7FjmHebCLGrMQubirhyB1zw/qKBbB 2zUw== X-Google-Smtp-Source: AGHT+IHN8ZdFEj2qWOp8KpU6+YBk38JSj8fh7zh9J8HVXyP8Q+npEOJz7T9CGZUonMETQuHx4arrhw== X-Received: by 2002:a17:90b:3c8e:b0:340:ca7d:936a with SMTP id 98e67ed59e1d1-34733f22173mr8145736a91.18.1763849701351; Sat, 22 Nov 2025 14:15:01 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.15.00 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:15:01 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 15/21] goarch.bbclass: do not leak TUNE_FEATURES into crosssdk task signatures Date: Sat, 22 Nov 2025 14:14:21 -0800 Message-ID: X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:15:03 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226713 From: Alexander Kanavin The default assignments look like this: TARGET_GO386 = "${@go_map_386(d.getVar('TARGET_ARCH'), d.getVar('TUNE_FEATURES'), d)}" TUNE_FEATURES is a target-specific variable, and so should be used only for target builds. The change is similar to what is already done for native packages. (From OE-Core rev: cfff8e968257c44880caa3605e158764ed5c6a2a) Signed-off-by: Alexander Kanavin Signed-off-by: Mathieu Dubois-Briand Signed-off-by: Richard Purdie Signed-off-by: Peter Marko Signed-off-by: Steve Sakoman --- meta/classes-recipe/goarch.bbclass | 3 +++ 1 file changed, 3 insertions(+) diff --git a/meta/classes-recipe/goarch.bbclass b/meta/classes-recipe/goarch.bbclass index 1ebe03864f..0e9ef3a6ec 100644 --- a/meta/classes-recipe/goarch.bbclass +++ b/meta/classes-recipe/goarch.bbclass @@ -24,6 +24,9 @@ TARGET_GOMIPS = "${@go_map_mips(d.getVar('TARGET_ARCH'), d.getVar('TUNE_FEATURES TARGET_GOARM:class-native = "7" TARGET_GO386:class-native = "sse2" TARGET_GOMIPS:class-native = "hardfloat" +TARGET_GOARM:class-crosssdk = "7" +TARGET_GO386:class-crosssdk = "sse2" +TARGET_GOMIPS:class-crosssdk = "hardfloat" TARGET_GOTUPLE = "${TARGET_GOOS}_${TARGET_GOARCH}" GO_BUILD_BINDIR = "${@['bin/${HOST_GOTUPLE}','bin'][d.getVar('BUILD_GOTUPLE') == d.getVar('HOST_GOTUPLE')]}" From patchwork Sat Nov 22 22:14:22 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75238 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 EEE26CFD30B for ; Sat, 22 Nov 2025 22:15:13 +0000 (UTC) Received: from mail-pj1-f42.google.com (mail-pj1-f42.google.com [209.85.216.42]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.3766.1763849704496930246 for ; Sat, 22 Nov 2025 14:15:04 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=BWf+xc7R; spf=softfail (domain: sakoman.com, ip: 209.85.216.42, mailfrom: steve@sakoman.com) Received: by mail-pj1-f42.google.com with SMTP id 98e67ed59e1d1-3437af8444cso3357885a91.2 for ; Sat, 22 Nov 2025 14:15:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849704; x=1764454504; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=t2Wu5upEIt31uD6NYTGUXrMt1NMTgYemKiO1IPKfYkk=; b=BWf+xc7R4yg6V3kNYOjJrptpAgCaIoUJodNWUlMKDj2GMYQcvAR2WVNsCyGImYLMSi mejpwWQoAt2oJw+aSolIJ62t+fxIFGn3pD5npqZJra23xpxV9zCA+YeHI1EikFolgZgI srEI3A6v0G9lmnT7JQqUB2HPMM0ECBLCcxHgnoFmHzV8qeDIpe208p5Q9tUS8SjlJwVS ahcI63SSR+iRBh7HTVCCKBkjKNzFWlfNKcnhuLlbSFOSJq0G+kQ/BczDAIpIuhQ0h82I HjALJr2retSIvrQ/Fg0G1MVGj6enK0ViJm9SQICAe3uu0G7OOFaithcQmwezTFOqzdfE tvUg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849704; x=1764454504; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=t2Wu5upEIt31uD6NYTGUXrMt1NMTgYemKiO1IPKfYkk=; b=MENvnmjZAyWMRKv4nvA/8icTh+TN1bwdXDwkefewFgZWOsKsQq4tCLRQcCHkpvuPso YoKB4Imli2WfHaAFqm7aEfQIbtBS+swbP9rdHDqopBoNZo7UsMHDqj+Hfug2YI6LRT1/ ytqfsmzd/xlV4xcZcengt6PONOIdfqLbfGo/rGEm13avWRUkB2jp6RbwIS72Ah02W+tx PlxNf3C9lVfdftqKUYL5LXkL35ucArlr1G6FWCSLYqASdpJvF6aC/YV/SsdbDZCYn7y2 E1Aaua97As/mtj+w/XGu9O7DuS71beVb8GJNBWtIpUkBpwlSNgIesDdaSVFmnrgw2dWN nIhg== X-Gm-Message-State: AOJu0Ywe3Iv7SisQwCIk+uJPULRhITq4KB/Y3sGjCTCFFTnWGYe+98wG XO0vNLZQnlt58tTuR5RS4dZ2w/jYHdCuGscnPUzrKPsEZndF0sJeGYt2CV6nTsUVw+jEKMCOAgJ 3IFQb X-Gm-Gg: ASbGncsjiKi+1zTx4zXRJS4Jrt2JhAfiwn2nDh2TlWNUU7jxmXCfetfSkk12OS9SpOE lay7y9qdS3j1PWnMoEeifZ7joUaF+VSfVfqBKDqvuNz+LuJCiRQZKk2MJJk5iF2xWrqmC7Zy/E0 XzjTS8OIUa2y2/nWhdok9gXsPqZXQPfhQ2eTFabvOPDJ4NvhzCLQ2uv9pz3qx80L1LhO0YrOJC2 dk3+Axr10lyJ4/u2wthCOSZdLJygv2CG+kNDQDRVf8ZL/+2kqOCjGm2d47DlwW96ocy0YgZtmJq 37CiK2H2vKuBN580vU3NUzWie8zp8eFaP5gH/flsz/zdg8iswV6CekDeQ6o8rWmL5xvwAI1nz6L gonoD71RttrVx6lUfBFPf5N1ja68vNFQy3C92CbM9cE6AkKvIOdNwe/P8o8seYi9a/NxnZjBmxo NtHA== X-Google-Smtp-Source: AGHT+IHbmUFEr6Mltunj99J+0Av7igdzEYkZpWFclJgCNh3CwpJjnN1aw3tPvvq2++Mn60qK5HNY7w== X-Received: by 2002:a17:90b:1dd1:b0:341:8ca8:ae64 with SMTP id 98e67ed59e1d1-34733f51faamr7771860a91.35.1763849703660; Sat, 22 Nov 2025 14:15:03 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.15.02 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:15:02 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 16/21] go: add sdk test Date: Sat, 22 Nov 2025 14:14:22 -0800 Message-ID: <506f4e8c99b164673ba7d1c19e10d240f4df0376.1763849517.git.steve@sakoman.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:15:13 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226714 From: Osama Abdelkader - Add meta/lib/oeqa/sdk/cases/go.py with GoCompileTest and GoHostCompileTest classes - Test validates Go cross-compilation toolchain functionality - Includes native compilation, cross-compilation, and Go module support - Uses dynamic architecture detection for portability (From OE-Core rev: 17015f692a6bf3697a89db51bbc4673a5efa1497) Signed-off-by: Osama Abdelkader Signed-off-by: Mathieu Dubois-Briand Signed-off-by: Richard Purdie Signed-off-by: Peter Marko Signed-off-by: Steve Sakoman --- meta/lib/oeqa/sdk/cases/go.py | 128 ++++++++++++++++++++++++++++++++++ 1 file changed, 128 insertions(+) create mode 100644 meta/lib/oeqa/sdk/cases/go.py diff --git a/meta/lib/oeqa/sdk/cases/go.py b/meta/lib/oeqa/sdk/cases/go.py new file mode 100644 index 0000000000..9c15124f6a --- /dev/null +++ b/meta/lib/oeqa/sdk/cases/go.py @@ -0,0 +1,128 @@ +# +# Copyright OpenEmbedded Contributors +# +# SPDX-License-Identifier: MIT +# + +import os +import shutil +import unittest + +from oeqa.core.utils.path import remove_safe +from oeqa.sdk.case import OESDKTestCase + +from oeqa.utils.subprocesstweak import errors_have_output +errors_have_output() + +class GoCompileTest(OESDKTestCase): + td_vars = ['MACHINE', 'TARGET_ARCH'] + + @classmethod + def setUpClass(self): + # Copy test.go file to SDK directory (same as GCC test uses files_dir) + shutil.copyfile(os.path.join(self.tc.files_dir, 'test.go'), + os.path.join(self.tc.sdk_dir, 'test.go')) + + def setUp(self): + target_arch = self.td.get("TARGET_ARCH") + # Check for go-cross-canadian package (uses target architecture) + if not self.tc.hasHostPackage("go-cross-canadian-%s" % target_arch): + raise unittest.SkipTest("GoCompileTest class: SDK doesn't contain a Go cross-canadian toolchain") + + # Additional runtime check for go command availability + try: + self._run('which go') + except Exception as e: + raise unittest.SkipTest("GoCompileTest class: go command not available: %s" % str(e)) + + def test_go_build(self): + """Test Go build command (native compilation)""" + self._run('cd %s; go build -o test test.go' % self.tc.sdk_dir) + + def test_go_module(self): + """Test Go module creation and building""" + # Create a simple Go module + self._run('cd %s; go mod init hello-go' % self.tc.sdk_dir) + self._run('cd %s; go build -o hello-go' % self.tc.sdk_dir) + + @classmethod + def tearDownClass(self): + files = [os.path.join(self.tc.sdk_dir, f) \ + for f in ['test.go', 'test', 'hello-go', 'go.mod', 'go.sum']] + for f in files: + remove_safe(f) + +class GoHostCompileTest(OESDKTestCase): + td_vars = ['MACHINE', 'SDK_SYS', 'TARGET_ARCH'] + + # Architecture mapping from Yocto/Poky to Go + ARCH_MAP = { + 'aarch64': 'arm64', + 'cortexa57': 'arm64', # ARM Cortex-A57 is ARM64 + 'cortexa72': 'arm64', # ARM Cortex-A72 is ARM64 + 'cortexa53': 'arm64', # ARM Cortex-A53 is ARM64 + 'x86_64': 'amd64', + 'i586': '386', + 'i686': '386', + 'mips': 'mips', + 'mipsel': 'mipsle', + 'powerpc64': 'ppc64', + 'powerpc64le': 'ppc64le', + 'riscv64': 'riscv64', + } + + @classmethod + def setUpClass(self): + # Copy test.go file to SDK directory (same as GCC test uses files_dir) + shutil.copyfile(os.path.join(self.tc.files_dir, 'test.go'), + os.path.join(self.tc.sdk_dir, 'test.go')) + + def setUp(self): + target_arch = self.td.get("TARGET_ARCH") + # Check for go-cross-canadian package (uses target architecture) + if not self.tc.hasHostPackage("go-cross-canadian-%s" % target_arch): + raise unittest.SkipTest("GoHostCompileTest class: SDK doesn't contain a Go cross-canadian toolchain") + + # Additional runtime check for go command availability + try: + self._run('which go') + except Exception as e: + raise unittest.SkipTest("GoHostCompileTest class: go command not available: %s" % str(e)) + + def _get_go_arch(self): + """Get Go architecture from SDK_SYS""" + sdksys = self.td.get("SDK_SYS") + arch = sdksys.split('-')[0] + + # Handle ARM variants + if arch.startswith('arm'): + return 'arm' + + # Use mapping for other architectures + return self.ARCH_MAP.get(arch, arch) + + def test_go_cross_compile(self): + """Test Go cross-compilation for target""" + goarch = self._get_go_arch() + self._run('cd %s; GOOS=linux GOARCH=%s go build -o test-%s test.go' % (self.tc.sdk_dir, goarch, goarch)) + + def test_go_module_cross_compile(self): + """Test Go module cross-compilation""" + goarch = self._get_go_arch() + self._run('cd %s; go mod init hello-go' % self.tc.sdk_dir) + self._run('cd %s; GOOS=linux GOARCH=%s go build -o hello-go-%s' % (self.tc.sdk_dir, goarch, goarch)) + + @classmethod + def tearDownClass(self): + # Clean up files with dynamic architecture names + files = [os.path.join(self.tc.sdk_dir, f) \ + for f in ['test.go', 'go.mod', 'go.sum']] + # Add architecture-specific files using the same mapping + for arch in self.ARCH_MAP.values(): + files.extend([os.path.join(self.tc.sdk_dir, f) \ + for f in ['test-%s' % arch, 'hello-go-%s' % arch]]) + # Add 'arm' for ARM variants + files.extend([os.path.join(self.tc.sdk_dir, f) \ + for f in ['test-arm', 'hello-go-arm']]) + for f in files: + remove_safe(f) From patchwork Sat Nov 22 22:14:23 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75242 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 161BDCFD314 for ; Sat, 22 Nov 2025 22:15:14 +0000 (UTC) Received: from mail-pj1-f51.google.com (mail-pj1-f51.google.com [209.85.216.51]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.3769.1763849706486067922 for ; Sat, 22 Nov 2025 14:15:06 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=yItI+W28; spf=softfail (domain: sakoman.com, ip: 209.85.216.51, mailfrom: steve@sakoman.com) Received: by mail-pj1-f51.google.com with SMTP id 98e67ed59e1d1-343f52d15efso2881373a91.3 for ; Sat, 22 Nov 2025 14:15:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849706; x=1764454506; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=MzjsQQtJYMQioekYxe9GPABswCu5A3JFdvJpb/7sw+I=; b=yItI+W28VweQQOktMRQ1hzvUJVY/A4z6TlbXsIIAMWi/s2wGx9ycDaXBbCcD0+yT6V jNdMW49V6ACOXJWiOFNbepza2BYmDcAhEvBcr6sgji/Gs2oc7SS5MqURhp+HXkekfsUr UFt9LVuxSBdmnIRN/nCz8/CrmsIJEPBVTZWf16crHfySMOn4vgjpYxObItKiFa22t4Uc PW1zkqAeeT12sewUtSSDY0UWTXKZ1xoGuXylq8Y5tMZc7X1+Z8dM2JB81MIkV+HoowtW R5L25YP4VC8YK8nOW2EzXKdky0MYiCczKo1/dZ5dR7U08CF2Gf9nnllSExzDBftChCo0 Pufg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849706; x=1764454506; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=MzjsQQtJYMQioekYxe9GPABswCu5A3JFdvJpb/7sw+I=; b=E0E2CX0GUXUekbi9MNlrnSowwtX+kjiidSnejhMCuw/czw5HjZiNF9lVz2lHY0ZHIp t1L8Ue3BVI1kV+o6JHTeC4ukGOCWc/O3pq6gx6IX3/9KVPdl6xZkPcwyAIALeCCTOHpV vFq4Y5zz2m285KCQwFOOeeKdbn/7jErw6LTVosW/sty52bRrxXVlLnL1uMMCnbMJb+Qd WV2BNfaE8YymAhLPXRlAUBYQHD8GLivotGVu31Qbu6g4HtM8mqlfg4+U4k94mq7QJD6x eUMYpLnGNAV6bcjMvBBwL4kyLv+L0vAvePe9/qy7ZQqE8LCR+9o8f6Fj51WOsdtLMzy4 bOZw== X-Gm-Message-State: AOJu0YxpLZfthttZv+Cl86CEeVZrD8QqngcIvdhsZ0Kpvt6KSZGllA2M X5hbdx22oNWkiMlJivi9GY4LXmJWZ38h6FQL8T2p0eA6I/E3tYVkXkU5GPqX3sMz2KpagF7dI/N D47wG X-Gm-Gg: ASbGnctSI8RhGMydjMZb70/o5RDvykmV/S2R7hDdSOxY+eIp4QDaXm5Pc4aHLMRKQ3V uUf2ZoxSQRyzvuw4cQKUZdzVA6LycNch3x5rKK8eN0resxs0LEzb07pG0y9DukLrSFefXqb0R8X An80j54TdTxZTgRXl9DFTAzOQTdkd9aRrAL5UnLF5nvpfszlQ3wAY+/rxx4o85cfLGAvUloTq/J CqDSn6epHODPVimu1WSlHvW1/Nj2+ppq+/ImXSn4oyj9gUZ6Vj2D/z9ybnlLJixaW8BjoVz7nZG 5nUQ1AOEfxRtFktL8UdMiD6jczMrccMvyF3bKTmlTkJqndhr0vGbuk6tkYFVzhX0VYZ5G1Bt91a Br8VCRib9cdRKtRgIv5qHjourpY3UqQSOApSm8dCI0n5WbHlLclYHswEOHzRGg9nHleQ2Ny9Rox ejaQ== X-Google-Smtp-Source: AGHT+IEXD3sdCT44xh40QV0pM9UkYywhqYvbokCSsHEfWgPfHTho7CI7pSvYF2sVdXiOCLikzjIsYw== X-Received: by 2002:a17:90b:380a:b0:340:b152:efe7 with SMTP id 98e67ed59e1d1-34733e5934cmr6845712a91.11.1763849705698; Sat, 22 Nov 2025 14:15:05 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.15.04 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:15:05 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 17/21] go: extend runtime test Date: Sat, 22 Nov 2025 14:14:23 -0800 Message-ID: X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:15:14 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226715 From: Osama Abdelkader extend go runtime test with a simple test file, and simple go module test to validate go compilation and execution on target. (From OE-Core rev: e3b2b9170f76f4bbdc41ea6ba7bccffc17d01968) Signed-off-by: Osama Abdelkader Signed-off-by: Mathieu Dubois-Briand Signed-off-by: Richard Purdie Signed-off-by: Peter Marko Signed-off-by: Steve Sakoman --- meta/lib/oeqa/files/test.go | 7 ++++ meta/lib/oeqa/runtime/cases/go.py | 68 +++++++++++++++++++++++++++++++ 2 files changed, 75 insertions(+) create mode 100644 meta/lib/oeqa/files/test.go diff --git a/meta/lib/oeqa/files/test.go b/meta/lib/oeqa/files/test.go new file mode 100644 index 0000000000..9ca9302654 --- /dev/null +++ b/meta/lib/oeqa/files/test.go @@ -0,0 +1,7 @@ +package main + +import "fmt" + +func main() { + fmt.Println("Hello from Go!") +} diff --git a/meta/lib/oeqa/runtime/cases/go.py b/meta/lib/oeqa/runtime/cases/go.py index 39a80f4dca..fc7959b5f4 100644 --- a/meta/lib/oeqa/runtime/cases/go.py +++ b/meta/lib/oeqa/runtime/cases/go.py @@ -4,10 +4,78 @@ # SPDX-License-Identifier: MIT # +import os from oeqa.runtime.case import OERuntimeTestCase from oeqa.core.decorator.depends import OETestDepends from oeqa.runtime.decorator.package import OEHasPackage +class GoCompileTest(OERuntimeTestCase): + + @classmethod + def setUp(cls): + dst = '/tmp/' + src = os.path.join(cls.tc.files_dir, 'test.go') + cls.tc.target.copyTo(src, dst) + + @classmethod + def tearDown(cls): + files = '/tmp/test.go /tmp/test' + cls.tc.target.run('rm %s' % files) + dirs = '/tmp/hello-go' + cls.tc.target.run('rm -r %s' % dirs) + + @OETestDepends(['ssh.SSHTest.test_ssh']) + @OEHasPackage('go') + @OEHasPackage('go-runtime') + @OEHasPackage('go-runtime-dev') + @OEHasPackage('openssh-scp') + def test_go_compile(self): + # Check if go is available + status, output = self.target.run('which go') + if status != 0: + self.skipTest('go command not found, output: %s' % output) + + # Compile the simple Go program + status, output = self.target.run('go build -o /tmp/test /tmp/test.go') + msg = 'go compile failed, output: %s' % output + self.assertEqual(status, 0, msg=msg) + + # Run the compiled program + status, output = self.target.run('/tmp/test') + msg = 'running compiled file failed, output: %s' % output + self.assertEqual(status, 0, msg=msg) + + @OETestDepends(['ssh.SSHTest.test_ssh']) + @OEHasPackage('go') + @OEHasPackage('go-runtime') + @OEHasPackage('go-runtime-dev') + @OEHasPackage('openssh-scp') + def test_go_module(self): + # Check if go is available + status, output = self.target.run('which go') + if status != 0: + self.skipTest('go command not found, output: %s' % output) + + # Create a simple Go module + status, output = self.target.run('mkdir -p /tmp/hello-go') + msg = 'mkdir failed, output: %s' % output + self.assertEqual(status, 0, msg=msg) + + # Copy the existing test.go file to the module + status, output = self.target.run('cp /tmp/test.go /tmp/hello-go/main.go') + msg = 'copying test.go failed, output: %s' % output + self.assertEqual(status, 0, msg=msg) + + # Build the module + status, output = self.target.run('cd /tmp/hello-go && go build -o hello main.go') + msg = 'go build failed, output: %s' % output + self.assertEqual(status, 0, msg=msg) + + # Run the module + status, output = self.target.run('cd /tmp/hello-go && ./hello') + msg = 'running go module failed, output: %s' % output + self.assertEqual(status, 0, msg=msg) + class GoHelloworldTest(OERuntimeTestCase): @OETestDepends(['ssh.SSHTest.test_ssh']) @OEHasPackage(['go-helloworld']) From patchwork Sat Nov 22 22:14:24 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75240 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 08D97CFD30E for ; Sat, 22 Nov 2025 22:15:14 +0000 (UTC) Received: from mail-pj1-f41.google.com (mail-pj1-f41.google.com [209.85.216.41]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.3770.1763849708185669983 for ; Sat, 22 Nov 2025 14:15:08 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=i1PnDhdu; spf=softfail (domain: sakoman.com, ip: 209.85.216.41, mailfrom: steve@sakoman.com) Received: by mail-pj1-f41.google.com with SMTP id 98e67ed59e1d1-3438231df5fso4054378a91.2 for ; Sat, 22 Nov 2025 14:15:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849707; x=1764454507; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=XO1zrm+RRfPtxNRj/BgahNFVRxY8JE5GpXTVePvqwrQ=; b=i1PnDhduz6oaA60AownjlfXiaw7DZW0VaJYJYasUTCJ90v19pVFuYTB63ctQ3Zh+Mp gAA39p6m3JPONGxdmE4JjXzDxSxFX7GBu9Ts8gVtOG9xxyhnEu5wd1g72HCq9JUsP3Io sAx+W218grXRDsi4tURqwG/iAdXTjKmSSDfouZQXpshIiZj13We0OoChuCtnth9Hk0P8 qw2JH7krftxR+lCVEq1iXg8CPhD+F5u4w9L58No3lVDq2NQjQns526mSMcGz+KRocuvb qyt8uzrmp8z/iQGPhGU5jhMlh6adskhaqWWRuqqZnQXU/5siBIN61yOPckKiUzTFLQgo eXSg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849707; x=1764454507; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=XO1zrm+RRfPtxNRj/BgahNFVRxY8JE5GpXTVePvqwrQ=; b=k6rAnYSSshN0A+L7PhsR6g75Ui5BtmAUjD6KGCkWsGAOK5HVnFhfeFbT7BJfucJicV 1Ya8HJBkwLs3C4lxunFfOy45VUKnSwOyoxJQX4kf0gjQcp8/XlHQMvWvYQoe7nR3h4gd WPJNP4gRYzHfAjGc8LznI7NmlV+2HUvQkKvQc9ylcG1uvsVRPa2K+ne6e5+44Pwd353f iDuNcSuPl10W508u4AKNlP47O6n5db95mn49NDmddR5wrjrawv8iW4yYkOyYybcFuLJC gWPyJPPBIx21bWaN2HtmFHEb5nI33Zf/FcK32trRr3JgozUre13UYrod/gldUyTnBpDu TVRg== X-Gm-Message-State: AOJu0Yyoh4L2I2/MIKWIA26LqAIkq+rYZuIFGkyDphWijlik46oXe6Br FsA0zYSxU3G5gO6DrtmPQPrD7e2w8wAdy33GZr7yItLHIcLQbafU7Xq7CsieqSjDHxg6piutZG1 B1KPJ X-Gm-Gg: ASbGncvky6JzJb8TN/n2Q2fn5qrq/TUFjJC+92InmZOgvQS7v1zNnAKh1hLaRgfFmpd 2qX088wLD1BDI28nXz20GSmT2SSVxh9GK6kSzLLJ3Yxq8/42c5SB7rqVY7Q3bqD57p+HyLhLl08 3V96RgPxWfcb8lnJWcL1AHkQ+9V6JlbdHgD5xT34oddQRdtg3sqdi/k0a8wrohvtxnOP8HawGjd GLIe2ZcohIiXQrZovxe/nHVI7c/lCQ7ynY9mEjMYehskTSvPeJnwKzun5LUO4cJPnt4uRQGVAW2 GF0gC8KD/AAoTYIffQOH/rvgSdti2iNaoWY4jrdAnfuXbFDZTdKvZ3h+knmp0f/LQ5YFhnsScbH M6nOoiXbjIqIq0qsbXcn9oD/MNWG014kU1dl8SxIeUZJiXCqOlQ4O1jte+hl5bJcfRJTe/RWq5t q5TA== X-Google-Smtp-Source: AGHT+IGhQyCN1xHaGIEfj4qWSfyhOsR6ya7oNTHCPsgmXHeLcBU+uSq0axNexK/SCVNsf9p5UNHMdg== X-Received: by 2002:a17:90b:4d0f:b0:340:e103:bfdd with SMTP id 98e67ed59e1d1-34733f44278mr6339700a91.25.1763849707450; Sat, 22 Nov 2025 14:15:07 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.15.06 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:15:07 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 18/21] go: remove duplicate arch map in sdk test Date: Sat, 22 Nov 2025 14:14:24 -0800 Message-ID: <21f3a6c661307eab5530b51704c3a338013c9c5c.1763849517.git.steve@sakoman.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:15:14 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226716 From: Osama Abdelkader ARCH_MAP is duplicating an existing map in meta/lib/oe/go.py use oe.go map_arch instead. (From OE-Core rev: c2ba36f41777d347fd5ffcd9b6862638e5f35a1b) Signed-off-by: Osama Abdelkader Signed-off-by: Mathieu Dubois-Briand Signed-off-by: Richard Purdie Signed-off-by: Peter Marko Signed-off-by: Steve Sakoman --- meta/lib/oeqa/sdk/cases/go.py | 31 +++++-------------------------- 1 file changed, 5 insertions(+), 26 deletions(-) diff --git a/meta/lib/oeqa/sdk/cases/go.py b/meta/lib/oeqa/sdk/cases/go.py index 9c15124f6a..a050df7a9f 100644 --- a/meta/lib/oeqa/sdk/cases/go.py +++ b/meta/lib/oeqa/sdk/cases/go.py @@ -12,6 +12,7 @@ from oeqa.core.utils.path import remove_safe from oeqa.sdk.case import OESDKTestCase from oeqa.utils.subprocesstweak import errors_have_output +from oe.go import map_arch errors_have_output() class GoCompileTest(OESDKTestCase): @@ -55,22 +56,6 @@ class GoCompileTest(OESDKTestCase): class GoHostCompileTest(OESDKTestCase): td_vars = ['MACHINE', 'SDK_SYS', 'TARGET_ARCH'] - # Architecture mapping from Yocto/Poky to Go - ARCH_MAP = { - 'aarch64': 'arm64', - 'cortexa57': 'arm64', # ARM Cortex-A57 is ARM64 - 'cortexa72': 'arm64', # ARM Cortex-A72 is ARM64 - 'cortexa53': 'arm64', # ARM Cortex-A53 is ARM64 - 'x86_64': 'amd64', - 'i586': '386', - 'i686': '386', - 'mips': 'mips', - 'mipsel': 'mipsle', - 'powerpc64': 'ppc64', - 'powerpc64le': 'ppc64le', - 'riscv64': 'riscv64', - } - @classmethod def setUpClass(self): # Copy test.go file to SDK directory (same as GCC test uses files_dir) @@ -94,12 +79,8 @@ class GoHostCompileTest(OESDKTestCase): sdksys = self.td.get("SDK_SYS") arch = sdksys.split('-')[0] - # Handle ARM variants - if arch.startswith('arm'): - return 'arm' - # Use mapping for other architectures - return self.ARCH_MAP.get(arch, arch) + return map_arch(arch) def test_go_cross_compile(self): """Test Go cross-compilation for target""" @@ -117,12 +98,10 @@ class GoHostCompileTest(OESDKTestCase): # Clean up files with dynamic architecture names files = [os.path.join(self.tc.sdk_dir, f) \ for f in ['test.go', 'go.mod', 'go.sum']] - # Add architecture-specific files using the same mapping - for arch in self.ARCH_MAP.values(): + # Add common architecture-specific files that might be created + common_archs = ['arm64', 'arm', 'amd64', '386', 'mips', 'mipsle', 'ppc64', 'ppc64le', 'riscv64'] + for arch in common_archs: files.extend([os.path.join(self.tc.sdk_dir, f) \ for f in ['test-%s' % arch, 'hello-go-%s' % arch]]) - # Add 'arm' for ARM variants - files.extend([os.path.join(self.tc.sdk_dir, f) \ - for f in ['test-arm', 'hello-go-arm']]) for f in files: remove_safe(f) From patchwork Sat Nov 22 22:14:25 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75239 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 09274CFD312 for ; Sat, 22 Nov 2025 22:15:14 +0000 (UTC) Received: from mail-pj1-f43.google.com (mail-pj1-f43.google.com [209.85.216.43]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.3771.1763849709767269477 for ; Sat, 22 Nov 2025 14:15:09 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=KeQAjm7b; spf=softfail (domain: sakoman.com, ip: 209.85.216.43, mailfrom: steve@sakoman.com) Received: by mail-pj1-f43.google.com with SMTP id 98e67ed59e1d1-340c39ee02dso2694530a91.1 for ; Sat, 22 Nov 2025 14:15:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849709; x=1764454509; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=a6qrDvYIEIfh+2qIXs2fwpRfxs+PLi4NhOmViKiDRU4=; b=KeQAjm7bnwoDdw8jhTFcsPD+czcqTg50iPcJwNNXRFjkMvJ5c+XL1FbtFB4bvSvJRr 6vswwVjvzay3kgrnxRZ4MDtOfuhI9PHvsg32LcsBHDxutp0rinu5/A1sR2SvrJt4G08w 4PD6g4c0o1M5HH9Tu3slXEfyTEBfSdg6ZANJkxg9p2StRmW1zsa86RgdYRCUJsqbt2SQ IdOS/EKnTaq+RaCjL889Ew0ZyCRuYYyLTf1q84I5nSN5AwL+4BWEIV3tm7UV24+LHq+5 UhHsp7Ji6wTH069YaAV/F/fWKS68EHCbRXWGuI3DlAj7VJgqeTxI6AJGacmm9AouczZv Ld8g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849709; x=1764454509; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=a6qrDvYIEIfh+2qIXs2fwpRfxs+PLi4NhOmViKiDRU4=; b=ADu5E1/37lVGEPL5VpFCXHzc1IbAqpqE+23eBimn9SD5tKD3OtjB3YWIouOPmLYjgi fqZxCQunh7hoU4CdnoXl9BB4R3OTWvBAv4e+msKJSgsZ97Z9/xjpLSYV5fcAyMZSejUu v+9nztHOHRoVlATJmV2y5ETmzjinp9KaLA976IRToFDcO5xmV0U0lF0N+uJxf7EjKI6V E/1lm+0VNnYy+WjA8X+urRlmzfirFF6XZIDKzx3h0sXtSBB0SoaK5+B800iPpSDpIvIm /rUnI/rZuOc79nbRyAN0vw9WeQVWiVTvOzSHhSTwSXQdrHsdyiaCL6YqQQEK7x5AQs5E b2Uw== X-Gm-Message-State: AOJu0YxlfQI/eq92xDySxgiE1NBIo+6YocEp5XXJQ+FE2h/PdIuF7L2L 2yRoyyrYw2jIMPhYWXjq2QpUsTIZLGG+mAMNwAZnmHRUI1rhApiyyXD2ohaEWLrMVPYpssCukCJ T2RuB X-Gm-Gg: ASbGncuatUZH1OTScXa5lnxP0J4JWY73TGamylXzGAokkbIt+ntuMz8AIJbcHMDHPeg uM0yhEpiq7yT/4LuMJOw1HhBbr2zzhQUUtkgMqOLY6bY0BKmE0BSw0Zl1WQKPxLTRNaL4UG2OZK nEq8zyuFf6hVvJSFaNMhGAFdbecXN4XCnCpIkEkSM7h6ko1IF45TtDhS+TKjhRsu80FV8TARfOq HUMNnw4duEElVbcMFx8d/QhirfBmSmVv2iDZd60r9hpipeqpQGxFvOgGOBTubMeC0KWyhcrGcpD sJWCBwkMWT5B1hxIFXchcxUEL26gD/+p0pSjMhtOj+AfgVh5QxqQl8wxEy4uTyM+EyClkI6YnhI i/+t7dWKt8EyHczkIr7mEqjLWf+bmL5irm2yTWJCzyi7ERZsWnmjZqs6XqSYdbOExdNxnbz0yNl sqLQ== X-Google-Smtp-Source: AGHT+IGmO1Uzxe5PC97n5Z2rbJ4OXAY+y9P36RJSOypf6la11wdoBxew3NDQkmEC58QMAfUfeDx9NA== X-Received: by 2002:a17:90b:1c85:b0:32e:38b0:15f4 with SMTP id 98e67ed59e1d1-34733e46dc6mr8631682a91.7.1763849709008; Sat, 22 Nov 2025 14:15:09 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.15.08 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:15:08 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 19/21] oeqa: fix package detection in go sdk tests Date: Sat, 22 Nov 2025 14:14:25 -0800 Message-ID: <82a46b70bfba7c4ce4fd20e2658b182b03e55037.1763849517.git.steve@sakoman.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:15:14 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226717 From: Peter Marko The test are skipped if architecture contains dash because TARGET_ARCH contains underscore while package name contains dash. Here the translation needs to be done. Note that poky distro default arch has dash: MACHINE="qemux86-64" TARGET_ARCH="x86_64" ERROR: Nothing PROVIDES 'go-cross-canadian-x86_64'. Close matches: gcc-cross-canadian-x86-64 gdb-cross-canadian-x86-64 go-cross-canadian-x86-64 TRANSLATED_TARGET_ARCH="x86-64" Quoting meta/classes-recipe/cross-canadian.bbclass: TRANSLATED_TARGET_ARCH is added into PN Signed-off-by: Peter Marko Signed-off-by: Steve Sakoman --- meta/lib/oeqa/sdk/cases/go.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/meta/lib/oeqa/sdk/cases/go.py b/meta/lib/oeqa/sdk/cases/go.py index a050df7a9f..693be89e1d 100644 --- a/meta/lib/oeqa/sdk/cases/go.py +++ b/meta/lib/oeqa/sdk/cases/go.py @@ -25,9 +25,9 @@ class GoCompileTest(OESDKTestCase): os.path.join(self.tc.sdk_dir, 'test.go')) def setUp(self): - target_arch = self.td.get("TARGET_ARCH") + translated_target_arch = self.td.get("TRANSLATED_TARGET_ARCH") # Check for go-cross-canadian package (uses target architecture) - if not self.tc.hasHostPackage("go-cross-canadian-%s" % target_arch): + if not self.tc.hasHostPackage("go-cross-canadian-%s" % translated_target_arch): raise unittest.SkipTest("GoCompileTest class: SDK doesn't contain a Go cross-canadian toolchain") # Additional runtime check for go command availability @@ -63,9 +63,9 @@ class GoHostCompileTest(OESDKTestCase): os.path.join(self.tc.sdk_dir, 'test.go')) def setUp(self): - target_arch = self.td.get("TARGET_ARCH") + translated_target_arch = self.td.get("TRANSLATED_TARGET_ARCH") # Check for go-cross-canadian package (uses target architecture) - if not self.tc.hasHostPackage("go-cross-canadian-%s" % target_arch): + if not self.tc.hasHostPackage("go-cross-canadian-%s" % translated_target_arch): raise unittest.SkipTest("GoHostCompileTest class: SDK doesn't contain a Go cross-canadian toolchain") # Additional runtime check for go command availability From patchwork Sat Nov 22 22:14:26 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75241 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 01CB3CFD307 for ; Sat, 22 Nov 2025 22:15:14 +0000 (UTC) Received: from mail-pj1-f49.google.com (mail-pj1-f49.google.com [209.85.216.49]) by mx.groups.io with SMTP id smtpd.msgproc01-g2.2721.1763849712124619951 for ; Sat, 22 Nov 2025 14:15:12 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=b/k6KrZT; spf=softfail (domain: sakoman.com, ip: 209.85.216.49, mailfrom: steve@sakoman.com) Received: by mail-pj1-f49.google.com with SMTP id 98e67ed59e1d1-3436cbb723fso2559419a91.2 for ; Sat, 22 Nov 2025 14:15:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849711; x=1764454511; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=sMPgBERqIeI0HuOIQqEHSX+BGTGfat3ue5rDZCDTqtg=; b=b/k6KrZT8QB+F9BgjQjYVhp17t+FvCt6IumNhUAYDyw1EGTe+FXbJ5reA/nuicWpjT /p32PzNFG/iDE7dKxQ4artGn1fKpJx6z3BFfNA6gwTXpjQlrKiecHjF1pPUuhFN+3Wr8 4SLXYw74pYiZ8oIZXfD0ABX49gj9h1jqOpIv74Ozq4tJ1bxugcu9zg+k3b8qz6mKs6e0 xXipdKw5gJG9ePfWuPXwSwstihJ8kCdN1oRx3JHZL/8o0IVunT0nQzp1vK3l/BQocO2s 4ZGklWISKjFe6oZdXSf+9wFzOTLgRiy1+7OjEjIneWtNwstJpjakL9doGzhH2KjxM1F8 jA1A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849711; x=1764454511; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=sMPgBERqIeI0HuOIQqEHSX+BGTGfat3ue5rDZCDTqtg=; b=EYQNvzGG+Zg9n1N6lXKyjtgQjJjqEbcUqfahb+4vimnAEvUdHwlD4nsx7PseCEJR/g NgLj//joOclN7WJzvC9Lcw/96ZnMXeBQSOYj6MLHE60fkQcRYiomJ0jpZtSeoBIy6RzQ mxWz5RkqI3TYT2TsVbribPOqbu33GDpWOR17VvpMcP2hXROsWlBbtE1804oTHpXgUPi1 elBgewI8iLAUyiQIMMOGPz7kJOMhKcTongNqA9UnyyleicR9vOZLWL533RAJIijvb1DT CFvm0hru5FTCecplu0SCPcxzc4NHVF59pTwforhiPkINuM2y6S5UzFlUIJYPZQ7GE56J w1XQ== X-Gm-Message-State: AOJu0YyQdasKuQdSO8+bMfLNX+nEfBkwweS1cLL5kQl+ZxjfBP5XzSBJ 6n8UwRpFKLjOdnnr+S8W639rFItQTYjV+1KLN65pLm9md4HgW80jnbFsi5JWY7RqMtRWte6/YZF Ge2y8 X-Gm-Gg: ASbGncsNUoG1RSo0QwUUrZZJQAoxXcQr1DSt8qgiZ6SBVaHRGVqeFQnoS4PieoaOeoL b1eRBwS0oatkPT5gGnmJNFRSlm9YRVQAQYyapkh53qZbED4IArZgYdq0RVG/rJfypVrsP66/6DF eDMzJRXMi7H9lSfVdx/T1KBHNYXXwnQEQ+H50fn/X2PkLUEn9GIPpN1iXhldET1VGsxhmoa2Nwq 112m/vH4MF9+g/txhCC+f9664byv1gkWIPoGdW8F9Sa0GHOEukARjL0Zn6mb7JMl6C1BdszR++K UPb2Uu0uJx2YgEzKVK6yhoAE8XdWW9hMcRz30gnCVFtN3ah+f3YjW9rSaJVG51k6QoA8lnZY/gN HS0k1KFNZ1K1EYRblQP4tFspanjFEYmLAfLm2UGPMagx2EWdfx7FJsaCO8/klwoU6dr/M72XjRc 0dng== X-Google-Smtp-Source: AGHT+IEiPN+CiWcqXLhNFTM4AWxPjJc8JQ+/kIOqtM0Rp2Rdd5pzrpGeciguHtuXuwD72yYRwfSU6A== X-Received: by 2002:a17:90a:d24c:b0:340:f40c:169c with SMTP id 98e67ed59e1d1-34733f2a47cmr4677895a91.32.1763849711369; Sat, 22 Nov 2025 14:15:11 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.15.09 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:15:10 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 20/21] oeqa: drop unnecessary dependency from go runtime tests Date: Sat, 22 Nov 2025 14:14:26 -0800 Message-ID: <4e10e7848cb10307f133f181b41563c995df032a.1763849517.git.steve@sakoman.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:15:13 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226718 From: Peter Marko The tests do not use scp command, so openssh-scp is not needed. Signed-off-by: Peter Marko Signed-off-by: Steve Sakoman --- meta/lib/oeqa/runtime/cases/go.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/meta/lib/oeqa/runtime/cases/go.py b/meta/lib/oeqa/runtime/cases/go.py index fc7959b5f4..d4b69438a5 100644 --- a/meta/lib/oeqa/runtime/cases/go.py +++ b/meta/lib/oeqa/runtime/cases/go.py @@ -28,7 +28,6 @@ class GoCompileTest(OERuntimeTestCase): @OEHasPackage('go') @OEHasPackage('go-runtime') @OEHasPackage('go-runtime-dev') - @OEHasPackage('openssh-scp') def test_go_compile(self): # Check if go is available status, output = self.target.run('which go') @@ -49,7 +48,6 @@ class GoCompileTest(OERuntimeTestCase): @OEHasPackage('go') @OEHasPackage('go-runtime') @OEHasPackage('go-runtime-dev') - @OEHasPackage('openssh-scp') def test_go_module(self): # Check if go is available status, output = self.target.run('which go') From patchwork Sat Nov 22 22:14:27 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 75237 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 EEE60CFD30D for ; Sat, 22 Nov 2025 22:15:13 +0000 (UTC) Received: from mail-pl1-f180.google.com (mail-pl1-f180.google.com [209.85.214.180]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.3773.1763849713582996392 for ; Sat, 22 Nov 2025 14:15:13 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=DyrGRWyt; spf=softfail (domain: sakoman.com, ip: 209.85.214.180, mailfrom: steve@sakoman.com) Received: by mail-pl1-f180.google.com with SMTP id d9443c01a7336-297ef378069so28462825ad.3 for ; Sat, 22 Nov 2025 14:15:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1763849713; x=1764454513; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=XL/kfWHJOz6SAfs7LRjmiptXG+ae6Kl5tTRWnbH2jZI=; b=DyrGRWytG6MIQCVdYgrUdazXPhAmGOlSNdgpaH3eAK2PgpbBvcROLA4lpa99WHBGn+ L5gNqy4o/9wmk2/ushXxMier043NbhBT7GY4BZxqGR3Se2KgFexbPet7zEhpYWerTtQg /CGLsjNshxSDUbcrxizqOMK6eO6wMhfW6Ixbq0BbSd6CBVZd+zmAKsjmmMooxd0nZQ2b zMsxvTpWChcWG1oASoOtxM+K4d5wLg3hF9A/WYIi12uGG3nNpx8dEjqLiEtdwIiHP+Gc ck6xlFGLNk51kdO44UGRkx1wwn3+07zDfn9Nh4HsIu3BpgX5ByzT1lFkC39adbsZ4W/A URgw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763849713; x=1764454513; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=XL/kfWHJOz6SAfs7LRjmiptXG+ae6Kl5tTRWnbH2jZI=; b=Qdgcn3OLsX2rApB7eM+rI7TkL6KO6M4UBNfzCBDBH8IhPJ+ilmOtceUXkb/eCYovWr ghWaxTpwUG9FeJge/TV61NGq/s6vqOjyR2+Q+RI8+7UB+k0d0TuaZAg2YFKWtrfO+naS yKyProkcHMv4tISZmeVnS99K2VCX3O9UWEWWolhC+rNnjtqf4Oaz7hQyCJ9cEw4YQzO8 SwyaYS92ZCmsJYmw8s5Xc8w3uwqmDLM95bOQgaewPEMMLpUZiEWkNIK4TNRZig31LkST v/F2bttgygFBkiQx9akpc5fA/H+1JC2W3l488NaA+Az2DWcBJu/lYSLj8zaPJLoOP4vM PZ5g== X-Gm-Message-State: AOJu0YzMV5JfrqrDUJ0VT/Q1xjO+gUwgJ3A1S2lcEvvUv02uWySobD4d EsqUYRjuVXCGxSkXLNKkflZx9UC99gomK505ACtwy1BDEdZTe7stLv/9dy++PTDcRun4N+KFjvt n49Hz X-Gm-Gg: ASbGnct8L8X+JLrllZInaZr7D+V30nGG0JIMBbi5N2ZgoOdLjJaouhOq8GpFGnIKZKN cMFodb1FDI5OjbdRjivrS4V7ISRINPq7+gQrzqIHEQY+pmjw6BGxULC6GByICELqxxWQW/oLBuf p5bfoxpuiy3oNotCr/4TjjJTClciEFTMnyfK3nxofwdN4ryJ7mOj2LoAmhlMBDJ3ffWFK9VjHWX i22GlpMg7e5sU7N0TcNxbun7iucjo0XYT0hP6mNLickfcvfnn1MzHtSIZyEdVOBV1VTP/qJAAFF PgqnjOTxTFx1crX60qHX/c4jX0qNZBexmodvQ/juIeKghC9FNE00cEUIc3ko5au+detb8Vhi4XM nwLNXcVZY2h+jO55Dp2jikoi2MlrLDSRnoM5CtEGbDTjVsd3mAeh6pggSiuJHKQMWSzhEm4F/vl /5cec04hA9+rG9 X-Google-Smtp-Source: AGHT+IGVyL9vFJGOqfQC7stNNStE7bvZmN8AKBag39ex2EFgUgOqdLgqR6cA4wMkTu4+5qQ4KK3GeA== X-Received: by 2002:a17:90a:ae91:b0:340:be44:dd11 with SMTP id 98e67ed59e1d1-34733f2a450mr5256055a91.27.1763849712826; Sat, 22 Nov 2025 14:15:12 -0800 (PST) Received: from hexa.. ([2602:feb4:3b:2100:a812:a9e4:3291:bb61]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-345af26d8b1sm7158274a91.3.2025.11.22.14.15.12 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 22 Nov 2025 14:15:12 -0800 (PST) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 21/21] oeqa/sdk/buildepoxy: skip test in eSDK Date: Sat, 22 Nov 2025 14:14:27 -0800 Message-ID: <7cfacaee1b3319e561036512a849e762d0f68a5e.1763849517.git.steve@sakoman.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 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 ; Sat, 22 Nov 2025 22:15:13 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/226719 From: Peter Marko Currently meson inside eSDKs only works with fully populated eSDKs, but our testing uses minimal eSDKS, so skip the test if the eSDK is a minimal build. A bug has been filed to resolve this. This is minimal change extracted from OE-Core commit which has this only as a minor comment: 575e0bf52db0467d88af4b5fe467b682f10ca62a Signed-off-by: Peter Marko Signed-off-by: Steve Sakoman --- meta/lib/oeqa/sdk/cases/buildepoxy.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/meta/lib/oeqa/sdk/cases/buildepoxy.py b/meta/lib/oeqa/sdk/cases/buildepoxy.py index 5b9c36fcec..2f21210c79 100644 --- a/meta/lib/oeqa/sdk/cases/buildepoxy.py +++ b/meta/lib/oeqa/sdk/cases/buildepoxy.py @@ -10,6 +10,7 @@ import tempfile import unittest from oeqa.sdk.case import OESDKTestCase +from oeqa.sdkext.context import OESDKExtTestContext from oeqa.utils.subprocesstweak import errors_have_output errors_have_output() @@ -22,6 +23,9 @@ class EpoxyTest(OESDKTestCase): if libc in [ 'newlib' ]: raise unittest.SkipTest("MesonTest class: SDK doesn't contain a supported C library") + if isinstance(self.tc, OESDKExtTestContext): + self.skipTest(f"{self.id()} does not support eSDK (https://bugzilla.yoctoproject.org/show_bug.cgi?id=15854)") + if not (self.tc.hasHostPackage("nativesdk-meson") or self.tc.hasHostPackage("meson-native")): raise unittest.SkipTest("EpoxyTest class: SDK doesn't contain Meson")