Openembedded Devel Discussions
 help / color / mirror / Atom feed
From: Martin Jansa <martin.jansa@gmail.com>
To: openembedded-devel@lists.openembedded.org
Cc: Khem Raj <raj.khem@gmail.com>,
	Armin Kuster <akuster808@gmail.com>,
	Martin Jansa <Martin.Jansa@gmail.com>
Subject: [meta-oe][dunfell][PATCH] nodejs: Fix build with gcc13
Date: Sun, 23 Jul 2023 18:05:53 +0200	[thread overview]
Message-ID: <20230723160553.2826040-1-Martin.Jansa@gmail.com> (raw)

From: Khem Raj <raj.khem@gmail.com>

* MJ: remove AUTHORS modification from the original patch from
  nodejs-16, so that the same patch does apply for both 14 and 12
  versions used in dunfell

* MJ: gcc-13 isn't used for target builds in dunfell, but can be used
  on host, so this is useful backport for nodejs-native

* MJ: this fixes default nodejs-native-12, nodejs-native-14 with negative
  D_P might need additional fix on top

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
---
 .../nodejs/nodejs/gcc13.patch                 | 63 +++++++++++++++++++
 .../nodejs/nodejs_12.22.12.bb                 |  1 +
 .../recipes-devtools/nodejs/nodejs_14.18.1.bb |  1 +
 3 files changed, 65 insertions(+)
 create mode 100644 meta-oe/recipes-devtools/nodejs/nodejs/gcc13.patch

diff --git a/meta-oe/recipes-devtools/nodejs/nodejs/gcc13.patch b/meta-oe/recipes-devtools/nodejs/nodejs/gcc13.patch
new file mode 100644
index 0000000000..9a448a0ba2
--- /dev/null
+++ b/meta-oe/recipes-devtools/nodejs/nodejs/gcc13.patch
@@ -0,0 +1,63 @@
+From 576aed71db7b40c90b44c623580629792a606928 Mon Sep 17 00:00:00 2001
+From: Jiawen Geng <technicalcute@gmail.com>
+Date: Fri, 14 Oct 2022 09:54:33 +0800
+Subject: [PATCH] deps: V8: cherry-pick c2792e58035f
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Original commit message:
+
+    [base] Fix build with gcc-13
+
+    See https://gcc.gnu.org/gcc-13/porting_to.html#header-dep-changes.
+
+    Also see Gentoo Linux bug report: https://bugs.gentoo.org/865981
+
+    Change-Id: I421f396b02ba37e12ee70048ee33e034f8113566
+    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3934140
+    Reviewed-by: Clemens Backes <clemensb@chromium.org>
+    Reviewed-by: Simon Zund <szuend@chromium.org>
+    Commit-Queue: Clemens Backes <clemensb@chromium.org>
+    Cr-Commit-Position: refs/heads/main@{#83587}
+
+Refs: https://github.com/v8/v8/commit/c2792e58035fcbaa16d0cb70998852fbeb5df4cc
+PR-URL: https://github.com/nodejs/node/pull/44961
+Fixes: https://github.com/nodejs/node/issues/43642
+Reviewed-By: Michael Zasso <targos@protonmail.com>
+Reviewed-By: Richard Lau <rlau@redhat.com>
+Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
+Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
+
+Upstream-Status: Backport [https://github.com/nodejs/node/commit/0be1c5728173ea9ac42843058e26b6268568acf0]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ deps/v8/AUTHORS                               | 1 +
+ deps/v8/src/base/logging.h                    | 1 +
+ deps/v8/src/inspector/v8-string-conversions.h | 1 +
+ 3 files changed, 3 insertions(+)
+
+diff --git a/deps/v8/src/base/logging.h b/deps/v8/src/base/logging.h
+index 08db24a9..38be165f 100644
+--- a/deps/v8/src/base/logging.h
++++ b/deps/v8/src/base/logging.h
+@@ -5,6 +5,7 @@
+ #ifndef V8_BASE_LOGGING_H_
+ #define V8_BASE_LOGGING_H_
+ 
++#include <cstdint>
+ #include <cstring>
+ #include <sstream>
+ #include <string>
+diff --git a/deps/v8/src/inspector/v8-string-conversions.h b/deps/v8/src/inspector/v8-string-conversions.h
+index c1d69c18..eb33c681 100644
+--- a/deps/v8/src/inspector/v8-string-conversions.h
++++ b/deps/v8/src/inspector/v8-string-conversions.h
+@@ -5,6 +5,7 @@
+ #ifndef V8_INSPECTOR_V8_STRING_CONVERSIONS_H_
+ #define V8_INSPECTOR_V8_STRING_CONVERSIONS_H_
+ 
++#include <cstdint>
+ #include <string>
+ 
+ // Conversion routines between UT8 and UTF16, used by string-16.{h,cc}. You may
diff --git a/meta-oe/recipes-devtools/nodejs/nodejs_12.22.12.bb b/meta-oe/recipes-devtools/nodejs/nodejs_12.22.12.bb
index c1d66eeffb..facc399085 100644
--- a/meta-oe/recipes-devtools/nodejs/nodejs_12.22.12.bb
+++ b/meta-oe/recipes-devtools/nodejs/nodejs_12.22.12.bb
@@ -27,6 +27,7 @@ SRC_URI = "http://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz \
            file://CVE-2022-43548.patch \
            file://CVE-llhttp.patch \
            file://python-3.11-invalid-mode-rU.patch \
+           file://gcc13.patch \
            "
 SRC_URI_append_class-target = " \
            file://0002-Using-native-binaries.patch \
diff --git a/meta-oe/recipes-devtools/nodejs/nodejs_14.18.1.bb b/meta-oe/recipes-devtools/nodejs/nodejs_14.18.1.bb
index fc886817ac..882d3f6573 100644
--- a/meta-oe/recipes-devtools/nodejs/nodejs_14.18.1.bb
+++ b/meta-oe/recipes-devtools/nodejs/nodejs_14.18.1.bb
@@ -29,6 +29,7 @@ SRC_URI = "http://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz \
            file://CVE-2022-32212.patch \
            file://CVE-2022-35255.patch \
            file://CVE-2022-43548.patch \
+           file://gcc13.patch \
            "
 SRC_URI:append:class-target = " \
            file://0002-Using-native-binaries-nodejs14.patch \


                 reply	other threads:[~2023-07-23 16:06 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230723160553.2826040-1-Martin.Jansa@gmail.com \
    --to=martin.jansa@gmail.com \
    --cc=akuster808@gmail.com \
    --cc=openembedded-devel@lists.openembedded.org \
    --cc=raj.khem@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox