From patchwork Thu Jul 18 13:45:30 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 46598 X-Patchwork-Delegate: steve@sakoman.com 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 2C158C3DA63 for ; Thu, 18 Jul 2024 13:46:01 +0000 (UTC) Received: from mail-pl1-f169.google.com (mail-pl1-f169.google.com [209.85.214.169]) by mx.groups.io with SMTP id smtpd.web11.15457.1721310353041330737 for ; Thu, 18 Jul 2024 06:45:53 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=1L+45pbW; spf=softfail (domain: sakoman.com, ip: 209.85.214.169, mailfrom: steve@sakoman.com) Received: by mail-pl1-f169.google.com with SMTP id d9443c01a7336-1fbe6f83957so7495485ad.3 for ; Thu, 18 Jul 2024 06:45:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1721310352; x=1721915152; 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=Q06XnKBo5zK292TFyyM07d48rgiLttaQQvo4FdGiExs=; b=1L+45pbWq355CoA52w1X/RHyBy3fTyRd64sVwZhHvFEA5RG4od/szZE+d+Et37GAqN Z7Q+FliXqUeUDm7K1h6Y4oTa7S592dnuCbPoIFGig/oqK54Jx2l1XdoML4jZZgggzbNb WWWdjKd2JKeMeZGZ43LNxdZnS8symyoNwRh0/RmAU4wAuRz8I0sfGtgth8CNg1CbSYRA Sk4nah8Y1e1HYxNvAM+u8wfxKN228GoVmGM5uPt63Xtyrcz3Bb2B0tj4rYpbcMHH80XA 8sT2L4BPrCd4gaxgtGHj7IfWN2tK3k+AbTQvDySJKsTOjkRdJ83jjtysj0knpotHc3Ql iTIA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721310352; x=1721915152; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Q06XnKBo5zK292TFyyM07d48rgiLttaQQvo4FdGiExs=; b=b5bRfWzMNAIlqWh+NfjNXPbzirmMLPpqLv8ZDdKs6noTxb8gYWmxT9ne94YuXOSh8E FakUDn8889CbFjBK88rhgM5oxrjzEl467g0AuWdNyWKvDNmb0UCizSF8dxbexpaNckpz BWP5wA66D61iFX0U04C1JMlezbdR3BbUuLaibdjVp9ssN0RsrjFDHyt7LMv8qMlh7Tse t0uoIi98snCN/z407c35T9RCH9ztqUzOR9q518l/FHqRHGWkpwZtfOVlQOgKW4WLrbJr vlSmqmapMGvYyWjaPD+q10NSOQjEIoXHlgL/hvMKHdr91dow1SEtGCcC/is6pyT86Xjn wsMA== X-Gm-Message-State: AOJu0Yzbgr04M0Rz0tmQvi2zUHLWmxdPZ75m4RjaweDK8EQ0gIb2sKGx a+k9WqWqtBlW665BbfNHUwsTxs40EfnGUHdpLBaGnrBFwsAqfbIKGwEzv0c8JYK3IxNoq/hKV4a Y X-Google-Smtp-Source: AGHT+IH376QvManV4x+x1lcPSfsJ9lba0q6MW5hpifPJ1Q998TuZ6dqWopNXgI3VgFNjD29AhaUYfQ== X-Received: by 2002:a17:902:d4c9:b0:1fb:bd7:f22c with SMTP id d9443c01a7336-1fc4e683463mr36726065ad.56.1721310352014; Thu, 18 Jul 2024 06:45:52 -0700 (PDT) Received: from hexa.. ([98.142.47.158]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-1fc0bb6ffbdsm93366985ad.60.2024.07.18.06.45.50 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 18 Jul 2024 06:45:51 -0700 (PDT) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 01/12] busybox: Patch CVE-2021-42380 Date: Thu, 18 Jul 2024 06:45:30 -0700 Message-Id: <9f5c683b6cadae6228096deb36d7d6fb6de94ad1.1721310237.git.steve@sakoman.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 18 Jul 2024 13:46:01 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/202214 From: Peter Marko Backport patch for CVE-2021-42380. Additionally backport clang regression fix caused by this patch. Signed-off-by: Peter Marko Signed-off-by: Richard Purdie (cherry picked from commit 66543769ff79d81508bb703bd2fc34871a16e2c7) Signed-off-by: Steve Sakoman --- ...-fix-segfault-when-compiled-by-clang.patch | 41 +++++ .../busybox/busybox/CVE-2021-42380.patch | 151 ++++++++++++++++++ meta/recipes-core/busybox/busybox_1.36.1.bb | 2 + 3 files changed, 194 insertions(+) create mode 100644 meta/recipes-core/busybox/busybox/0001-awk-fix-segfault-when-compiled-by-clang.patch create mode 100644 meta/recipes-core/busybox/busybox/CVE-2021-42380.patch diff --git a/meta/recipes-core/busybox/busybox/0001-awk-fix-segfault-when-compiled-by-clang.patch b/meta/recipes-core/busybox/busybox/0001-awk-fix-segfault-when-compiled-by-clang.patch new file mode 100644 index 0000000000..3f6145b250 --- /dev/null +++ b/meta/recipes-core/busybox/busybox/0001-awk-fix-segfault-when-compiled-by-clang.patch @@ -0,0 +1,41 @@ +From e1a68741067167dc4837e0a26d3d5c318a631fc7 Mon Sep 17 00:00:00 2001 +From: Ron Yorston +Date: Fri, 19 Jan 2024 15:41:17 +0000 +Subject: [PATCH] awk: fix segfault when compiled by clang + +A 32-bit build of BusyBox using clang segfaulted in the test +"awk assign while assign". Specifically, on line 7 of the test +input where the adjustment of the L.v pointer when the Fields +array was reallocated + + L.v += Fields - old_Fields_ptr; + +was out by 4 bytes. + +Rearrange to code so both gcc and clang generate code that works. + +Signed-off-by: Ron Yorston +Signed-off-by: Bernhard Reutner-Fischer + +Upstream-Status: Backport [https://git.busybox.net/busybox/commit/?id=5dcc443dba039b305a510c01883e9f34e42656ae] +Signed-off-by: Peter Marko +--- + editors/awk.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/editors/awk.c b/editors/awk.c +index aa485c782..0981c6735 100644 +--- a/editors/awk.c ++++ b/editors/awk.c +@@ -2935,7 +2935,7 @@ static var *evaluate(node *op, var *res) + if (old_Fields_ptr) { + //if (old_Fields_ptr != Fields) + // debug_printf_eval("L.v moved\n"); +- L.v += Fields - old_Fields_ptr; ++ L.v = Fields + (L.v - old_Fields_ptr); + } + if (opinfo & OF_STR2) { + R.s = getvar_s(R.v); +-- +2.30.2 + diff --git a/meta/recipes-core/busybox/busybox/CVE-2021-42380.patch b/meta/recipes-core/busybox/busybox/CVE-2021-42380.patch new file mode 100644 index 0000000000..3baef86415 --- /dev/null +++ b/meta/recipes-core/busybox/busybox/CVE-2021-42380.patch @@ -0,0 +1,151 @@ +From 5dcc443dba039b305a510c01883e9f34e42656ae Mon Sep 17 00:00:00 2001 +From: Denys Vlasenko +Date: Fri, 26 May 2023 19:36:58 +0200 +Subject: [PATCH] awk: fix use-after-realloc (CVE-2021-42380), closes 15601 + +Signed-off-by: Denys Vlasenko + +CVE: CVE-2021-42380 +Upstream-Status: Backport [https://git.busybox.net/busybox/commit/?id=5dcc443dba039b305a510c01883e9f34e42656ae] +Signed-off-by: Peter Marko +--- + editors/awk.c | 26 ++++++++++++++++----- + testsuite/awk.tests | 55 +++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 75 insertions(+), 6 deletions(-) + +diff --git a/editors/awk.c b/editors/awk.c +index 728ee8685..2af823808 100644 +--- a/editors/awk.c ++++ b/editors/awk.c +@@ -555,7 +555,7 @@ struct globals { + const char *g_progname; + int g_lineno; + int nfields; +- int maxfields; /* used in fsrealloc() only */ ++ unsigned maxfields; + var *Fields; + char *g_pos; + char g_saved_ch; +@@ -1931,9 +1931,9 @@ static void fsrealloc(int size) + { + int i, newsize; + +- if (size >= maxfields) { +- /* Sanity cap, easier than catering for overflows */ +- if (size > 0xffffff) ++ if ((unsigned)size >= maxfields) { ++ /* Sanity cap, easier than catering for over/underflows */ ++ if ((unsigned)size > 0xffffff) + bb_die_memory_exhausted(); + + i = maxfields; +@@ -2891,6 +2891,7 @@ static var *evaluate(node *op, var *res) + uint32_t opinfo; + int opn; + node *op1; ++ var *old_Fields_ptr; + + opinfo = op->info; + opn = (opinfo & OPNMASK); +@@ -2899,10 +2900,16 @@ static var *evaluate(node *op, var *res) + debug_printf_eval("opinfo:%08x opn:%08x\n", opinfo, opn); + + /* execute inevitable things */ ++ old_Fields_ptr = NULL; + if (opinfo & OF_RES1) { + if ((opinfo & OF_REQUIRED) && !op1) + syntax_error(EMSG_TOO_FEW_ARGS); + L.v = evaluate(op1, TMPVAR0); ++ /* Does L.v point to $n variable? */ ++ if ((size_t)(L.v - Fields) < maxfields) { ++ /* yes, remember where Fields[] is */ ++ old_Fields_ptr = Fields; ++ } + if (opinfo & OF_STR1) { + L.s = getvar_s(L.v); + debug_printf_eval("L.s:'%s'\n", L.s); +@@ -2921,8 +2928,15 @@ static var *evaluate(node *op, var *res) + */ + if (opinfo & OF_RES2) { + R.v = evaluate(op->r.n, TMPVAR1); +- //TODO: L.v may be invalid now, set L.v to NULL to catch bugs? +- //L.v = NULL; ++ /* Seen in $5=$$5=$0: ++ * Evaluation of R.v ($$5=$0 expression) ++ * made L.v ($5) invalid. It's detected here. ++ */ ++ if (old_Fields_ptr) { ++ //if (old_Fields_ptr != Fields) ++ // debug_printf_eval("L.v moved\n"); ++ L.v += Fields - old_Fields_ptr; ++ } + if (opinfo & OF_STR2) { + R.s = getvar_s(R.v); + debug_printf_eval("R.s:'%s'\n", R.s); +diff --git a/testsuite/awk.tests b/testsuite/awk.tests +index bbf0fbff1..ddc51047b 100755 +--- a/testsuite/awk.tests ++++ b/testsuite/awk.tests +@@ -485,4 +485,59 @@ testing 'awk assign while test' \ + "" \ + "foo" + ++# User-supplied bug (SEGV) example, was causing use-after-realloc ++testing 'awk assign while assign' \ ++ "awk '\$5=\$\$5=\$0'; echo \$?" \ ++ "\ ++─ process timing ────────────────────────────────────┬─ ─ process timing ────────────────────────────────────┬─ overall results ────┐ results ────┐ ++│ run time : │ run time : 0 days, 0 hrs, 0 min, 56 sec │ cycles done : 0 │ days, 0 hrs, 0 min, 56 sec │ cycles done : 0 │ ++│ last new find │ last new find : 0 days, 0 hrs, 0 min, 1 sec │ corpus count : 208 │ 0 days, 0 hrs, 0 min, 1 sec │ corpus count : 208 │ ++│last saved crash : │last saved crash : none seen yet │saved crashes : 0 │ seen yet │saved crashes : 0 │ ++│ last saved hang │ last saved hang : none seen yet │ saved hangs : 0 │ none seen yet │ saved hangs : 0 │ ++├─ cycle progress ─────────────────────┬─ ├─ cycle progress ─────────────────────┬─ map coverage┴──────────────────────┤ coverage┴──────────────────────┤ ++│ now processing : │ now processing : 184.1 (88.5%) │ map density : 0.30% / 0.52% │ (88.5%) │ map density : 0.30% / 0.52% │ │ now processing : 184.1 (88.5%) │ map density : 0.30% / 0.52% │ ++│ runs timed out │ runs timed out : 0 (0.00%) │ count coverage : 2.18 bits/tuple │ 0 (0.00%) │ count coverage : 2.18 bits/tuple │ ++├─ stage progress ─────────────────────┼─ ├─ stage progress ─────────────────────┼─ findings in depth ─────────────────┤ in depth ─────────────────┤ ++│ now trying : │ now trying : havoc │ favored items : 43 (20.67%) │ │ favored items : 43 (20.67%) │ ++│ stage execs : │ stage execs : 11.2k/131k (8.51%) │ new edges on : 52 (25.00%) │ (8.51%) │ new edges on │ stage execs : 11.2k/131k (8.51%) │ new edges on : 52 (25.00%) │ 52 (25.00%) │ ++│ total execs : │ total execs : 179k │ total crashes : 0 (0 saved) │ │ total crashes : 0 (0 saved) │ │ total execs : 179k │ total crashes : 0 (0 saved) │ ++│ exec speed : │ exec speed : 3143/sec │ total tmouts : 0 (0 saved) │ │ total tmouts : 0 (0 saved) │ │ exec speed : 3143/sec │ total tmouts : 0 (0 saved) │ ++├─ fuzzing strategy yields ├─ fuzzing strategy yields ────────────┴─────────────┬─ item geometry ───────┤ item geometry ───────┤ ++│ bit flips : │ bit flips : 11/648, 4/638, 5/618 │ levels : 4 │ 4/638, 5/618 │ levels : │ bit flips : 11/648, 4/638, 5/618 │ levels : 4 │ │ ++│ byte flips : │ byte flips : 0/81, 0/71, 0/52 │ pending : 199 │ 0/71, 0/52 │ pending : 199 │ ++│ arithmetics : 11/4494, │ arithmetics : 11/4494, 0/1153, 0/0 │ pend fav : 35 │ 0/0 │ pend fav : 35 │ ++│ known ints : 1/448, 0/1986, 0/2288 │ own finds : 207 │ known ints : │ known ints : 1/448, 0/1986, 0/2288 │ own finds : 207 │ 0/1986, 0/2288 │ own finds : 207 │ ++│ dictionary : 0/0, │ dictionary : 0/0, 0/0, 0/0, 0/0 │ imported : 0 │ 0/0, 0/0 │ imported : 0 │ ++│havoc/splice : 142/146k, 23/7616 │havoc/splice : 142/146k, 23/7616 │ stability : 100.00% │ stability : 100.00% │ ++│py/custom/rq : unused, unused, │py/custom/rq : unused, unused, unused, unused ├───────────────────────┘ unused ├───────────────────────┘ ++│ trim/eff : 57.02%/26, │ trim/eff : 57.02%/26, 0.00% │ [cpu000:100%] │ [cpu000:100%] ++└────────────────────────────────────────────────────┘^C └────────────────────────────────────────────────────┘^C ++0 ++" \ ++ "" \ ++ "\ ++─ process timing ────────────────────────────────────┬─ overall results ────┐ ++│ run time : 0 days, 0 hrs, 0 min, 56 sec │ cycles done : 0 │ ++│ last new find : 0 days, 0 hrs, 0 min, 1 sec │ corpus count : 208 │ ++│last saved crash : none seen yet │saved crashes : 0 │ ++│ last saved hang : none seen yet │ saved hangs : 0 │ ++├─ cycle progress ─────────────────────┬─ map coverage┴──────────────────────┤ ++│ now processing : 184.1 (88.5%) │ map density : 0.30% / 0.52% │ ++│ runs timed out : 0 (0.00%) │ count coverage : 2.18 bits/tuple │ ++├─ stage progress ─────────────────────┼─ findings in depth ─────────────────┤ ++│ now trying : havoc │ favored items : 43 (20.67%) │ ++│ stage execs : 11.2k/131k (8.51%) │ new edges on : 52 (25.00%) │ ++│ total execs : 179k │ total crashes : 0 (0 saved) │ ++│ exec speed : 3143/sec │ total tmouts : 0 (0 saved) │ ++├─ fuzzing strategy yields ────────────┴─────────────┬─ item geometry ───────┤ ++│ bit flips : 11/648, 4/638, 5/618 │ levels : 4 │ ++│ byte flips : 0/81, 0/71, 0/52 │ pending : 199 │ ++│ arithmetics : 11/4494, 0/1153, 0/0 │ pend fav : 35 │ ++│ known ints : 1/448, 0/1986, 0/2288 │ own finds : 207 │ ++│ dictionary : 0/0, 0/0, 0/0, 0/0 │ imported : 0 │ ++│havoc/splice : 142/146k, 23/7616 │ stability : 100.00% │ ++│py/custom/rq : unused, unused, unused, unused ├───────────────────────┘ ++│ trim/eff : 57.02%/26, 0.00% │ [cpu000:100%] ++└────────────────────────────────────────────────────┘^C" ++ + exit $FAILCOUNT +-- +2.30.2 + diff --git a/meta/recipes-core/busybox/busybox_1.36.1.bb b/meta/recipes-core/busybox/busybox_1.36.1.bb index 06eb9eb999..513dff8011 100644 --- a/meta/recipes-core/busybox/busybox_1.36.1.bb +++ b/meta/recipes-core/busybox/busybox_1.36.1.bb @@ -50,6 +50,8 @@ SRC_URI = "https://busybox.net/downloads/busybox-${PV}.tar.bz2;name=tarball \ file://0001-libbb-sockaddr2str-ensure-only-printable-characters-.patch \ file://0002-nslookup-sanitize-all-printed-strings-with-printable.patch \ file://start-stop-false.patch \ + file://CVE-2021-42380.patch \ + file://0001-awk-fix-segfault-when-compiled-by-clang.patch \ " SRC_URI:append:libc-musl = " file://musl.cfg " # TODO http://lists.busybox.net/pipermail/busybox/2023-January/090078.html From patchwork Thu Jul 18 13:45:31 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 46599 X-Patchwork-Delegate: steve@sakoman.com 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 496E5C3DA70 for ; Thu, 18 Jul 2024 13:46:01 +0000 (UTC) Received: from mail-pl1-f179.google.com (mail-pl1-f179.google.com [209.85.214.179]) by mx.groups.io with SMTP id smtpd.web11.15458.1721310354635081408 for ; Thu, 18 Jul 2024 06:45:54 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=STcldCBD; spf=softfail (domain: sakoman.com, ip: 209.85.214.179, mailfrom: steve@sakoman.com) Received: by mail-pl1-f179.google.com with SMTP id d9443c01a7336-1fbe6f83957so7495705ad.3 for ; Thu, 18 Jul 2024 06:45:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1721310354; x=1721915154; 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=0OkpOzgIpqyf3rBKP3LLP2PvQToynI4hp5w/JKjz5OM=; b=STcldCBDc2grJ5eLhrOfj11/9ON43imdngh89TfwHLHX0MwaI/n3R4ZnpB5xlfnuRK w32Xq3FZXgUNaWV2eJLMycgbjeaixMopLebQXAjKOesmY4pk64zfwBQDKHyfx9pOlqg+ Q63fdl1Cyn6b+hqiwHYjFxzVSNtiQGb1UxGRTaCXh+CVoDMzYinuzWQzvFHtrwbL3I8b zmPvHmOS4BIa8GXdl6s5wHwFYpIuKaVTjZcJVbCSczXjBoNZuCn9om13TMicItYLD7r1 0+h5TKQY93VpgMsNqhfRFpcg0EnP2M1iFQ0SBp3ZvP7TMU1YdcRfZ+gI7/iCPaDyE7nP ku+w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721310354; x=1721915154; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=0OkpOzgIpqyf3rBKP3LLP2PvQToynI4hp5w/JKjz5OM=; b=BCsPilpOnJTZzdlmiThWnVaC0tMfb91mDFP6w5Pn/IY2zqGMjTVNe11HAvuPJLsN/o kgQuTxxCTi/3qpNMvdPg/8jtXNWsWhaDWZZ4JWO21moADOisFfI4G5SUMf+4yvbvLDkm xZJSaVDMtHs0nWVf71VGSK9snSA3n7dC9X93D3U0cfCisEgPtXDVx/xHAZzHDHedBPzF dG1mdrGNPGSR8fdSlHpPhjnm39EHs7fCn5gX5s1/KmLTq2OOyrtifFMeH45IVjUMt0lN gsMGbSWQvCuNtOVSuXSOP5xCqEya3GY1iwRp7uWIQaPF2fwwV4n/O5wp00I2hRrbtOvg mR+w== X-Gm-Message-State: AOJu0Yz+aAy62QTxyPp2KargatORVr+gzEOf2hzYAXNGokb48fr8MUnY Hnyv+lSXjeDm0s8MgnCPKgvG+ULQWeLbkKnKoeFRD9H8kgJVTsI53j29hb0xnzxGT1mm7PhNml2 2 X-Google-Smtp-Source: AGHT+IF4p22XIFUgWeTLuERLq0Nqx7aV07awo+joB/Bqcd5coj4IHpF5P5MJhNm/ijY0drndnTdhHA== X-Received: by 2002:a17:903:22c7:b0:1f7:19b7:98bd with SMTP id d9443c01a7336-1fc4e105de3mr43002515ad.6.1721310353790; Thu, 18 Jul 2024 06:45:53 -0700 (PDT) Received: from hexa.. ([98.142.47.158]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-1fc0bb6ffbdsm93366985ad.60.2024.07.18.06.45.52 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 18 Jul 2024 06:45:53 -0700 (PDT) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 02/12] busybox: Patch CVE-2023-42363 Date: Thu, 18 Jul 2024 06:45:31 -0700 Message-Id: <9c52dadd06fd9132c6efc1d06b6fc4a4517be6c3.1721310237.git.steve@sakoman.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 18 Jul 2024 13:46:01 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/202215 From: Peter Marko Backport patch for CVE-2023-42363. Signed-off-by: Peter Marko Signed-off-by: Richard Purdie (cherry picked from commit 814f97922e1d6c24a36b03ee0e865f2210ff6d7c) Signed-off-by: Steve Sakoman --- .../busybox/busybox/CVE-2023-42363.patch | 67 +++++++++++++++++++ meta/recipes-core/busybox/busybox_1.36.1.bb | 1 + 2 files changed, 68 insertions(+) create mode 100644 meta/recipes-core/busybox/busybox/CVE-2023-42363.patch diff --git a/meta/recipes-core/busybox/busybox/CVE-2023-42363.patch b/meta/recipes-core/busybox/busybox/CVE-2023-42363.patch new file mode 100644 index 0000000000..379f6f83b1 --- /dev/null +++ b/meta/recipes-core/busybox/busybox/CVE-2023-42363.patch @@ -0,0 +1,67 @@ +From fb08d43d44d1fea1f741fafb9aa7e1958a5f69aa Mon Sep 17 00:00:00 2001 +From: Natanael Copa +Date: Mon, 20 May 2024 17:55:28 +0200 +Subject: [PATCH] awk: fix use after free (CVE-2023-42363) + +function old new delta +evaluate 3377 3385 +8 + +Fixes https://bugs.busybox.net/show_bug.cgi?id=15865 + +Signed-off-by: Natanael Copa +Signed-off-by: Denys Vlasenko + +CVE: CVE-2023-42363 +Upstream-Status: Backport [https://git.busybox.net/busybox/commit/?id=fb08d43d44d1fea1f741fafb9aa7e1958a5f69aa] +Signed-off-by: Peter Marko +--- + editors/awk.c | 21 +++++++++++++-------- + 1 file changed, 13 insertions(+), 8 deletions(-) + +diff --git a/editors/awk.c b/editors/awk.c +index 0981c6735..ff6d6350b 100644 +--- a/editors/awk.c ++++ b/editors/awk.c +@@ -2910,19 +2910,14 @@ static var *evaluate(node *op, var *res) + /* yes, remember where Fields[] is */ + old_Fields_ptr = Fields; + } +- if (opinfo & OF_STR1) { +- L.s = getvar_s(L.v); +- debug_printf_eval("L.s:'%s'\n", L.s); +- } + if (opinfo & OF_NUM1) { + L_d = getvar_i(L.v); + debug_printf_eval("L_d:%f\n", L_d); + } + } +- /* NB: Must get string/numeric values of L (done above) +- * _before_ evaluate()'ing R.v: if both L and R are $NNNs, +- * and right one is large, then L.v points to Fields[NNN1], +- * second evaluate() reallocates and moves (!) Fields[], ++ /* NB: if both L and R are $NNNs, and right one is large, ++ * then at this pint L.v points to Fields[NNN1], second ++ * evaluate() below reallocates and moves (!) Fields[], + * R.v points to Fields[NNN2] but L.v now points to freed mem! + * (Seen trying to evaluate "$444 $44444") + */ +@@ -2942,6 +2937,16 @@ static var *evaluate(node *op, var *res) + debug_printf_eval("R.s:'%s'\n", R.s); + } + } ++ /* Get L.s _after_ R.v is evaluated: it may have realloc'd L.v ++ * so we must get the string after "old_Fields_ptr" correction ++ * above. Testcase: x = (v = "abc", gsub("b", "X", v)); ++ */ ++ if (opinfo & OF_RES1) { ++ if (opinfo & OF_STR1) { ++ L.s = getvar_s(L.v); ++ debug_printf_eval("L.s:'%s'\n", L.s); ++ } ++ } + + debug_printf_eval("switch(0x%x)\n", XC(opinfo & OPCLSMASK)); + switch (XC(opinfo & OPCLSMASK)) { +-- +2.30.2 + diff --git a/meta/recipes-core/busybox/busybox_1.36.1.bb b/meta/recipes-core/busybox/busybox_1.36.1.bb index 513dff8011..170447743c 100644 --- a/meta/recipes-core/busybox/busybox_1.36.1.bb +++ b/meta/recipes-core/busybox/busybox_1.36.1.bb @@ -52,6 +52,7 @@ SRC_URI = "https://busybox.net/downloads/busybox-${PV}.tar.bz2;name=tarball \ file://start-stop-false.patch \ file://CVE-2021-42380.patch \ file://0001-awk-fix-segfault-when-compiled-by-clang.patch \ + file://CVE-2023-42363.patch \ " SRC_URI:append:libc-musl = " file://musl.cfg " # TODO http://lists.busybox.net/pipermail/busybox/2023-January/090078.html From patchwork Thu Jul 18 13:45:32 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 46600 X-Patchwork-Delegate: steve@sakoman.com 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 4A0A9C3DA6F for ; Thu, 18 Jul 2024 13:46:01 +0000 (UTC) Received: from mail-pl1-f175.google.com (mail-pl1-f175.google.com [209.85.214.175]) by mx.groups.io with SMTP id smtpd.web11.15459.1721310356337709621 for ; Thu, 18 Jul 2024 06:45:56 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=M/L+ZDq+; spf=softfail (domain: sakoman.com, ip: 209.85.214.175, mailfrom: steve@sakoman.com) Received: by mail-pl1-f175.google.com with SMTP id d9443c01a7336-1fc2a194750so8243755ad.1 for ; Thu, 18 Jul 2024 06:45:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1721310355; x=1721915155; 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=rFCxNlNOdyrzB0lOFJxSxsgcSR9Log1ga0siY3/a16E=; b=M/L+ZDq+GF9v5ev1nOrkbhLXSO9un3aQ2qngHgS2SU0WQjaa47xfKyWZgxn7XdlmtW qjL6RFx4dwpuQalSySHQkp/NHhlxKbJO41uCNo81NYvoOIOUzZkJAhyfadj9gmrb+YO1 9IoUHmKepyS5B4fInjQ43uJCntHT7rkBkH3x7/yvdcozVPKMNyrKO4EpvIESAVmLTJ4r 8vJLDMrtIQZDTVo+0KDNTpbrbSOV4i/x5cppSrZLq3yFx5B6LyLx50xDjFqGkm+UFENs MUcNN/szxePfubJUYsggPKHRdfH/T//rmrSDPTRDWvjP30DQNlEVzYG0oexvDeOcPH1G KcUw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721310356; x=1721915156; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=rFCxNlNOdyrzB0lOFJxSxsgcSR9Log1ga0siY3/a16E=; b=XBrQU5BsFuBZ3jZuiZozC8C9cjzGvFviu39tc2l6wO/Gkzl8y3slX8vV7lJY694Ppe DPV0bvVg8pvbwisXAwA4mO+yVUCBq6so7UShKdXJ9KP0Sc3PjxGbKk74tOLCTdKhn4by I0Ex40KQQ0AEMe2ClqSZn2C15n1OrVtRFD7TvHPzjT2eLbNZQ63IRBcX8BPOJBts7/my zII9qm4M2f1dmEstuaeE2fhKHeaWjBrFsKdUNTBTP2vHDGAfWn1ISC+/112hL3VohKF4 XcPNy/mUJfYrHXOXOX6vlvi7vvbO7FhHry9fohpA6OJXPj8YV9m3b8KBKArzTTnEiOVu s+5w== X-Gm-Message-State: AOJu0YziylVDXtTZIeVA2/2mneI9uP6ONvBmqruixJaffKy3xoBZ9iHm sSHhw9nuSSaHJ2HF4Nza/HJax2AV5oXSyoRkKHtVMheys6TDhfkXQNgx5KCq59rDkLdTANYWFtS x X-Google-Smtp-Source: AGHT+IF1TwIA5k5aIwxByXsEyyEHgxtyY1SaIqcZIyJTyJhjj6vfJQp0n073xhoDacCyvZ2LTXZyKA== X-Received: by 2002:a17:902:c40a:b0:1fb:72ea:376 with SMTP id d9443c01a7336-1fc4e70b9cdmr35588995ad.65.1721310355515; Thu, 18 Jul 2024 06:45:55 -0700 (PDT) Received: from hexa.. ([98.142.47.158]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-1fc0bb6ffbdsm93366985ad.60.2024.07.18.06.45.54 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 18 Jul 2024 06:45:55 -0700 (PDT) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 03/12] vte: fix CVE-2024-37535 Date: Thu, 18 Jul 2024 06:45:32 -0700 Message-Id: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 18 Jul 2024 13:46:01 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/202216 From: Hitendra Prajapati Upstream-Status: Backport from https://gitlab.gnome.org/GNOME/vte/-/commit/036bc3ddcbb56f05c6ca76712a53b89dee1369e2 && https://gitlab.gnome.org/GNOME/vte/-/commit/c313849c2e5133802e21b13fa0b141b360171d39 Signed-off-by: Hitendra Prajapati Signed-off-by: Steve Sakoman --- .../vte/vte/CVE-2024-37535-01.patch | 64 ++++++++++++++ .../vte/vte/CVE-2024-37535-02.patch | 85 +++++++++++++++++++ meta/recipes-support/vte/vte_0.74.2.bb | 5 +- 3 files changed, 153 insertions(+), 1 deletion(-) create mode 100644 meta/recipes-support/vte/vte/CVE-2024-37535-01.patch create mode 100644 meta/recipes-support/vte/vte/CVE-2024-37535-02.patch diff --git a/meta/recipes-support/vte/vte/CVE-2024-37535-01.patch b/meta/recipes-support/vte/vte/CVE-2024-37535-01.patch new file mode 100644 index 0000000000..d18a3380af --- /dev/null +++ b/meta/recipes-support/vte/vte/CVE-2024-37535-01.patch @@ -0,0 +1,64 @@ +From 036bc3ddcbb56f05c6ca76712a53b89dee1369e2 Mon Sep 17 00:00:00 2001 +From: Christian Persch +Date: Sun, 2 Jun 2024 19:19:35 +0200 +Subject: [PATCH] emulation: Restrict resize request to sane numbers + +Fixes: https://gitlab.gnome.org/GNOME/vte/-/issues/2786 +(cherry picked from commit fd5511f24b7269195a7083f409244e9787c705dc) + + +Upstream-Status: Backport [https://gitlab.gnome.org/GNOME/vte/-/commit/036bc3ddcbb56f05c6ca76712a53b89dee1369e2] +CVE: CVE-2024-37535 +Signed-off-by: Hitendra Prajapati +--- + src/vteseq.cc | 20 ++++++++++++-------- + 1 file changed, 12 insertions(+), 8 deletions(-) + +diff --git a/src/vteseq.cc b/src/vteseq.cc +index 8d1c2e1..1c73dad 100644 +--- a/src/vteseq.cc ++++ b/src/vteseq.cc +@@ -208,9 +208,18 @@ Terminal::emit_bell() + /* Emit a "resize-window" signal. (Grid size.) */ + void + Terminal::emit_resize_window(guint columns, +- guint rows) +-{ +- _vte_debug_print(VTE_DEBUG_SIGNALS, "Emitting `resize-window'.\n"); ++ guint rows) ++{ ++ // Ignore resizes with excessive number of rows or columns, ++ // see https://gitlab.gnome.org/GNOME/vte/-/issues/2786 ++ if (columns < VTE_MIN_GRID_WIDTH || ++ columns > 511 || ++ rows < VTE_MIN_GRID_HEIGHT || ++ rows > 511) ++ return; ++ ++ _vte_debug_print(VTE_DEBUG_SIGNALS, "Emitting `resize-window' %d columns %d rows.\n", ++ columns, rows); + g_signal_emit(m_terminal, signals[SIGNAL_RESIZE_WINDOW], 0, columns, rows); + } + +@@ -4457,8 +4466,6 @@ Terminal::DECSLPP(vte::parser::Sequence const& seq) + else if (param < 24) + return; + +- _vte_debug_print(VTE_DEBUG_EMULATION, "Resizing to %d rows.\n", param); +- + emit_resize_window(m_column_count, param); + } + +@@ -8917,9 +8924,6 @@ Terminal::XTERM_WM(vte::parser::Sequence const& seq) + seq.collect(1, {&height, &width}); + + if (width != -1 && height != -1) { +- _vte_debug_print(VTE_DEBUG_EMULATION, +- "Resizing window to %d columns, %d rows.\n", +- width, height); + emit_resize_window(width, height); + } + break; +-- +2.25.1 + diff --git a/meta/recipes-support/vte/vte/CVE-2024-37535-02.patch b/meta/recipes-support/vte/vte/CVE-2024-37535-02.patch new file mode 100644 index 0000000000..032e00fb5c --- /dev/null +++ b/meta/recipes-support/vte/vte/CVE-2024-37535-02.patch @@ -0,0 +1,85 @@ +rom c313849c2e5133802e21b13fa0b141b360171d39 Mon Sep 17 00:00:00 2001 +From: Christian Persch +Date: Sun, 2 Jun 2024 19:19:35 +0200 +Subject: [PATCH] widget: Add safety limit to widget size requests + +https://gitlab.gnome.org/GNOME/vte/-/issues/2786 +(cherry picked from commit 1803ba866053a3d7840892b9d31fe2944a183eda) + +Upstream-Status: Backport [https://gitlab.gnome.org/GNOME/vte/-/commit/c313849c2e5133802e21b13fa0b141b360171d39] +CVE: CVE-2024-37535 +Signed-off-by: Hitendra Prajapati +--- + src/vtegtk.cc | 35 +++++++++++++++++++++++++++++++++++ + 1 file changed, 35 insertions(+) + +diff --git a/src/vtegtk.cc b/src/vtegtk.cc +index 0f4641d..060d27e 100644 +--- a/src/vtegtk.cc ++++ b/src/vtegtk.cc +@@ -91,6 +91,38 @@ + template + constexpr bool check_enum_value(T value) noexcept; + ++static inline void ++sanitise_widget_size_request(int* minimum, ++ int* natural) noexcept ++{ ++ // Overly large size requests will make gtk happily allocate ++ // a window size over the window system's limits (see ++ // e.g. https://gitlab.gnome.org/GNOME/vte/-/issues/2786), ++ // leading to aborting the whole process. ++ // The toolkit should be in a better position to know about ++ // these limits and not exceed them (which here is certainly ++ // possible since our minimum sizes are very small), let's ++ // limit the widget's size request to some large value ++ // that hopefully is within the absolute limits of ++ // the window system (assumed here to be int16 range, ++ // and leaving some space for the widgets that contain ++ // the terminal). ++ auto const limit = (1 << 15) - (1 << 12); ++ ++ if (*minimum > limit || *natural > limit) { ++ static auto warned = false; ++ ++ if (!warned) { ++ g_warning("Widget size request (minimum %d, natural %d) exceeds limits\n", ++ *minimum, *natural); ++ warned = true; ++ } ++ } ++ ++ *minimum = std::min(*minimum, limit); ++ *natural = std::clamp(*natural, *minimum, limit); ++} ++ + struct _VteTerminalClassPrivate { + GtkStyleProvider *style_provider; + }; +@@ -497,6 +529,7 @@ try + { + VteTerminal *terminal = VTE_TERMINAL(widget); + WIDGET(terminal)->get_preferred_width(minimum_width, natural_width); ++ sanitise_widget_size_request(minimum_width, natural_width); + } + catch (...) + { +@@ -511,6 +544,7 @@ try + { + VteTerminal *terminal = VTE_TERMINAL(widget); + WIDGET(terminal)->get_preferred_height(minimum_height, natural_height); ++ sanitise_widget_size_request(minimum_height, natural_height); + } + catch (...) + { +@@ -748,6 +782,7 @@ try + WIDGET(terminal)->measure(orientation, for_size, + minimum, natural, + minimum_baseline, natural_baseline); ++ sanitise_widget_size_request(minimum, natural); + } + catch (...) + { +-- +2.25.1 + diff --git a/meta/recipes-support/vte/vte_0.74.2.bb b/meta/recipes-support/vte/vte_0.74.2.bb index d8eafde2fb..af9ff1bb1d 100644 --- a/meta/recipes-support/vte/vte_0.74.2.bb +++ b/meta/recipes-support/vte/vte_0.74.2.bb @@ -18,7 +18,10 @@ GIDOCGEN_MESON_OPTION = "docs" inherit gnomebase gi-docgen features_check upstream-version-is-even gobject-introspection systemd vala -SRC_URI += "file://0001-Add-W_EXITCODE-macro-for-non-glibc-systems.patch" +SRC_URI += "file://0001-Add-W_EXITCODE-macro-for-non-glibc-systems.patch \ + file://CVE-2024-37535-01.patch \ + file://CVE-2024-37535-02.patch \ + " SRC_URI[archive.sha256sum] = "a535fb2a98fea8a2449cd1a02cccf5190131dddff52e715afdace3feb536eae7" ANY_OF_DISTRO_FEATURES = "${GTK3DISTROFEATURES}" From patchwork Thu Jul 18 13:45:33 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 46601 X-Patchwork-Delegate: steve@sakoman.com 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 7AF9DC3DA7E for ; Thu, 18 Jul 2024 13:46:01 +0000 (UTC) Received: from mail-pl1-f179.google.com (mail-pl1-f179.google.com [209.85.214.179]) by mx.groups.io with SMTP id smtpd.web10.15387.1721310357997938835 for ; Thu, 18 Jul 2024 06:45:58 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=OhjJwWgc; spf=softfail (domain: sakoman.com, ip: 209.85.214.179, mailfrom: steve@sakoman.com) Received: by mail-pl1-f179.google.com with SMTP id d9443c01a7336-1fc491f9b55so8628505ad.3 for ; Thu, 18 Jul 2024 06:45:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1721310357; x=1721915157; 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=mqGhD81nSc8I5ugPU79Uco4x8L2ot4UCAJPoWseKCjA=; b=OhjJwWgcG7/JMEdvReQZTkjxhAC1kkhTG/j9+1aON2Qoxs3xEv8SFyJeV1Fr3CzHts j2rKQ2MTlP3/NIAKx7GSUUsGEfvZRFFquk4UlvFk5tnxxk0w/8NuTAZQ+i8ak3l9ErBn zLcczaVO650EE2FLeWXkoIVVH9uUl3nYovfbk82DMqniBe+vdf4HWnC0S9TY0VwxnBkW f2aL8+cACb3piY1tVEY239R+i6U1Qy30Dl3S26BEJv99wK3V2IQ4GpamKtlVI2uA3bQA SI0yzdd6hLHWecHCvvvescB8SUJNcRkCv5Gyg0MN+339AT7zXBwsSm8Wzq5D6xLse3ZS jxZQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721310357; x=1721915157; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=mqGhD81nSc8I5ugPU79Uco4x8L2ot4UCAJPoWseKCjA=; b=IgD6utGX+L4MQTR9YJY0o+OrQH/1jaD/H3nUCQ2HQnsSAg4Ba0IKLwQZ2HLJFu4W9a oAgJw8xX2/LVJkO9F0en95iLA5DJ03LA2FeQifZEoJn3g2DY8xcHyRAu2bHgQOxwCb/t PDT8borUTYYupXyDvHXRG9vRN49ZiJqPF+kZA41l079acIGDFEVGPGZHLW+QGm18KSFg ZjGUyCOHkUG6PZcnNK9ema2NeWXq6oTG2jt+XiNLmCFpbxR3p0PzaT9W91wbx+NTEGzM ReQIYpWIGGd2YwgXu6FBNMrbnJGCKkl29iPiKrGJXhtjrBGcs1L0GJAPRFG0Xe0Z2o1A EWiQ== X-Gm-Message-State: AOJu0Yw4IMSIWZ6TSS/zPjbaEpMRdhtkXYxJWXZtkcj4o2cacYhJuIzu n0yaRlb6mo02MYUq/fxuofqBav3HULs/a6KOx/PHdLY2CdZB6QTf+PrYDAwyfau0emULvQmW7Ct T X-Google-Smtp-Source: AGHT+IEqkHWrkWblavHOI9yO4aBMK7sxHZZRcFJu80+TGVVEN0iv9mBrraE+1G8dHLHkpfzUQ+jOgQ== X-Received: by 2002:a17:903:2288:b0:1f7:13db:527b with SMTP id d9443c01a7336-1fc4e121c01mr49494375ad.7.1721310357223; Thu, 18 Jul 2024 06:45:57 -0700 (PDT) Received: from hexa.. ([98.142.47.158]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-1fc0bb6ffbdsm93366985ad.60.2024.07.18.06.45.56 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 18 Jul 2024 06:45:56 -0700 (PDT) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 04/12] less: fix CVE-2024-32487 Date: Thu, 18 Jul 2024 06:45:33 -0700 Message-Id: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 18 Jul 2024 13:46:01 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/202217 From: Archana Polampalli Signed-off-by: Archana Polampalli Signed-off-by: Steve Sakoman --- .../less/files/CVE-2024-32487.patch | 74 +++++++++++++++++++ meta/recipes-extended/less/less_643.bb | 1 + 2 files changed, 75 insertions(+) create mode 100644 meta/recipes-extended/less/files/CVE-2024-32487.patch diff --git a/meta/recipes-extended/less/files/CVE-2024-32487.patch b/meta/recipes-extended/less/files/CVE-2024-32487.patch new file mode 100644 index 0000000000..2d33099cd3 --- /dev/null +++ b/meta/recipes-extended/less/files/CVE-2024-32487.patch @@ -0,0 +1,74 @@ +From 007521ac3c95bc76e3d59c6dbfe75d06c8075c33 Mon Sep 17 00:00:00 2001 +From: Mark Nudelman +Date: Thu, 11 Apr 2024 17:49:48 -0700 +Subject: [PATCH] Fix bug when viewing a file whose name contains a newline. + +CVE: CVE-2024-32487 + +Upstream-Status: Backport [https://github.com/gwsw/less/commit/007521ac3c95bc76e3d59c6dbfe75d06c8075c33] + +Signed-off-by: Archana Polampalli +--- + filename.c | 29 ++++++++++++++++++++++++----- + 1 file changed, 24 insertions(+), 5 deletions(-) + +diff --git a/filename.c b/filename.c +index a8726dc..c4b35b1 100644 +--- a/filename.c ++++ b/filename.c +@@ -133,6 +133,15 @@ static int metachar(char c) + return (strchr(metachars(), c) != NULL); + } + ++/* ++ * Must use quotes rather than escape char for this metachar? ++ */ ++static int must_quote(char c) ++{ ++ /* {{ Maybe the set of must_quote chars should be configurable? }} */ ++ return (c == '\n'); ++} ++ + /* + * Insert a backslash before each metacharacter in a string. + */ +@@ -164,6 +173,9 @@ public char * shell_quote(char *s) + * doesn't support escape chars. Use quotes. + */ + use_quotes = 1; ++ } else if (must_quote(*p)) ++ { ++ len += 3; /* open quote + char + close quote */ + } else + { + /* +@@ -193,15 +205,22 @@ public char * shell_quote(char *s) + { + while (*s != '\0') + { +- if (metachar(*s)) ++ if (!metachar(*s)) + { +- /* +- * Add the escape char. +- */ ++ *p++ = *s++; ++ } else if (must_quote(*s)) ++ { ++ /* Surround the char with quotes. */ ++ *p++ = openquote; ++ *p++ = *s++; ++ *p++ = closequote; ++ } else ++ { ++ /* Insert an escape char before the char. */ + strcpy(p, esc); + p += esclen; ++ *p++ = *s++; + } +- *p++ = *s++; + } + *p = '\0'; + } +-- +2.40.0 diff --git a/meta/recipes-extended/less/less_643.bb b/meta/recipes-extended/less/less_643.bb index 67834bdd58..537283bde4 100644 --- a/meta/recipes-extended/less/less_643.bb +++ b/meta/recipes-extended/less/less_643.bb @@ -27,6 +27,7 @@ DEPENDS = "ncurses" SRC_URI = "http://www.greenwoodsoftware.com/${BPN}/${BPN}-${PV}.tar.gz \ file://run-ptest \ + file://CVE-2024-32487.patch \ " SRC_URI[sha256sum] = "2911b5432c836fa084c8a2e68f6cd6312372c026a58faaa98862731c8b6052e8" From patchwork Thu Jul 18 13:45:34 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 46597 X-Patchwork-Delegate: steve@sakoman.com 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 232E9C3DA49 for ; Thu, 18 Jul 2024 13:46:01 +0000 (UTC) Received: from mail-pg1-f170.google.com (mail-pg1-f170.google.com [209.85.215.170]) by mx.groups.io with SMTP id smtpd.web10.15388.1721310360064708908 for ; Thu, 18 Jul 2024 06:46:00 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=E7OD4Pag; spf=softfail (domain: sakoman.com, ip: 209.85.215.170, mailfrom: steve@sakoman.com) Received: by mail-pg1-f170.google.com with SMTP id 41be03b00d2f7-78964fd9f2dso558851a12.3 for ; Thu, 18 Jul 2024 06:46:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1721310359; x=1721915159; 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=DAkNpWnSKRt5BmLxxPwZJSpdZ+nQYkhnAQxi1uErDo0=; b=E7OD4PagIJkKzw0ZZF89KSe7WETkUcG8lOIy8zqDSa6CL0BYrQkmycYDEhf1Amyqg5 ne5+qFB1886rGNlky9fL35p/v+tDzuolAuyikbM1wkcoyr7yFqJqIqIYw3Vhli+nBkxk tNEOZapqhRQHv0UxdEyNg2C7jO8RM3uw95V5efSjP0En8XRRsVns61eGmoWNYCeX5JmX 68WCAVfvBksA5MCLFf5aLbVl+3YqhAQj0tzfPbpe+60CwRwNwmAy6amd+XMWzwDy6ofg XxtZFGKkIQW63VvK78U0+tChZETReM25c2i+uRJIKFcYrQPUOZSdObz3ytEczhhVW/JM qmSw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721310359; x=1721915159; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=DAkNpWnSKRt5BmLxxPwZJSpdZ+nQYkhnAQxi1uErDo0=; b=cFblZ7M40Qgw1/Uto8fnTiTxBEOYKh+oMX3GzLVSYavHNtTShoo8Aak8u5mSWy61AZ hRnFRgQDecNOBt+hI+zyQUsra10lTQ7Hit63Cvv7hI/FuGIfAKklEbXVZlATB8hO9y1J vjBDraVLH57vK+HEtUieC0rNYezB9rUzAnCDDlfUmBb/6o25mb7o8hcMOb5JKBF0TmvK Gf8rSh9Hc0iUQBG/2eZHvjAkv6aNrmUsqShjaVKSijP8FYSyFP/Kim8YOFTYal0Mprcf tc86rJCoio9SRrfUCKwj58jFtf5VKJYudazjtP9xf4AMx6Cn60EYhcHRmWn01OjYBot1 fjOQ== X-Gm-Message-State: AOJu0YwCZgqjC46uprISgxC0QXl9TSDO9P/fjRFiE+yJCHv6IaO3QQqa 8qsOZan4SqHuKlgrOHaObtqN9msr+195uwHVl+0mJQqX1uQhEBEdwgnOWCBSKPdluo3r85KSIdO C X-Google-Smtp-Source: AGHT+IHMgSzBw0I4gANgWSgcoaAT2WYRvJsVES8h8aNs9m4T58WqDbS/cyD5eqmMUo0oLeOgMLjyKw== X-Received: by 2002:a05:6a20:d50a:b0:1bd:1d15:f089 with SMTP id adf61e73a8af0-1c3fddf9dd8mr4717054637.54.1721310359050; Thu, 18 Jul 2024 06:45:59 -0700 (PDT) Received: from hexa.. ([98.142.47.158]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-1fc0bb6ffbdsm93366985ad.60.2024.07.18.06.45.58 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 18 Jul 2024 06:45:58 -0700 (PDT) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 05/12] openssh: fix CVE-2024-39894 Date: Thu, 18 Jul 2024 06:45:34 -0700 Message-Id: <644716564d8c223c71be635e2f1794c74ae23d7f.1721310237.git.steve@sakoman.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 18 Jul 2024 13:46:01 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/202218 From: Vijay Anusuri ssh(1) in OpenSSH versions 9.5p1 to 9.7p1 (inclusive). Logic error in ObscureKeystrokeTiming option. A logic error in the implementation of the ssh(1) ObscureKeystrokeTiming option rendered the feature ineffective and additionally exposed limited keystroke timing information when terminal echo was disabled, e.g. while entering passwords to su(8) or sudo(8). This condition could be avoided for affected versions by disabling the feature using ObscureKeystrokeTiming=no. References: https://www.openssh.com/security.html https://www.openssh.com/txt/release-9.8 Upstream-Status: Backport [https://github.com/openssh/openssh-portable/commit/146c420d29d055cc75c8606327a1cf8439fe3a08] Signed-off-by: Vijay Anusuri Signed-off-by: Steve Sakoman --- .../openssh/openssh/CVE-2024-39894.patch | 35 +++++++++++++++++++ .../openssh/openssh_9.6p1.bb | 1 + 2 files changed, 36 insertions(+) create mode 100644 meta/recipes-connectivity/openssh/openssh/CVE-2024-39894.patch diff --git a/meta/recipes-connectivity/openssh/openssh/CVE-2024-39894.patch b/meta/recipes-connectivity/openssh/openssh/CVE-2024-39894.patch new file mode 100644 index 0000000000..898295340d --- /dev/null +++ b/meta/recipes-connectivity/openssh/openssh/CVE-2024-39894.patch @@ -0,0 +1,35 @@ +From 146c420d29d055cc75c8606327a1cf8439fe3a08 Mon Sep 17 00:00:00 2001 +From: "djm@openbsd.org" +Date: Mon, 1 Jul 2024 04:31:17 +0000 +Subject: [PATCH] upstream: when sending ObscureKeystrokeTiming chaff packets, + we + +can't rely on channel_did_enqueue to tell that there is data to send. This +flag indicates that the channels code enqueued a packet on _this_ ppoll() +iteration, not that data was enqueued in _any_ ppoll() iteration in the +timeslice. ok markus@ + +OpenBSD-Commit-ID: 009b74fd2769b36b5284a0188ade182f00564136 + +Upstream-Status: Backport [import from ubuntu https://git.launchpad.net/ubuntu/+source/openssh/tree/debian/patches/CVE-2024-39894.patch?h=ubuntu/noble-security +Upstream commit https://github.com/openssh/openssh-portable/commit/146c420d29d055cc75c8606327a1cf8439fe3a08] +CVE: CVE-2024-39894 +Signed-off-by: Vijay Anusuri +--- + clientloop.c | 7 ++++--- + 1 file changed, 4 insertions(+), 3 deletions(-) + +--- a/clientloop.c ++++ b/clientloop.c +@@ -612,8 +612,9 @@ obfuscate_keystroke_timing(struct ssh *s + if (timespeccmp(&now, &chaff_until, >=)) { + /* Stop if there have been no keystrokes for a while */ + stop_reason = "chaff time expired"; +- } else if (timespeccmp(&now, &next_interval, >=)) { +- /* Otherwise if we were due to send, then send chaff */ ++ } else if (timespeccmp(&now, &next_interval, >=) && ++ !ssh_packet_have_data_to_write(ssh)) { ++ /* If due to send but have no data, then send chaff */ + if (send_chaff(ssh)) + nchaff++; + } diff --git a/meta/recipes-connectivity/openssh/openssh_9.6p1.bb b/meta/recipes-connectivity/openssh/openssh_9.6p1.bb index 3cdf0327b0..8bc4f4269a 100644 --- a/meta/recipes-connectivity/openssh/openssh_9.6p1.bb +++ b/meta/recipes-connectivity/openssh/openssh_9.6p1.bb @@ -28,6 +28,7 @@ SRC_URI = "http://ftp.openbsd.org/pub/OpenBSD/OpenSSH/portable/openssh-${PV}.tar file://0001-regress-banner.sh-log-input-and-output-files-on-erro.patch \ file://0001-systemd-Add-optional-support-for-systemd-sd_notify.patch \ file://CVE-2024-6387.patch \ + file://CVE-2024-39894.patch \ " SRC_URI[sha256sum] = "910211c07255a8c5ad654391b40ee59800710dd8119dd5362de09385aa7a777c" From patchwork Thu Jul 18 13:45:35 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 46603 X-Patchwork-Delegate: steve@sakoman.com 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 43071C3DA49 for ; Thu, 18 Jul 2024 13:46:11 +0000 (UTC) Received: from mail-pg1-f180.google.com (mail-pg1-f180.google.com [209.85.215.180]) by mx.groups.io with SMTP id smtpd.web11.15463.1721310362183462589 for ; Thu, 18 Jul 2024 06:46:02 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=MTR/Of7h; spf=softfail (domain: sakoman.com, ip: 209.85.215.180, mailfrom: steve@sakoman.com) Received: by mail-pg1-f180.google.com with SMTP id 41be03b00d2f7-7515437ff16so586203a12.2 for ; Thu, 18 Jul 2024 06:46:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1721310361; x=1721915161; 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=MI7s55Ck3mPfoK9yvZeatZHW+/LkLVQjQhig/WsAJZM=; b=MTR/Of7hhpR2deXSt0yjphO90UFCGmRH/N0vUv2DdwHILfcSLFm5lnUhuk9zPuj011 CcNVisW9cDiz/QAM+dgfCx8D6RsX3TZNS2lWLYZwazqaLaW3ZsdpidbqW/T+N0o+8Agu YTn8OsY1g7UijETCg6gBKPoXdVcmd062K1oVi0w7TxOAiOW8YZVWq2ctwdJEe8VPVfpa NOg0ZE0ZDuSiOR4e49+wkYSvfvN7JIFGSSart7isDzkrR5HvRz+z461SB926oSWh8EG/ 2ZhohcpIOzLikEsMQUd+EIbav3C20xJM3HXhGxf7vBjI4eJK/n0kV/y64XkDoJK1eoQY 4XNg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721310361; x=1721915161; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=MI7s55Ck3mPfoK9yvZeatZHW+/LkLVQjQhig/WsAJZM=; b=SzXhmOmzQ4DArh6sQzoujdbFvpL0vAa0pRdbNSezhXc2DIaAC2w24pCCgKqJb9wjcf 4wdcBevcmcvbOLMmQShEG1f0gLBM1QSfwDwZtjksp1uMCiXd9PZd4sWCH3AWrjMifbgf mQcr8U37KXxg5CO9wHygSv5vkZkQk2/aLFCT1IskqyBDmkp96903wEtU4FnZUHib53ng 5eOvnfiPuasiAdudI2igU0ravXPRX3q2YdtFS6Q3dz2wxDbJFcFJeGVPqTbUUmj/Va9h 0+zjOsyXVcAPtg1SEVVpKr+Snq3PDq2EhdGb9DSPeLyneumeRp7PrVdrekraW9x26AEM kiKQ== X-Gm-Message-State: AOJu0Yx88kn10+NIPLd7fSDDhIqiHwBNKprIrxwLWNjJOc3vECbbaF9U +s3knhq2LNKDiqykoQg1ijMtYh9f/BmzI3wRih5xICNEs3iYS4FBHkqzCqInfe+ZeMpPCdk49J+ a X-Google-Smtp-Source: AGHT+IFrrin26dVF1LiAmNC61y0+FH2GpuouEr9or4BXbQ5kbwueX1VbhD1YZHH7UI/YCjBUkMTzCw== X-Received: by 2002:a05:6a20:1582:b0:1c0:f323:1b9d with SMTP id adf61e73a8af0-1c3fdcff646mr5952444637.20.1721310361296; Thu, 18 Jul 2024 06:46:01 -0700 (PDT) Received: from hexa.. ([98.142.47.158]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-1fc0bb6ffbdsm93366985ad.60.2024.07.18.06.46.00 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 18 Jul 2024 06:46:01 -0700 (PDT) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 06/12] go: upgrade 1.22.4 -> 1.22.5 Date: Thu, 18 Jul 2024 06:45:35 -0700 Message-Id: <8786cb9cdda93545315f79927f933a261ed3cb31.1721310237.git.steve@sakoman.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 18 Jul 2024 13:46:11 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/202219 From: Jose Quaresma - refresh patches with devtool Upgrade to latest 1.22.x release [1]: $ git --no-pager log --oneline go1.22.4..go1.22.5 8e1fdea831 (tag: go1.22.5, origin/release-branch.go1.22) [release-branch.go1.22] go1.22.5 c2d4f852ce [release-branch.go1.22] cmd/link: handle dynamic import variables on Darwin in plugin mode 3222951439 [release-branch.go1.22] net/http: send body or close connection on expect-100-continue requests ceaf26ecce [release-branch.go1.22] cmd/compile: mark pointer to noalg type as noalg dfe4dbf8c0 [release-branch.go1.22] os/exec: on Windows look for extensions in Run if not already done 3560cf0afb [release-branch.go1.22] runtime: always update stack bounds on cgocallback 5159a7193a [release-branch.go1.22] cmd/compile: put constants before variables in initialization order 11b861e459 [release-branch.go1.22] go/types, types2: report error for floating-point iteration variable 81fc616267 [release-branch.go1.22] crypto/tls: don't call tlsrsakex.IncNonDefault with FIPS 14f0251867 [release-branch.go1.22] cmd/cgo/internal/swig: force use of lld for LTO tests on the builders ab60a7bc18 [release-branch.go1.22] cmd/cgo/internal/testsanitizers: make the libfuzzer tests all short 4c97e883b5 [release-branch.go1.22] cmd/link: put runtime.end in the last section of data segment 179ccb7042 [release-branch.go1.22] cmd/go: fix go list -u -m all with too new retractions dependency fe9b3c3399 [release-branch.go1.22] net: add GODEBUG=netedns0=0 to disable sending EDNS0 header b515c5208b [release-branch.go1.22] go/internal/gccgoimporter: recognize "any" as a builtin type [1] https://github.com/golang/go/compare/go1.22.4...go1.22.5 Signed-off-by: Jose Quaresma Signed-off-by: Richard Purdie (cherry picked from commit 0a1d4a42282bd9f0bdc8dd53c7865aa81d4a5821) Signed-off-by: Jose Quaresma Signed-off-by: Steve Sakoman --- .../go/{go-1.22.4.inc => go-1.22.5.inc} | 2 +- ...-native_1.22.4.bb => go-binary-native_1.22.5.bb} | 6 +++--- ...nadian_1.22.4.bb => go-cross-canadian_1.22.5.bb} | 0 .../go/{go-cross_1.22.4.bb => go-cross_1.22.5.bb} | 0 ...{go-crosssdk_1.22.4.bb => go-crosssdk_1.22.5.bb} | 0 .../{go-runtime_1.22.4.bb => go-runtime_1.22.5.bb} | 0 ...e-content-based-hash-generation-less-pedan.patch | 11 ++++------- ...ow-GOTOOLDIR-to-be-overridden-in-the-envir.patch | 12 ++++-------- .../0003-ld-add-soname-to-shareable-objects.patch | 9 +++------ ...override-CC-when-building-dist-and-go_boot.patch | 10 +++------- ...5-cmd-dist-separate-host-and-target-builds.patch | 9 +++------ ...006-cmd-go-make-GOROOT-precious-by-default.patch | 13 +++++-------- ...lter-out-build-specific-paths-from-linker-.patch | 12 +++++------- ...st-buildgo.go-do-not-hardcode-host-compile.patch | 11 ++++------- ...lter-build-paths-on-staticly-linked-arches.patch | 9 +++------ .../go/{go_1.22.4.bb => go_1.22.5.bb} | 0 16 files changed, 38 insertions(+), 66 deletions(-) rename meta/recipes-devtools/go/{go-1.22.4.inc => go-1.22.5.inc} (89%) rename meta/recipes-devtools/go/{go-binary-native_1.22.4.bb => go-binary-native_1.22.5.bb} (78%) rename meta/recipes-devtools/go/{go-cross-canadian_1.22.4.bb => go-cross-canadian_1.22.5.bb} (100%) rename meta/recipes-devtools/go/{go-cross_1.22.4.bb => go-cross_1.22.5.bb} (100%) rename meta/recipes-devtools/go/{go-crosssdk_1.22.4.bb => go-crosssdk_1.22.5.bb} (100%) rename meta/recipes-devtools/go/{go-runtime_1.22.4.bb => go-runtime_1.22.5.bb} (100%) rename meta/recipes-devtools/go/{go_1.22.4.bb => go_1.22.5.bb} (100%) diff --git a/meta/recipes-devtools/go/go-1.22.4.inc b/meta/recipes-devtools/go/go-1.22.5.inc similarity index 89% rename from meta/recipes-devtools/go/go-1.22.4.inc rename to meta/recipes-devtools/go/go-1.22.5.inc index 44897daba4..7f7d8377ca 100644 --- a/meta/recipes-devtools/go/go-1.22.4.inc +++ b/meta/recipes-devtools/go/go-1.22.5.inc @@ -15,4 +15,4 @@ SRC_URI += "\ file://0008-src-cmd-dist-buildgo.go-do-not-hardcode-host-compile.patch \ file://0009-go-Filter-build-paths-on-staticly-linked-arches.patch \ " -SRC_URI[main.sha256sum] = "fed720678e728a7ca30ba8d1ded1caafe27d16028fab0232b8ba8e22008fb784" +SRC_URI[main.sha256sum] = "ac9c723f224969aee624bc34fd34c9e13f2a212d75c71c807de644bb46e112f6" diff --git a/meta/recipes-devtools/go/go-binary-native_1.22.4.bb b/meta/recipes-devtools/go/go-binary-native_1.22.5.bb similarity index 78% rename from meta/recipes-devtools/go/go-binary-native_1.22.4.bb rename to meta/recipes-devtools/go/go-binary-native_1.22.5.bb index 61da51be3a..b00857f001 100644 --- a/meta/recipes-devtools/go/go-binary-native_1.22.4.bb +++ b/meta/recipes-devtools/go/go-binary-native_1.22.5.bb @@ -9,9 +9,9 @@ PROVIDES = "go-native" # Checksums available at https://go.dev/dl/ SRC_URI = "https://dl.google.com/go/go${PV}.${BUILD_GOOS}-${BUILD_GOARCH}.tar.gz;name=go_${BUILD_GOTUPLE}" -SRC_URI[go_linux_amd64.sha256sum] = "ba79d4526102575196273416239cca418a651e049c2b099f3159db85e7bade7d" -SRC_URI[go_linux_arm64.sha256sum] = "a8e177c354d2e4a1b61020aca3562e27ea3e8f8247eca3170e3fa1e0c2f9e771" -SRC_URI[go_linux_ppc64le.sha256sum] = "a3e5834657ef92523f570f798fed42f1f87bc18222a16815ec76b84169649ec4" +SRC_URI[go_linux_amd64.sha256sum] = "904b924d435eaea086515bc63235b192ea441bd8c9b198c507e85009e6e4c7f0" +SRC_URI[go_linux_arm64.sha256sum] = "8d21325bfcf431be3660527c1a39d3d9ad71535fabdf5041c826e44e31642b5a" +SRC_URI[go_linux_ppc64le.sha256sum] = "5312bb420ac0b59175a58927e70b4660b14ab7319aab54398b6071fabcbfbb09" UPSTREAM_CHECK_URI = "https://golang.org/dl/" UPSTREAM_CHECK_REGEX = "go(?P\d+(\.\d+)+)\.linux" diff --git a/meta/recipes-devtools/go/go-cross-canadian_1.22.4.bb b/meta/recipes-devtools/go/go-cross-canadian_1.22.5.bb similarity index 100% rename from meta/recipes-devtools/go/go-cross-canadian_1.22.4.bb rename to meta/recipes-devtools/go/go-cross-canadian_1.22.5.bb diff --git a/meta/recipes-devtools/go/go-cross_1.22.4.bb b/meta/recipes-devtools/go/go-cross_1.22.5.bb similarity index 100% rename from meta/recipes-devtools/go/go-cross_1.22.4.bb rename to meta/recipes-devtools/go/go-cross_1.22.5.bb diff --git a/meta/recipes-devtools/go/go-crosssdk_1.22.4.bb b/meta/recipes-devtools/go/go-crosssdk_1.22.5.bb similarity index 100% rename from meta/recipes-devtools/go/go-crosssdk_1.22.4.bb rename to meta/recipes-devtools/go/go-crosssdk_1.22.5.bb diff --git a/meta/recipes-devtools/go/go-runtime_1.22.4.bb b/meta/recipes-devtools/go/go-runtime_1.22.5.bb similarity index 100% rename from meta/recipes-devtools/go/go-runtime_1.22.4.bb rename to meta/recipes-devtools/go/go-runtime_1.22.5.bb diff --git a/meta/recipes-devtools/go/go/0001-cmd-go-make-content-based-hash-generation-less-pedan.patch b/meta/recipes-devtools/go/go/0001-cmd-go-make-content-based-hash-generation-less-pedan.patch index 564837c7cd..a8e5d6e86d 100644 --- a/meta/recipes-devtools/go/go/0001-cmd-go-make-content-based-hash-generation-less-pedan.patch +++ b/meta/recipes-devtools/go/go/0001-cmd-go-make-content-based-hash-generation-less-pedan.patch @@ -1,7 +1,7 @@ -From 9a6c5040cbcd88b10ceb8ceaebc8d6158c086670 Mon Sep 17 00:00:00 2001 +From 9b3ebef0356594a447906f00fe80584952c08289 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Mon, 28 Mar 2022 10:59:03 -0700 -Subject: [PATCH 1/9] cmd/go: make content-based hash generation less pedantic +Subject: [PATCH] cmd/go: make content-based hash generation less pedantic Go 1.10's build tool now uses content-based hashes to determine when something should be built or re-built. @@ -32,7 +32,7 @@ Signed-off-by: Jose Quaresma 2 files changed, 36 insertions(+), 10 deletions(-) diff --git a/src/cmd/go/internal/envcmd/env.go b/src/cmd/go/internal/envcmd/env.go -index c7c2e83e0f..4a90d9da5c 100644 +index c7c2e83..4a90d9d 100644 --- a/src/cmd/go/internal/envcmd/env.go +++ b/src/cmd/go/internal/envcmd/env.go @@ -189,7 +189,7 @@ func ExtraEnvVarsCostly() []cfg.EnvVar { @@ -45,7 +45,7 @@ index c7c2e83e0f..4a90d9da5c 100644 // Should not happen - b.CFlags was given an empty package. fmt.Fprintf(os.Stderr, "go: invalid cflags: %v\n", err) diff --git a/src/cmd/go/internal/work/exec.go b/src/cmd/go/internal/work/exec.go -index e05471b06c..9724cd07d0 100644 +index e05471b..9724cd0 100644 --- a/src/cmd/go/internal/work/exec.go +++ b/src/cmd/go/internal/work/exec.go @@ -232,6 +232,8 @@ func (b *Builder) Do(ctx context.Context, root *Action) { @@ -163,6 +163,3 @@ index e05471b06c..9724cd07d0 100644 if err != nil { return "", "", err } --- -2.44.0 - diff --git a/meta/recipes-devtools/go/go/0002-cmd-go-Allow-GOTOOLDIR-to-be-overridden-in-the-envir.patch b/meta/recipes-devtools/go/go/0002-cmd-go-Allow-GOTOOLDIR-to-be-overridden-in-the-envir.patch index 001c94a4e7..a69ada47b0 100644 --- a/meta/recipes-devtools/go/go/0002-cmd-go-Allow-GOTOOLDIR-to-be-overridden-in-the-envir.patch +++ b/meta/recipes-devtools/go/go/0002-cmd-go-Allow-GOTOOLDIR-to-be-overridden-in-the-envir.patch @@ -1,8 +1,7 @@ -From e3f9a8a69d3a340c1a1d0bba566e71f20f635a43 Mon Sep 17 00:00:00 2001 +From 687ff9d17f756145f9a58413070cccbd488d1ea2 Mon Sep 17 00:00:00 2001 From: Alex Kube Date: Wed, 23 Oct 2019 21:15:37 +0430 -Subject: [PATCH 2/9] cmd/go: Allow GOTOOLDIR to be overridden in the - environment +Subject: [PATCH] cmd/go: Allow GOTOOLDIR to be overridden in the environment to allow for split host/target build roots @@ -20,7 +19,7 @@ Signed-off-by: Jose Quaresma 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/cmd/dist/build.go b/src/cmd/dist/build.go -index 32e59b446a..06ee4de8a9 100644 +index 32e59b4..06ee4de 100644 --- a/src/cmd/dist/build.go +++ b/src/cmd/dist/build.go @@ -259,7 +259,9 @@ func xinit() { @@ -35,7 +34,7 @@ index 32e59b446a..06ee4de8a9 100644 goversion := findgoversion() isRelease = strings.HasPrefix(goversion, "release.") || strings.HasPrefix(goversion, "go") diff --git a/src/cmd/go/internal/cfg/cfg.go b/src/cmd/go/internal/cfg/cfg.go -index a8daa2dfc3..393ada39c9 100644 +index a8daa2d..393ada3 100644 --- a/src/cmd/go/internal/cfg/cfg.go +++ b/src/cmd/go/internal/cfg/cfg.go @@ -230,7 +230,11 @@ func SetGOROOT(goroot string, isTestGo bool) { @@ -51,6 +50,3 @@ index a8daa2dfc3..393ada39c9 100644 } } } --- -2.44.0 - diff --git a/meta/recipes-devtools/go/go/0003-ld-add-soname-to-shareable-objects.patch b/meta/recipes-devtools/go/go/0003-ld-add-soname-to-shareable-objects.patch index 9cab2969c8..abc5faa21c 100644 --- a/meta/recipes-devtools/go/go/0003-ld-add-soname-to-shareable-objects.patch +++ b/meta/recipes-devtools/go/go/0003-ld-add-soname-to-shareable-objects.patch @@ -1,7 +1,7 @@ -From 7dde77b3ce8138314dd2736604b1b110dbcc0ac1 Mon Sep 17 00:00:00 2001 +From 01fe178b292db12d811811ff2d8d56b225e4b5e8 Mon Sep 17 00:00:00 2001 From: Alex Kube Date: Wed, 23 Oct 2019 21:16:32 +0430 -Subject: [PATCH 3/9] ld: add soname to shareable objects +Subject: [PATCH] ld: add soname to shareable objects so that OE's shared library dependency handling can find them. @@ -19,7 +19,7 @@ Signed-off-by: Jose Quaresma 1 file changed, 3 insertions(+) diff --git a/src/cmd/link/internal/ld/lib.go b/src/cmd/link/internal/ld/lib.go -index eab74dc328..ae9bbc9093 100644 +index eab74dc..ae9bbc9 100644 --- a/src/cmd/link/internal/ld/lib.go +++ b/src/cmd/link/internal/ld/lib.go @@ -1576,6 +1576,7 @@ func (ctxt *Link) hostlink() { @@ -46,6 +46,3 @@ index eab74dc328..ae9bbc9093 100644 } } --- -2.44.0 - diff --git a/meta/recipes-devtools/go/go/0004-make.bash-override-CC-when-building-dist-and-go_boot.patch b/meta/recipes-devtools/go/go/0004-make.bash-override-CC-when-building-dist-and-go_boot.patch index 8889aef1cf..9df43c46d0 100644 --- a/meta/recipes-devtools/go/go/0004-make.bash-override-CC-when-building-dist-and-go_boot.patch +++ b/meta/recipes-devtools/go/go/0004-make.bash-override-CC-when-building-dist-and-go_boot.patch @@ -1,8 +1,7 @@ -From 9f59e46991074d3e3c4d00f3971e62bfcd707167 Mon Sep 17 00:00:00 2001 +From e47d157631d1b97403f253c63d361b7380b32c22 Mon Sep 17 00:00:00 2001 From: Alex Kube Date: Wed, 23 Oct 2019 21:17:16 +0430 -Subject: [PATCH 4/9] make.bash: override CC when building dist and - go_bootstrap +Subject: [PATCH] make.bash: override CC when building dist and go_bootstrap for handling OE cross-canadian builds. @@ -19,7 +18,7 @@ Signed-off-by: Jose Quaresma 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/make.bash b/src/make.bash -index 76ad51624a..074e129a24 100755 +index 76ad516..074e129 100755 --- a/src/make.bash +++ b/src/make.bash @@ -198,7 +198,7 @@ if [[ "$GOROOT_BOOTSTRAP" == "$GOROOT" ]]; then @@ -40,6 +39,3 @@ index 76ad51624a..074e129a24 100755 rm -f ./cmd/dist/dist # DO NOT ADD ANY NEW CODE HERE. --- -2.44.0 - diff --git a/meta/recipes-devtools/go/go/0005-cmd-dist-separate-host-and-target-builds.patch b/meta/recipes-devtools/go/go/0005-cmd-dist-separate-host-and-target-builds.patch index 364fce907a..bc25d08fbf 100644 --- a/meta/recipes-devtools/go/go/0005-cmd-dist-separate-host-and-target-builds.patch +++ b/meta/recipes-devtools/go/go/0005-cmd-dist-separate-host-and-target-builds.patch @@ -1,7 +1,7 @@ -From 6dda78d528e60993a4688cd9d49440a726378ac8 Mon Sep 17 00:00:00 2001 +From bae1cec790ff17c4c93a2f8fda27036e5e021f6d Mon Sep 17 00:00:00 2001 From: Alex Kube Date: Wed, 23 Oct 2019 21:18:12 +0430 -Subject: [PATCH 5/9] cmd/dist: separate host and target builds +Subject: [PATCH] cmd/dist: separate host and target builds Change the dist tool to allow for OE-style cross- and cross-canadian builds: @@ -45,7 +45,7 @@ Signed-off-by: Jose Quaresma 1 file changed, 75 insertions(+), 1 deletion(-) diff --git a/src/cmd/dist/build.go b/src/cmd/dist/build.go -index 06ee4de8a9..74b7c7098f 100644 +index 06ee4de..016b1dd 100644 --- a/src/cmd/dist/build.go +++ b/src/cmd/dist/build.go @@ -46,6 +46,7 @@ var ( @@ -216,6 +216,3 @@ index 06ee4de8a9..74b7c7098f 100644 if goos == "android" { // Make sure the exec wrapper will sync a fresh $GOROOT to the device. --- -2.44.0 - diff --git a/meta/recipes-devtools/go/go/0006-cmd-go-make-GOROOT-precious-by-default.patch b/meta/recipes-devtools/go/go/0006-cmd-go-make-GOROOT-precious-by-default.patch index 262f1e96b8..4a57b07b7a 100644 --- a/meta/recipes-devtools/go/go/0006-cmd-go-make-GOROOT-precious-by-default.patch +++ b/meta/recipes-devtools/go/go/0006-cmd-go-make-GOROOT-precious-by-default.patch @@ -1,7 +1,7 @@ -From aff5a740d6286c04beb0593fc68b0aea5a95ad39 Mon Sep 17 00:00:00 2001 +From a31db6f78d851741aea1e76132a84a24138a5bc6 Mon Sep 17 00:00:00 2001 From: Alex Kube Date: Wed, 23 Oct 2019 21:18:56 +0430 -Subject: [PATCH 6/9] cmd/go: make GOROOT precious by default +Subject: [PATCH] cmd/go: make GOROOT precious by default The go build tool normally rebuilds whatever it detects is stale. This can be a problem when GOROOT is intended to @@ -29,7 +29,7 @@ Signed-off-by: Jose Quaresma 3 files changed, 34 insertions(+) diff --git a/src/cmd/go/internal/work/action.go b/src/cmd/go/internal/work/action.go -index a59072e591..9e35ebde0c 100644 +index a59072e..9e35ebd 100644 --- a/src/cmd/go/internal/work/action.go +++ b/src/cmd/go/internal/work/action.go @@ -754,6 +754,9 @@ func (b *Builder) addTransitiveLinkDeps(a, a1 *Action, shlib string) { @@ -43,7 +43,7 @@ index a59072e591..9e35ebde0c 100644 // TODO(rsc): The use of ModeInstall here is suspect, but if we only do ModeBuild, // we'll end up building an overall library or executable that depends at runtime diff --git a/src/cmd/go/internal/work/build.go b/src/cmd/go/internal/work/build.go -index 408edb5119..3d60252127 100644 +index 408edb5..3d60252 100644 --- a/src/cmd/go/internal/work/build.go +++ b/src/cmd/go/internal/work/build.go @@ -233,6 +233,8 @@ See also: go install, go get, go clean. @@ -67,7 +67,7 @@ index 408edb5119..3d60252127 100644 // Note that flags consulted by other parts of the code diff --git a/src/cmd/go/internal/work/exec.go b/src/cmd/go/internal/work/exec.go -index 9724cd07d0..544df461a2 100644 +index 9724cd0..544df46 100644 --- a/src/cmd/go/internal/work/exec.go +++ b/src/cmd/go/internal/work/exec.go @@ -544,6 +544,23 @@ func (b *Builder) build(ctx context.Context, a *Action) (err error) { @@ -109,6 +109,3 @@ index 9724cd07d0..544df461a2 100644 if err := b.Shell(a).Mkdir(a.Objdir); err != nil { return err } --- -2.44.0 - diff --git a/meta/recipes-devtools/go/go/0007-exec.go-filter-out-build-specific-paths-from-linker-.patch b/meta/recipes-devtools/go/go/0007-exec.go-filter-out-build-specific-paths-from-linker-.patch index c5bf28f54a..2fdd52974f 100644 --- a/meta/recipes-devtools/go/go/0007-exec.go-filter-out-build-specific-paths-from-linker-.patch +++ b/meta/recipes-devtools/go/go/0007-exec.go-filter-out-build-specific-paths-from-linker-.patch @@ -1,4 +1,4 @@ -From 083b5c74b12a1abeb11dd7f58a1cb1593d0000c0 Mon Sep 17 00:00:00 2001 +From 1097a07b097043e15fe29a85326dbd196401244a Mon Sep 17 00:00:00 2001 From: Changqing Li Date: Tue, 27 Feb 2024 18:06:51 +0800 Subject: [PATCH] exec.go: filter out build-specific paths from linker flags @@ -9,15 +9,16 @@ Filter out options that have build-specific paths. Upstream-Status: Inappropriate [ Not perfect for upstream ] Signed-off-by: Changqing Li +Signed-off-by: Jose Quaresma --- src/cmd/go/internal/work/exec.go | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/src/cmd/go/internal/work/exec.go b/src/cmd/go/internal/work/exec.go -index cde867b..e3ce17d 100644 +index 544df46..c8f297c 100644 --- a/src/cmd/go/internal/work/exec.go +++ b/src/cmd/go/internal/work/exec.go -@@ -1358,6 +1358,29 @@ func (b *Builder) linkActionID(a *Action) cache.ActionID { +@@ -1401,6 +1401,29 @@ func (b *Builder) linkActionID(a *Action) cache.ActionID { return h.Sum() } @@ -47,7 +48,7 @@ index cde867b..e3ce17d 100644 // printLinkerConfig prints the linker config into the hash h, // as part of the computation of a linker-related action ID. func (b *Builder) printLinkerConfig(h io.Writer, p *load.Package) { -@@ -1368,7 +1391,7 @@ func (b *Builder) printLinkerConfig(h io.Writer, p *load.Package) { +@@ -1411,7 +1434,7 @@ func (b *Builder) printLinkerConfig(h io.Writer, p *load.Package) { case "gc": fmt.Fprintf(h, "link %s %q %s\n", b.toolID("link"), forcedLdflags, ldBuildmode) if p != nil { @@ -56,6 +57,3 @@ index cde867b..e3ce17d 100644 } // GOARM, GOMIPS, etc. --- -2.25.1 - diff --git a/meta/recipes-devtools/go/go/0008-src-cmd-dist-buildgo.go-do-not-hardcode-host-compile.patch b/meta/recipes-devtools/go/go/0008-src-cmd-dist-buildgo.go-do-not-hardcode-host-compile.patch index 0662f66af5..4c1f0ca145 100644 --- a/meta/recipes-devtools/go/go/0008-src-cmd-dist-buildgo.go-do-not-hardcode-host-compile.patch +++ b/meta/recipes-devtools/go/go/0008-src-cmd-dist-buildgo.go-do-not-hardcode-host-compile.patch @@ -1,8 +1,8 @@ -From e0999902687e2e394499f7153db8d62440c4dab0 Mon Sep 17 00:00:00 2001 +From e5af6155f2d6e0758d11d6c12d6f47ea8e65b141 Mon Sep 17 00:00:00 2001 From: Alexander Kanavin Date: Tue, 10 Nov 2020 16:33:27 +0000 -Subject: [PATCH 8/9] src/cmd/dist/buildgo.go: do not hardcode host compilers - into target binaries +Subject: [PATCH] src/cmd/dist/buildgo.go: do not hardcode host compilers into + target binaries These come from $CC/$CXX on the build host and are not useful on targets; additionally as they contain host specific paths, this helps reproducibility. @@ -16,7 +16,7 @@ Signed-off-by: Jose Quaresma 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/cmd/dist/buildgo.go b/src/cmd/dist/buildgo.go -index 884e9d729a..2f52edacfe 100644 +index 884e9d7..2f52eda 100644 --- a/src/cmd/dist/buildgo.go +++ b/src/cmd/dist/buildgo.go @@ -51,8 +51,8 @@ func mkzdefaultcc(dir, file string) { @@ -41,6 +41,3 @@ index 884e9d729a..2f52edacfe 100644 writefile(buf.String(), file, writeSkipSame) } --- -2.44.0 - diff --git a/meta/recipes-devtools/go/go/0009-go-Filter-build-paths-on-staticly-linked-arches.patch b/meta/recipes-devtools/go/go/0009-go-Filter-build-paths-on-staticly-linked-arches.patch index cc45496e9c..d939cb4716 100644 --- a/meta/recipes-devtools/go/go/0009-go-Filter-build-paths-on-staticly-linked-arches.patch +++ b/meta/recipes-devtools/go/go/0009-go-Filter-build-paths-on-staticly-linked-arches.patch @@ -1,7 +1,7 @@ -From 6c2438f187ca912c54a71b4ac65ab98999a019d2 Mon Sep 17 00:00:00 2001 +From 6bdd6405ce63c7aa4b35cd85833d03c7f1b9109a Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sat, 2 Jul 2022 23:08:13 +0100 -Subject: [PATCH 9/9] go: Filter build paths on staticly linked arches +Subject: [PATCH] go: Filter build paths on staticly linked arches Filter out build time paths from ldflags and other flags variables when they're embedded in the go binary so that builds are reproducible regardless of build @@ -17,7 +17,7 @@ Signed-off-by: Jose Quaresma 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/src/cmd/go/internal/load/pkg.go b/src/cmd/go/internal/load/pkg.go -index 1549800afb..f41fb2c4ef 100644 +index 1549800..f41fb2c 100644 --- a/src/cmd/go/internal/load/pkg.go +++ b/src/cmd/go/internal/load/pkg.go @@ -2277,6 +2277,17 @@ func appendBuildSetting(info *debug.BuildInfo, key, value string) { @@ -56,6 +56,3 @@ index 1549800afb..f41fb2c4ef 100644 } } appendSetting("GOARCH", cfg.BuildContext.GOARCH) --- -2.44.0 - diff --git a/meta/recipes-devtools/go/go_1.22.4.bb b/meta/recipes-devtools/go/go_1.22.5.bb similarity index 100% rename from meta/recipes-devtools/go/go_1.22.4.bb rename to meta/recipes-devtools/go/go_1.22.5.bb From patchwork Thu Jul 18 13:45:36 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 46605 X-Patchwork-Delegate: steve@sakoman.com 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 590E3C3DA6F for ; Thu, 18 Jul 2024 13:46:11 +0000 (UTC) Received: from mail-pl1-f182.google.com (mail-pl1-f182.google.com [209.85.214.182]) by mx.groups.io with SMTP id smtpd.web10.15391.1721310363796175670 for ; Thu, 18 Jul 2024 06:46:03 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=POUFUuua; spf=softfail (domain: sakoman.com, ip: 209.85.214.182, mailfrom: steve@sakoman.com) Received: by mail-pl1-f182.google.com with SMTP id d9443c01a7336-1fc692abba4so3898065ad.2 for ; Thu, 18 Jul 2024 06:46:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1721310363; x=1721915163; 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=k3GVLHSi/qM8G8bbKOfi4PKAoVViXPkFKnsVuuHOf3U=; b=POUFUuuab1uoWsqtGgURh4ojFTDkOZJJXNreBo0YgksEu7QiVIWmvsVLubIsom9Dlo 2rcXqZzNf9gIc6Y36K+O7hkzGd5u7ygRyNNM8rrEAXe67C6/Q4tJhCsk/1ysKEGmWXjV nIu+sXrCpkkF3TrhpRVMAKYoX12tJuRBuHq0nIbeXQJnaQ+egj2Iyp+bB2+XvXry7ur9 H3H5wE6VrKKfnz9XJg0RnXt8uIvQCW1RL55rwxFNmWyEK9LXFJqnaGBfIpWocFGYP8RE R0xstav2XVQgsvh3MOpvkVVm0bREIh5TfwUWuNqmB0Xek9UvCIX3mGJyf2rawapbybIY A4QQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721310363; x=1721915163; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=k3GVLHSi/qM8G8bbKOfi4PKAoVViXPkFKnsVuuHOf3U=; b=HMEmKPcp/vrSH+HA0OotTxadTppJ1mCYXlhIMvO/D6/1CkFw7K3EsKWC/mDKT35wmZ ofgxnSC7L3CXFKGRNBxpUepfhCkdI5QU8APfxIEU0V4vU1CBtPE6CuVEUSNaC/FfLJFm 8hHcfecdt+1UFQoQI98ePP8lqqxV9H34Mf94wZS7Fq37oXCszvkzu8LasNMXh6xkVUVa ehCWUHpNxsFEHHIEj1Zo+OaBCJBcZD+0QGiBRRQMU9msqIS8isr6JmG56YIWTkRh43Mc 5JI+6L/5fBAqJSzzbk+SBXpXaOcs8FM24eJGu2gBZVjuoFxdhmnlY/gfpn6zQUXteug7 6KVw== X-Gm-Message-State: AOJu0Yx6hkYwdJ92zNFItNttlvfiH91N23+mxtX3m+1KHMdZcW+E6Qe7 onv5lhCdYpFmbygNqwUTqSyKAwupN1dDDfgtcCfqq+ck4/H4IKUX8KIN17HR29VY0sy5UIpWLZY d X-Google-Smtp-Source: AGHT+IFsuYPPlCc4YmL4a1bAW/eb4AmK5nBEzk5GgulJ6xh9KngZhAma3eurNTxbLO7x3/BV/7iiJA== X-Received: by 2002:a17:902:ebc6:b0:1fb:9280:c96e with SMTP id d9443c01a7336-1fc4e6c007dmr42392835ad.62.1721310363075; Thu, 18 Jul 2024 06:46:03 -0700 (PDT) Received: from hexa.. ([98.142.47.158]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-1fc0bb6ffbdsm93366985ad.60.2024.07.18.06.46.02 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 18 Jul 2024 06:46:02 -0700 (PDT) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 07/12] binutils: stable 2.42 branch updates Date: Thu, 18 Jul 2024 06:45:36 -0700 Message-Id: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 18 Jul 2024 13:46:11 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/202220 From: Deepthi Hemraj Below commits on binutils-2.42 stable branch are updated. 29ae8b8ea71 x86-64: Skip -z mark-plt tests on MUSL 92cc764e58f hppa: Fix handling of relocations that apply to data c439c1e1f56 elf: Add glibc version dependency only if needed 68ae8e2a849 ld: pass -g for ld-elf tests a1e3cb45c67 aarch64: Enable +cssc for armv8.9-a Signed-off-by: Deepthi Hemraj Signed-off-by: Steve Sakoman --- meta/recipes-devtools/binutils/binutils-2.42.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta/recipes-devtools/binutils/binutils-2.42.inc b/meta/recipes-devtools/binutils/binutils-2.42.inc index c8f526b5c7..24efe495ec 100644 --- a/meta/recipes-devtools/binutils/binutils-2.42.inc +++ b/meta/recipes-devtools/binutils/binutils-2.42.inc @@ -20,7 +20,7 @@ UPSTREAM_CHECK_GITTAGREGEX = "binutils-(?P\d+_(\d_?)*)" CVE_STATUS[CVE-2023-25584] = "cpe-incorrect: Applies only for version 2.40 and earlier" -SRCREV ?= "cbec9028dd3fa9b49e0204f1a989cea67cae32c6" +SRCREV ?= "71ef12cbf140a637e4ea4e2239ee5daedc8640de" BINUTILS_GIT_URI ?= "git://sourceware.org/git/binutils-gdb.git;branch=${SRCBRANCH};protocol=https" SRC_URI = "\ ${BINUTILS_GIT_URI} \ From patchwork Thu Jul 18 13:45:37 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 46602 X-Patchwork-Delegate: steve@sakoman.com 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 596D6C41513 for ; Thu, 18 Jul 2024 13:46:11 +0000 (UTC) Received: from mail-pl1-f179.google.com (mail-pl1-f179.google.com [209.85.214.179]) by mx.groups.io with SMTP id smtpd.web11.15467.1721310365307170617 for ; Thu, 18 Jul 2024 06:46:05 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=iL6x4mmM; spf=softfail (domain: sakoman.com, ip: 209.85.214.179, mailfrom: steve@sakoman.com) Received: by mail-pl1-f179.google.com with SMTP id d9443c01a7336-1fb1c69e936so5727935ad.3 for ; Thu, 18 Jul 2024 06:46:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1721310364; x=1721915164; 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=cRHJ2Bk7mgrX8PrHcmFV/mfeSgwfKtFpSgMKqi7n0X0=; b=iL6x4mmMnjXtDqzvNCtbuuYtnupwvndTvBdvwltV32GY6j9FmGSssf2GWPwnbeATY9 +MbhIgP7FoYtsnZJxs++X6XNULRZZJbh2wPZWBvyHi0Je/ca+TGFLTpamedr961UcFEZ HSa27W6F0A5OCerzBwrt4XRkk8NeMuAo4xyV0lmCZRNzxVA35pNhXqn4yyKhc2DmFNIX SqMUNFQyqaHtdy7hAtmHcj5qgMOcKyvujMcEHk9AKah/WmbcY0XDuBw43vXRjI+ua8nz izLVK0r+ROyFQkfI84icQ3l9r7+VtpGsOdEzuxbAFdBiWgUOXu/E3Teaf0sqoo8WHXH7 8PYw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721310364; x=1721915164; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=cRHJ2Bk7mgrX8PrHcmFV/mfeSgwfKtFpSgMKqi7n0X0=; b=aBjo1HkCqrgBiaDSX7P8OLGHoFpaY/lBOcUeYLmPSOaYQw20JdlBmU6ATYmlLQfEAu Ao+XluHE7T9N2yRwbyDNlhcfRVl3jWWrGDB+7rgF4aIbuucjgss+I2FC1w+ALDnS/wSv yCAwa4r9FszACKLXch4T1uGuL85Uuvbh2sqiFK6ksmUFZcGS2uX2OOL/rxprvZ8NRyUz i6dzmTm0nZEPbBnPNaaO4F9EpE28vayU4Trukpo5gKEDf4StAc4A1uPUJGHJ3WTrPPX+ UVLWompCMwP0zo92NIFE8RFytc0yecGpPoheBzwppUBaXyr5w/b7k6C2m9L+2puIGapp iCSw== X-Gm-Message-State: AOJu0YyJ4NF5WRXXgJd5E+jf2e5dTqFURrZ4S77dWGEThRxiWZf5021B vQMgBkRbrdwKNsaBy8fdCwY3i3ouYXm0lUY/Byzv06VAe+Bdk24dp/I30it23UzrSayCHKmQWZl G X-Google-Smtp-Source: AGHT+IFwX8Yc9lgPGJp4mZlb3/a4aIXrW5Wsa4TIxCeTFH+cj7wDVTJaXnt4F/08I7OydN38NcPGnw== X-Received: by 2002:a17:902:e5cd:b0:1fc:3dad:25ed with SMTP id d9443c01a7336-1fc4e154fe1mr43832535ad.9.1721310364532; Thu, 18 Jul 2024 06:46:04 -0700 (PDT) Received: from hexa.. ([98.142.47.158]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-1fc0bb6ffbdsm93366985ad.60.2024.07.18.06.46.03 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 18 Jul 2024 06:46:04 -0700 (PDT) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 08/12] vulkan-samples: fix do_compile error when -Og enabled Date: Thu, 18 Jul 2024 06:45:37 -0700 Message-Id: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 18 Jul 2024 13:46:11 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/202221 From: Changqing Li When debug build is enabled(-Og is used), vulkan-samples do_compile failed with error: In function 'ZSTD_compressBlock_lazy_generic', inlined from 'ZSTD_compressBlock_greedy' at TOPDIR/tmp-glibc/work/core2-32-wrs-linux/vulkan-samples/git/git/third_party/ktx/lib/basisu/zstd/zstd.c:21914:12: TOPDIR/tmp-glibc/work/core2-32-wrs-linux/vulkan-samples/git/git/third_party/ktx/lib/basisu/zstd/zstd.c:21551:30: error: inlining failed in call to 'always_inline' 'ZSTD_HcFindBestMatch_selectMLS': function not considered for inlining | FORCE_INLINE_TEMPLATE size_t ZSTD_HcFindBestMatch_selectMLS ( | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ TOPDIR/tmp-glibc/work/core2-32-wrs-linux/vulkan-samples/git/git/third_party/ktx/lib/basisu/zstd/zstd.c:21736:32: note: called from here | size_t const ml2 = searchMax(ms, ip, iend, &offsetFound); Refer [1], always_inline is not suggested to use with indirect function call, replace always_inline with inline to fix the issue [1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107931 Signed-off-by: Changqing Li Signed-off-by: Richard Purdie (cherry picked from commit 246de52fe59de0612d1145357c5e904a51363c8c) Signed-off-by: Steve Sakoman --- ...ce-FORCE_INLINE_TEMPLATE-with-inline.patch | 52 +++++++++++++++++++ .../vulkan/vulkan-samples_git.bb | 1 + 2 files changed, 53 insertions(+) create mode 100644 meta/recipes-graphics/vulkan/vulkan-samples/0001-zstd.c-replace-FORCE_INLINE_TEMPLATE-with-inline.patch diff --git a/meta/recipes-graphics/vulkan/vulkan-samples/0001-zstd.c-replace-FORCE_INLINE_TEMPLATE-with-inline.patch b/meta/recipes-graphics/vulkan/vulkan-samples/0001-zstd.c-replace-FORCE_INLINE_TEMPLATE-with-inline.patch new file mode 100644 index 0000000000..22538d4119 --- /dev/null +++ b/meta/recipes-graphics/vulkan/vulkan-samples/0001-zstd.c-replace-FORCE_INLINE_TEMPLATE-with-inline.patch @@ -0,0 +1,52 @@ +From a7bfe82a311c713b12bb83b8488574ad5c784f89 Mon Sep 17 00:00:00 2001 +From: Changqing Li +Date: Tue, 9 Jul 2024 04:29:11 +0000 +Subject: [PATCH] zstd.c: replace FORCE_INLINE_TEMPLATE with inline + +Refer [1], always-inline is not suggested to be used if you have indirect ++calls. so replace FORCE_INLINE_TEMPLATE with inline to fix error: +In function 'ZSTD_compressBlock_lazy_generic', + inlined from 'ZSTD_compressBlock_greedy' at TOPDIR/tmp-glibc/work/core2-32-wrs-linux/vulkan-samples/git/git/third_party/ktx/lib/basisu/zstd/zstd.c:21914:12: +TOPDIR/tmp-glibc/work/core2-32-wrs-linux/vulkan-samples/git/git/third_party/ktx/lib/basisu/zstd/zstd.c:21551:30: error: inlining failed in call to 'always_inline' 'ZSTD_HcFindBestMatch_selectMLS': function not considered for inlining + | FORCE_INLINE_TEMPLATE size_t ZSTD_HcFindBestMatch_selectMLS ( + | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +TOPDIR/tmp-glibc/work/core2-32-wrs-linux/vulkan-samples/git/git/third_party/ktx/lib/basisu/zstd/zstd.c:21736:32: note: called from here +| size_t const ml2 = searchMax(ms, ip, iend, &offsetFound); + +Upstream-Status: Inappropriate [ Latest upstream ktx don't have this part code ] + +Has report this issue to upstream Vulkan-Samples, refer [2] + +[1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107931 +[2] https://github.com/KhronosGroup/Vulkan-Samples/issues/1089 + +Signed-off-by: Changqing Li +--- + lib/basisu/zstd/zstd.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/lib/basisu/zstd/zstd.c b/lib/basisu/zstd/zstd.c +index eaf13738..423f149e 100644 +--- a/lib/basisu/zstd/zstd.c ++++ b/lib/basisu/zstd/zstd.c +@@ -21548,7 +21548,7 @@ size_t ZSTD_HcFindBestMatch_generic ( + } + + +-FORCE_INLINE_TEMPLATE size_t ZSTD_HcFindBestMatch_selectMLS ( ++static inline size_t ZSTD_HcFindBestMatch_selectMLS ( + ZSTD_matchState_t* ms, + const BYTE* ip, const BYTE* const iLimit, + size_t* offsetPtr) +@@ -21596,7 +21596,7 @@ static size_t ZSTD_HcFindBestMatch_dedicatedDictSearch_selectMLS ( + } + + +-FORCE_INLINE_TEMPLATE size_t ZSTD_HcFindBestMatch_extDict_selectMLS ( ++static inline size_t ZSTD_HcFindBestMatch_extDict_selectMLS ( + ZSTD_matchState_t* ms, + const BYTE* ip, const BYTE* const iLimit, + size_t* offsetPtr) +-- +2.44.0 + diff --git a/meta/recipes-graphics/vulkan/vulkan-samples_git.bb b/meta/recipes-graphics/vulkan/vulkan-samples_git.bb index d60c0f3190..4e688e44a7 100644 --- a/meta/recipes-graphics/vulkan/vulkan-samples_git.bb +++ b/meta/recipes-graphics/vulkan/vulkan-samples_git.bb @@ -10,6 +10,7 @@ SRC_URI = "gitsm://github.com/KhronosGroup/Vulkan-Samples.git;branch=main;protoc file://0001-Do-not-use-LFS64-functions-on-linux-musl.patch;patchdir=third_party/spdlog \ file://0001-Deprecate-u8string_view.patch;patchdir=third_party/spdlog \ file://32bit.patch \ + file://0001-zstd.c-replace-FORCE_INLINE_TEMPLATE-with-inline.patch;patchdir=third_party/ktx \ " UPSTREAM_CHECK_COMMITS = "1" From patchwork Thu Jul 18 13:45:38 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 46604 X-Patchwork-Delegate: steve@sakoman.com 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 88087C3DA63 for ; Thu, 18 Jul 2024 13:46:11 +0000 (UTC) Received: from mail-pl1-f181.google.com (mail-pl1-f181.google.com [209.85.214.181]) by mx.groups.io with SMTP id smtpd.web10.15394.1721310367031953368 for ; Thu, 18 Jul 2024 06:46:07 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=XTSt7Zax; spf=softfail (domain: sakoman.com, ip: 209.85.214.181, mailfrom: steve@sakoman.com) Received: by mail-pl1-f181.google.com with SMTP id d9443c01a7336-1fc6a017abdso3460695ad.0 for ; Thu, 18 Jul 2024 06:46:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1721310366; x=1721915166; 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=vZ+QGVvvRo+JwSwbKTQJkN4+hTn3DrZHrsUS8m1uI9g=; b=XTSt7ZaxIRtVek7AcT6rmszsX8k4j1KG2O/sn30vQ8IPjxt9NdnSNdHZ/Woi3H57fx W+IQFBqSGtp2fVb966+6zx5bN2iBzmy4E52Cyekewa24Zsx7SXnkWBc/necsWnSoGnQF +yrYcHHuNmcdxtXSafc2+dxqpS71GRs6sKM5ySujvqmXXS15eQG7xKcHj9z3v1wlt3T6 tqhsD2jIf3XdVpCCETRIr4qPah/S98sFpwhp64UodoZyRlC+P5EmQFdV0ayRvs2Pk8Hp pnVznnkKwZqIqRCiiYk1mXVUHiIumgkMbh++QgQp4on9yoHduCN7P6NDnEM2nhbEzFWs 6gxA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721310366; x=1721915166; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=vZ+QGVvvRo+JwSwbKTQJkN4+hTn3DrZHrsUS8m1uI9g=; b=gAhXITx9ZnlXkXbT5kc2mgDoL3ldck59yQHL6ofrOpWb2vL3r+TLfLdLJ4/gZP3RPX rMa4mZdSaQDlKL9M5aCdjH52TI0pg/Qwq8l503IJtrgDfQA7rESgiWI7y870sDNIJRzb ShCwdNV8rebRUFtf+Z+eS49VDrrO1uW9zrRyzhYPpBflO+it0ZLO8w9EaKQQ3aB+WaXV Qb1QwG429LFtveAcLX5p81zHpKc+7nCyOwLVc1ARd6veFEsSX36vEQflrR7Dh8tPCx+M nwT1JfYxbFouVAwXVB3KnNI0d271cFlEex3VS5fITE7QEpKXchqsgJ8tc/GbpXbR+p73 rbIw== X-Gm-Message-State: AOJu0Yzx+oR9OeA0wg2Ja2r3VXIjKhalnM0fIgDTMgpJKMkBPZ7ZR2N9 bUx9CQKLgkUlmwfwfRg0VydtiUsIDL7xxVXa1xbJVROZSez49bUEcIrz6DECV1Xyt8k5J00uPTb D X-Google-Smtp-Source: AGHT+IFMqNVnNnESONr7OGhr+nqh/CX1bVoFFdoX8M7TN1CO722RcolOEhTTkzUdfn87k0IzkBxHtg== X-Received: by 2002:a17:902:e548:b0:1fc:4763:445c with SMTP id d9443c01a7336-1fc4e14fe3amr40269435ad.32.1721310366311; Thu, 18 Jul 2024 06:46:06 -0700 (PDT) Received: from hexa.. ([98.142.47.158]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-1fc0bb6ffbdsm93366985ad.60.2024.07.18.06.46.05 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 18 Jul 2024 06:46:06 -0700 (PDT) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 09/12] multilib.conf: remove appending to PKG_CONFIG_PATH Date: Thu, 18 Jul 2024 06:45:38 -0700 Message-Id: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 18 Jul 2024 13:46:11 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/202222 From: Changqing Li * Since commit [a23c482cab allarch: only enable allarch when multilib is not used], allarch recipes will also be installed into ${MLPREFIX}recipe-sysroot, so this appending is not needed. * This appending also causes some QA errors. Eg: for lib32-php, the recipe will use 's@${RECIPE_SYSROOT}@@g' to remove host specific path, this appending makes not all the host specific path are matched. Signed-off-by: Changqing Li Signed-off-by: Richard Purdie (cherry picked from commit e6e6076f1956c711814c14d76194794d950e45f8) Signed-off-by: Steve Sakoman --- meta/conf/multilib.conf | 9 --------- 1 file changed, 9 deletions(-) diff --git a/meta/conf/multilib.conf b/meta/conf/multilib.conf index ef3605a73d..09546315b8 100644 --- a/meta/conf/multilib.conf +++ b/meta/conf/multilib.conf @@ -22,15 +22,6 @@ MULTILIB_GLOBAL_VARIANTS ?= "lib32 lib64 libx32" OPKG_ARGS:append = " --force-maintainer --force-overwrite" -# When multilib is enabled, allarch recipes will be installed into the MACHINE -# sysroot, not MLPREFIXMACHINE. This means that anything using pkg-config to -# find an allarch pkgconfig file will fail as the PKG_CONFIG_PATH only looks -# inside the multilib sysroot. Fix this by explicitly adding the MACHINE's -# architecture-independent pkgconfig location to PKG_CONFIG_PATH. -PKG_CONFIG_PATH .= ":${WORKDIR}/recipe-sysroot/${datadir}/pkgconfig" -PKG_CONFIG_PATH[vardepsexclude] = "datadir WORKDIR" -PKG_CONFIG_PATH[vardepvalueexclude] = ":${WORKDIR}/recipe-sysroot/${datadir}/pkgconfig" - # These recipes don't need multilib variants, the ${BPN} PROVDES/RPROVDES # ${MLPREFIX}${BPN} NON_MULTILIB_RECIPES = "grub grub-efi make-mod-scripts ovmf u-boot" From patchwork Thu Jul 18 13:45:39 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 46607 X-Patchwork-Delegate: steve@sakoman.com 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 5CAD5C41513 for ; Thu, 18 Jul 2024 13:46:21 +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.web11.15469.1721310372611343028 for ; Thu, 18 Jul 2024 06:46:12 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=ix0jo9C1; 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-1fc569440e1so8070545ad.3 for ; Thu, 18 Jul 2024 06:46:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1721310372; x=1721915172; 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=taojYMmopKFbFtoZnXIOurpQxIdLa7+0KAi0VAvC9eU=; b=ix0jo9C1TSU2ixP3xZ8XylOzPncBtTolcYrNYjWBYluNMB98hb6LykUTBtX52kl16y iE9MolaQRh3Hn6zex8NGG3o5wAxaZLYk7DLK3jxJwo6y6puZIt6ernRCfijj2xCChQk9 SqG33GJwQQ0YozhstCyaI/8jgjgPlWcL0uftxulxWoB8gMQ+NZ+LnXLjRmn2QddC8+4H Xd0vMZBYT13/vCZ8TbdLjtrXprqf5JQq0DJ7yiVpa3zvZsVA2D2OadpfrUmfPziK0LKa ZdMvFvquCPymwwijZq4HWtlS/GgMvH35qFjhGX8Ry3nBg4f6OP/OrNXa3+jp/B9w3P+U allg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721310372; x=1721915172; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=taojYMmopKFbFtoZnXIOurpQxIdLa7+0KAi0VAvC9eU=; b=icrfRXlR0znuHSexRmWHcBX7/1i9eaT/IJSq0M7SQ49z/7MyS/mRuCD/hLyqnbooBT c/AH+H9RRQAptacv7rOJo/e2x6ht+z5FWvuyiKPc7REVskbxt7DglVmd3YPqbxO0ioSd uZkvUoYQnxSCSj6/aMD48Eu3/LkQn1yCgj5jDMkI9e38QxOt9yMaW4T7JBQgc/ka7RlY Kfd/pp7GZDY+/ROx1v1pBy1z87WYNH370UW5bS8AoQy2qqhGTG+i9FgdrzIY91IHuWH5 6GBLw84gxAaN/AdbLvk3nzwJLBWDPq5M8diDIoMT0FCzWdsWtoR5JqChi5RyUCz8RbRz F6Tw== X-Gm-Message-State: AOJu0YytWIiWPYlP8ArrMve9aIZ1pbq6hHVSWgZH5KZZDTZV3B9/hMVy 69vYwnA2YbQi2Wm/a08WtdClQSKyl6KTJ9EeNH9SOt26Dm317SyhLHwZ1XEnrkT+jCZ8AXk8M/N p X-Google-Smtp-Source: AGHT+IEGYvO9RDkLDZGryp4+69F/bW3KDJe5D+v6Y+PROWXajCt9JkJw6PKUT4i3abCb5gBHAJ5vYg== X-Received: by 2002:a17:902:e846:b0:1fb:5f82:6a5d with SMTP id d9443c01a7336-1fc4e55ccfbmr47686995ad.21.1721310371840; Thu, 18 Jul 2024 06:46:11 -0700 (PDT) Received: from hexa.. ([98.142.47.158]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-1fc0bb6ffbdsm93366985ad.60.2024.07.18.06.46.11 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 18 Jul 2024 06:46:11 -0700 (PDT) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 10/12] gettext: fix a parallel build issue Date: Thu, 18 Jul 2024 06:45:39 -0700 Message-Id: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 18 Jul 2024 13:46:21 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/202223 From: Changqing Li Occasionally, gettext will build failed with error: In file included from ../../../gettext-0.22.5/gettext-runtime/intl/gettextP.h:71, from ../../../gettext-0.22.5/gettext-runtime/intl/log.c:24: ./libgnuintl.h:98:1: error: unterminated comment 98 | /* The user can define _INTL_RE | ^ ./libgnuintl.h:17: error: unterminated #ifndef 17 | #ifndef _LIBINTL_H In file included from ../../../gettext-0.22.5/gettext-runtime/intl/gettextP.h:71, from ../../../gettext-0.22.5/gettext-runtime/intl/langprefs.c:25: ./libgnuintl.h:98:1: error: unterminated comment 98 | /* The user can define _INTL_RE | ^ ./libgnuintl.h:17: error: unterminated #ifndef 17 | #ifndef _LIBINTL_H It is a parallel build issue caused by missing dependencies, backport patch to fix it. Signed-off-by: Changqing Li Signed-off-by: Alexandre Belloni Signed-off-by: Richard Purdie (cherry picked from commit e18fc96f9d4c0a0525c21371d3f36e8dfe008b35) Signed-off-by: Steve Sakoman --- ...1-intl-Fix-build-failure-with-make-j.patch | 35 +++++++++++++++++++ meta/recipes-core/gettext/gettext_0.22.5.bb | 1 + 2 files changed, 36 insertions(+) create mode 100644 meta/recipes-core/gettext/gettext/0001-intl-Fix-build-failure-with-make-j.patch diff --git a/meta/recipes-core/gettext/gettext/0001-intl-Fix-build-failure-with-make-j.patch b/meta/recipes-core/gettext/gettext/0001-intl-Fix-build-failure-with-make-j.patch new file mode 100644 index 0000000000..144259dd3f --- /dev/null +++ b/meta/recipes-core/gettext/gettext/0001-intl-Fix-build-failure-with-make-j.patch @@ -0,0 +1,35 @@ +From 97a6a63ad61949663283f5fad68c9d5fb9be1f15 Mon Sep 17 00:00:00 2001 +From: Bruno Haible +Date: Tue, 12 Sep 2023 11:33:41 +0200 +Subject: [PATCH] intl: Fix build failure with "make -j". + +Reported by Christian Weisgerber at +. + +* gettext-runtime/intl/Makefile.am (langprefs.lo, log.lo): Depend on gettextP.h +and its subordinate includes. + +Upstream-Status: Backport [https://git.savannah.gnu.org/gitweb/?p=gettext.git;a=commit;h=97a6a63ad61949663283f5fad68c9d5fb9be1f15] +Signed-off-by: Changqing Li +--- + gettext-runtime/intl/Makefile.am | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/gettext-runtime/intl/Makefile.am b/gettext-runtime/intl/Makefile.am +index da7abb758..9e56978bc 100644 +--- a/gettext-runtime/intl/Makefile.am ++++ b/gettext-runtime/intl/Makefile.am +@@ -387,8 +387,8 @@ dngettext.lo: ../config.h $(srcdir)/gettextP.h libgnuintl.h $(srcdir)/gmo + ngettext.lo: ../config.h $(srcdir)/gettextP.h libgnuintl.h $(srcdir)/gmo.h $(srcdir)/loadinfo.h + plural.lo: ../config.h $(srcdir)/plural-exp.h $(PLURAL_DEPS) + plural-exp.lo: ../config.h $(srcdir)/plural-exp.h +-langprefs.lo: ../config.h +-log.lo: ../config.h ++langprefs.lo: ../config.h $(srcdir)/gettextP.h libgnuintl.h $(srcdir)/gmo.h $(srcdir)/loadinfo.h ++log.lo: ../config.h $(srcdir)/gettextP.h libgnuintl.h $(srcdir)/gmo.h $(srcdir)/loadinfo.h + printf.lo: ../config.h + setlocale.lo: ../config.h $(srcdir)/gettextP.h libgnuintl.h $(srcdir)/gmo.h $(srcdir)/loadinfo.h + version.lo: ../config.h libgnuintl.h +-- +2.25.1 + diff --git a/meta/recipes-core/gettext/gettext_0.22.5.bb b/meta/recipes-core/gettext/gettext_0.22.5.bb index 1a66d37916..7eeb1a86fd 100644 --- a/meta/recipes-core/gettext/gettext_0.22.5.bb +++ b/meta/recipes-core/gettext/gettext_0.22.5.bb @@ -28,6 +28,7 @@ SRC_URI += " \ file://serial-tests-config.patch \ file://0001-tests-autopoint-3-unset-MAKEFLAGS.patch \ file://0001-init-env.in-do-not-add-C-CXX-parameters.patch \ + file://0001-intl-Fix-build-failure-with-make-j.patch \ " inherit autotools texinfo pkgconfig ptest From patchwork Thu Jul 18 13:45:40 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 46606 X-Patchwork-Delegate: steve@sakoman.com 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 5CAA8C3DA49 for ; Thu, 18 Jul 2024 13:46:21 +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.web10.15396.1721310374302283923 for ; Thu, 18 Jul 2024 06:46:14 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=PrW9qFCV; 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-1fc692abba4so3900195ad.2 for ; Thu, 18 Jul 2024 06:46:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1721310373; x=1721915173; 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=CPkiMmex4JLoFM6IJA/3YBAjfsAMtq94TfBQ8SRhy8U=; b=PrW9qFCVnkzUvusSBrE8bGOfYVoS/AmC6qlB4z7BukEmHCXRIAOXtIYcEP7LwccjxP PaAMYFnOeFE37q0SRgygKOyO5oJ5rPRrS8aPjQz72tB/kwLeUnnukSLqeNl49UNYckpG wnZ37U7XFucE0R2Zpx2W8ZkfQIFOBU+VpLF2lcP+nt7wbrg15ly8CgOSWeq89A0mhc0T 8012eFhckE0oqFYy44gaDIvORxZDveI3CdrF47EhK2apZX5Bh8jpWF1SoEpacZgZPMKG dXN7dVBXhD6GbL3JqKWYZRzNA74gV2UMNiZ8Us97K0Umj9oSF+E1mrvdygnlEMPhJMo2 4C0g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721310373; x=1721915173; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=CPkiMmex4JLoFM6IJA/3YBAjfsAMtq94TfBQ8SRhy8U=; b=U3gh+MB78tB1tOSEJ0e+WduMw7f8Fkyec98kcdZgbxlr7KTY4YJg8KJuULWPLlRizB wV0qhv+DHHCJzLcRPheCaS8noEJ/rD2xVMMoHeFpn2kpmUMvtZONUqonignqpCm7nc7S 4UYKJhqpiw220yIbFoh7QJgOL8lR3IAfnvaj4SuzTpY9qVtUPKIN3A8+yWwvuaY+Le6G 1Rj3eUtnDYa0P6jg8wZ3R5X6fZ7jEUYpO8mydxzo4wa9wRt5C+hYH2ZYAMJDFcrEcZOG H4xwiWreLv7XykcmOQ9j5UT/qqwnP+5pqGeNWVQSI4jajeiX8dxCWM7mqqxTqYS5CZTA 9zIA== X-Gm-Message-State: AOJu0YzzSjzUqltDASRtsoh3GGa8JpC7Z1J53nM78XVMIoKODtvSHl45 McP8b7COElofvUkV5h/rr6j549fgM3tKx0dWpA5tmVEpNvKnO/P3V0+/dHxyu4aLcWCwyNM8a2m 0 X-Google-Smtp-Source: AGHT+IGqIxfCczcJbNEUoX9G5pXstsLYdjPgQGCHxoWIhLqL51N2QDkUhy6tuWs964mayyhoXm8gNQ== X-Received: by 2002:a17:902:d506:b0:1fb:5c3d:b8ea with SMTP id d9443c01a7336-1fc4e135ed7mr42510255ad.13.1721310373517; Thu, 18 Jul 2024 06:46:13 -0700 (PDT) Received: from hexa.. ([98.142.47.158]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-1fc0bb6ffbdsm93366985ad.60.2024.07.18.06.46.12 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 18 Jul 2024 06:46:13 -0700 (PDT) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 11/12] Revert "apt: runtime error: filename too long (tmpdir length)" Date: Thu, 18 Jul 2024 06:45:40 -0700 Message-Id: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 18 Jul 2024 13:46:21 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/202224 This reverts commit dafdf9bb9e9d944b9f455c2be8cf698496200717. Patch rejected upstream Signed-off-by: Steve Sakoman --- ...he-filename-can-t-be-longer-than-255.patch | 40 ------------------- meta/recipes-devtools/apt/apt_2.6.1.bb | 1 - 2 files changed, 41 deletions(-) delete mode 100644 meta/recipes-devtools/apt/apt/0001-strutl.cc-the-filename-can-t-be-longer-than-255.patch diff --git a/meta/recipes-devtools/apt/apt/0001-strutl.cc-the-filename-can-t-be-longer-than-255.patch b/meta/recipes-devtools/apt/apt/0001-strutl.cc-the-filename-can-t-be-longer-than-255.patch deleted file mode 100644 index 311c3664ad..0000000000 --- a/meta/recipes-devtools/apt/apt/0001-strutl.cc-the-filename-can-t-be-longer-than-255.patch +++ /dev/null @@ -1,40 +0,0 @@ -From 918295aa1320718d342116f76c98d2289d377800 Mon Sep 17 00:00:00 2001 -From: Changqing Li -Date: Tue, 18 Jun 2024 10:32:55 +0800 -Subject: [PATCH] strutl.cc: the filename can't be longer than 255 - -The URItoFileName translates the path into the filename, but the -filename can't be longer than 255 according to -/usr/include/linux/limits.h. - -Truncate it when it is longer than 240 (leave some spaces for -".Packages" and "._Release" suffix) - -Upstream-Status: Submitted [https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1073591] -Signed-off-by: Robert Yang -Signed-off-by: Changqing Li ---- - apt-pkg/contrib/strutl.cc | 7 ++++++- - 1 file changed, 6 insertions(+), 1 deletion(-) - -diff --git a/apt-pkg/contrib/strutl.cc b/apt-pkg/contrib/strutl.cc -index 67100f1..5076b35 100644 ---- a/apt-pkg/contrib/strutl.cc -+++ b/apt-pkg/contrib/strutl.cc -@@ -565,7 +565,12 @@ string URItoFileName(const string &URI) - // "\x00-\x20{}|\\\\^\\[\\]<>\"\x7F-\xFF"; - string NewURI = QuoteString(U,"\\|{}[]<>\"^~_=!@#$%^&*"); - replace(NewURI.begin(),NewURI.end(),'/','_'); -- return NewURI; -+ -+ // Truncate from the head when it is longer than 240 -+ if(NewURI.length() > 240) -+ return NewURI.substr(NewURI.length() - 240, NewURI.length() - 1); -+ else -+ return NewURI; - } - /*}}}*/ - // Base64Encode - Base64 Encoding routine for short strings /*{{{*/ --- -2.25.1 - diff --git a/meta/recipes-devtools/apt/apt_2.6.1.bb b/meta/recipes-devtools/apt/apt_2.6.1.bb index 1eec7fe7a6..e688d30cae 100644 --- a/meta/recipes-devtools/apt/apt_2.6.1.bb +++ b/meta/recipes-devtools/apt/apt_2.6.1.bb @@ -14,7 +14,6 @@ SRC_URI = "${DEBIAN_MIRROR}/main/a/apt/${BPN}_${PV}.tar.xz \ file://0001-Hide-fstatat64-and-prlimit64-defines-on-musl.patch \ file://0001-aptwebserver.cc-Include-array.patch \ file://0001-Remove-using-std-binary_function.patch \ - file://0001-strutl.cc-the-filename-can-t-be-longer-than-255.patch \ " SRC_URI:append:class-native = " \ From patchwork Thu Jul 18 13:45:41 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Steve Sakoman X-Patchwork-Id: 46608 X-Patchwork-Delegate: steve@sakoman.com 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 72E62C3DA6F for ; Thu, 18 Jul 2024 13:46:21 +0000 (UTC) Received: from mail-pl1-f181.google.com (mail-pl1-f181.google.com [209.85.214.181]) by mx.groups.io with SMTP id smtpd.web10.15399.1721310375701806095 for ; Thu, 18 Jul 2024 06:46:15 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@sakoman-com.20230601.gappssmtp.com header.s=20230601 header.b=LrY7AY/P; spf=softfail (domain: sakoman.com, ip: 209.85.214.181, mailfrom: steve@sakoman.com) Received: by mail-pl1-f181.google.com with SMTP id d9443c01a7336-1fc49c0aaffso8185615ad.3 for ; Thu, 18 Jul 2024 06:46:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakoman-com.20230601.gappssmtp.com; s=20230601; t=1721310375; x=1721915175; 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=z+l69buO2Wot0B/nRIlGbsK1ZN0Hnnt178uKQlw7V1k=; b=LrY7AY/PxpgYfr/lqSNp4UoBQGHVzpr+bUWofi92rQpP+V7+yOQZIU7p3kpkEoJ9Vm kIDTAIS5E9ZTWFvtoaL/noDcYDXuqDV2mEyKqPFXbiR2aejaRD6efg1QE00KxfCoADnD 6YyKfpLJfQj/5Wwtrgrc82APoYExRji6Zib5o+1tcAwAxMCCJ+7DQgLCRTMQ+gxrDmXe 312MXZ0nLKWNWOxo4m9R6GeRdYx38GI5lm0JtCg8IqZwLK33Mb0ZSLI9cLMawdCPh2dW UsH9cVEGVJVFk/2MSeIgLTdhIeozq3vkWJJos3Pvl/Qyz4v2QoR+2bC7LJf4QDONgoiI Vd5Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721310375; x=1721915175; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=z+l69buO2Wot0B/nRIlGbsK1ZN0Hnnt178uKQlw7V1k=; b=YT33xfdJzymL9pIOSEo6lIVsxa9dodYnLItPBCjrCvIG3XzUriqRcj5xHWJUW5qFp/ 221Tdm36rt6akAvTE1A3YVauhUatbhwyip7H5D0Hv0TQ7dQM+mi4xqRTUtFnh+e0wqTV ZqF9qo+2WZ8o/zXJrU6E1wCT/MVzNmmLP+0oxt3e3Xz3pXgEQcgHrAWIOMgD4luixxUm 2AQl64tNvbkws6PL8e5sV/A+VFrja74wMzDWiLRQXy6qWT3a++IFuWXrMr0x1IAyK8CN zgJtrpPxeSrhYpP9NuuzPskGx4Fzw761VSTvedALiZUqsFLbvljfd+5b1zJFUbBPFb76 QBmw== X-Gm-Message-State: AOJu0Yz34U+WFXoTm2faq5OdsAElLp6Jj/1vGI0QIjSKtJowyDt9HdID kKAE4r0/l4ROs5QVR+hEqTHlGaGvACZmgyN+G2OUhxtgtB67XIaA8N6iPIqIEkjH+8mkeTQ6Nem e X-Google-Smtp-Source: AGHT+IEv7dLqyZkozyKCg06kHhRMuO+EkS7W0n6dIAuJdkTCL6ZVFJWQmMSkxBCCX698/4SsH2P3/A== X-Received: by 2002:a17:903:22cf:b0:1fb:438a:5e4b with SMTP id d9443c01a7336-1fc4e56242cmr43643105ad.41.1721310374924; Thu, 18 Jul 2024 06:46:14 -0700 (PDT) Received: from hexa.. ([98.142.47.158]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-1fc0bb6ffbdsm93366985ad.60.2024.07.18.06.46.14 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 18 Jul 2024 06:46:14 -0700 (PDT) From: Steve Sakoman To: openembedded-core@lists.openembedded.org Subject: [OE-core][scarthgap 12/12] pixman: fixing inline failure with -Og Date: Thu, 18 Jul 2024 06:45:41 -0700 Message-Id: <6cd503c5e84bf8090b840c69c7569ae1a46528d0.1721310237.git.steve@sakoman.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 18 Jul 2024 13:46:21 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/202225 From: Changqing Li When debug build is enabled(-Og is used), pixman-native do_compile failed with error: In function ‘combine_inner’, inlined from ‘combine_soft_light_ca_float’ at ../pixman-0.42.2/pixman/pixman-combine-float.c:655:1: ../pixman-0.42.2/pixman/pixman-combine-float.c:370:5: error: inlining failed in call to ‘always_inline’ ‘combine_soft_light_c’: function not considered for inlining 370 | combine_ ## name ## _c (float sa, float s, float da, float d) Refer [1], always_inline is not suggested to use with indirect function call, replace always_inline with __inline__ to fix the issue [1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107931 Signed-off-by: Changqing Li Signed-off-by: Steve Sakoman --- ...loat.c-fix-inlining-failed-in-call-t.patch | 56 +++++++++++++++++++ .../xorg-lib/pixman_0.42.2.bb | 1 + 2 files changed, 57 insertions(+) create mode 100644 meta/recipes-graphics/xorg-lib/pixman/0001-pixman-combine-float.c-fix-inlining-failed-in-call-t.patch diff --git a/meta/recipes-graphics/xorg-lib/pixman/0001-pixman-combine-float.c-fix-inlining-failed-in-call-t.patch b/meta/recipes-graphics/xorg-lib/pixman/0001-pixman-combine-float.c-fix-inlining-failed-in-call-t.patch new file mode 100644 index 0000000000..5c79754e50 --- /dev/null +++ b/meta/recipes-graphics/xorg-lib/pixman/0001-pixman-combine-float.c-fix-inlining-failed-in-call-t.patch @@ -0,0 +1,56 @@ +From 1e32984ccd58da1a66ca918d170a6b1829ef9df2 Mon Sep 17 00:00:00 2001 +From: Changqing Li +Date: Tue, 16 Jul 2024 15:31:16 +0800 +Subject: [PATCH] pixman-combine-float.c: fix inlining failed in call to + always_inline +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Refer [1], always-inline is not suggested to be used if you have indirect +calls. so replace force_inline with inline to fix error: +In function ‘combine_inner’, + inlined from ‘combine_soft_light_ca_float’ at ../pixman/pixman-combine-float.c:655:511: +../pixman/pixman-combine-float.c:655:211: error: inlining failed in call to ‘always_inline’ ‘combine_soft_light_c’: function not considered for inlining + +[1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115679 + +Upstream-Status: Submitted [https://www.mail-archive.com/pixman@lists.freedesktop.org/msg04812.html] + +Signed-off-by: Changqing Li +--- + pixman/pixman-combine-float.c | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +diff --git a/pixman/pixman-combine-float.c b/pixman/pixman-combine-float.c +index f5145bc..f65eb5f 100644 +--- a/pixman/pixman-combine-float.c ++++ b/pixman/pixman-combine-float.c +@@ -261,7 +261,7 @@ get_factor (combine_factor_t factor, float sa, float da) + } + + #define MAKE_PD_COMBINERS(name, a, b) \ +- static float force_inline \ ++ static float inline \ + pd_combine_ ## name (float sa, float s, float da, float d) \ + { \ + const float fa = get_factor (a, sa, da); \ +@@ -360,13 +360,13 @@ MAKE_PD_COMBINERS (conjoint_xor, ONE_MINUS_DA_OVER_SA, ONE_MINUS_SA_OVER_DA) + */ + + #define MAKE_SEPARABLE_PDF_COMBINERS(name) \ +- static force_inline float \ ++ static inline float \ + combine_ ## name ## _a (float sa, float s, float da, float d) \ + { \ + return da + sa - da * sa; \ + } \ + \ +- static force_inline float \ ++ static inline float \ + combine_ ## name ## _c (float sa, float s, float da, float d) \ + { \ + float f = (1 - sa) * d + (1 - da) * s; \ +-- +2.25.1 + diff --git a/meta/recipes-graphics/xorg-lib/pixman_0.42.2.bb b/meta/recipes-graphics/xorg-lib/pixman_0.42.2.bb index 23ae0cbb27..3c55c1705a 100644 --- a/meta/recipes-graphics/xorg-lib/pixman_0.42.2.bb +++ b/meta/recipes-graphics/xorg-lib/pixman_0.42.2.bb @@ -9,6 +9,7 @@ DEPENDS = "zlib" SRC_URI = "https://www.cairographics.org/releases/${BP}.tar.gz \ file://0001-ARM-qemu-related-workarounds-in-cpu-features-detecti.patch \ + file://0001-pixman-combine-float.c-fix-inlining-failed-in-call-t.patch \ " SRC_URI[sha256sum] = "ea1480efada2fd948bc75366f7c349e1c96d3297d09a3fe62626e38e234a625e"