mongodb: Fix build with clang16+32bit hosts
PATCH 1/2 mongodb: Fix build with clang16+32bit hosts
Signed-off-by Khem Raj <[email protected]>
--- ...01-Fix-type-mismatch-on-32bit-arches.patch | 38 +++++++++++++++++++ .../recipes-dbs/mongodb/mongodb_git.bb | 1 + 2 files changed, 39 insertions(+) create mode 100644 meta-oe/dynamic-layers/meta-python/recipes-dbs/mongodb/mongodb/0001-Fix-type-mismatch-on-32bit-arches.patch
meta-oe/dynamic-layers/meta-python/recipes-dbs/mongodb/mongodb/0001-Fix-type-mismatch-on-32bit-arches.patch new file +38 -0
@@ -0,0 +1,38 @@ +From 81eabea4e4da55cddfe8bcfcbc3759fa90948254 Mon Sep 17 00:00:00 2001 +From: Khem Raj <[email protected]> +Date: Fri, 3 Mar 2023 14:13:29 -0800 +Subject: [PATCH] Fix type mismatch on 32bit arches + +std::set::size returns an unsigned integral type. +std::max call therefore gets (unsigned int, unsigned long) here. +Type of both arguments is not same, so its ambigous +and there is no matching std::max implementation for mismatching +arguments. std::max expects both input variables to be of +same type, max(int,int) etc.. + +Fixes +src/mongo/util/processinfo_linux.cpp:424:16: error: no matching function for call to 'max' + return std::max(socketIds.size(), 1ul); + +Upstream-Status: Submitted [https://jira.mongodb.org/browse/SERVER-74633] +Signed-off-by: Khem Raj <[email protected]> +--- + src/mongo/util/processinfo_linux.cpp | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/mongo/util/processinfo_linux.cpp b/src/mongo/util/processinfo_linux.cpp +index 9063f140988..9a2c9fb49dc 100644 +--- a/src/mongo/util/processinfo_linux.cpp ++++ b/src/mongo/util/processinfo_linux.cpp +@@ -421,7 +421,7 @@ public: + + // On ARM64, the "physical id" field is unpopulated, causing there to be 0 sockets found. In + // this case, we default to 1. +- return std::max(socketIds.size(), 1ul); ++ return std::max(socketIds.size(), 1u); + } + + /** +-- +2.39.2 +
meta-oe/dynamic-layers/meta-python/recipes-dbs/mongodb/mongodb_git.bb +1 -0
@@ -35,6 +35,7 @@ SRC_URI = "git://github.com/mongodb/mongo.git;branch=v4.4;protocol=https \ file://0001-The-std-lib-unary-binary_function-base-classes-are-d.patch \ file://0001-free_mon-Include-missing-cstdint.patch \ file://0001-apply-msvc-workaround-for-clang-16.patch \ + file://0001-Fix-type-mismatch-on-32bit-arches.patch \ " SRC_URI:append:libc-musl ="\ file://0001-Mark-one-of-strerror_r-implementation-glibc-specific.patch \
Signature · 1 line
2.39.2
PATCH 2/2 nodejs: Upgrade to 18.14.2
License-Update: Add base64 license information [1] and postject [2]
Backport patch to fix enum size errors with clang
[1] https://github.com/nodejs/node/commit/2ec8092e2cf70267e765dfe4baf13d72838a58ed
[2] https://github.com/nodejs/node/commit/4aaec0726694ad0d3cb05d7f2593a90363c32f32
Signed-off-by Khem Raj <[email protected]>
---
.../oe-npm-cache | 0
....12.bb => nodejs-oe-cache-native_18.14.bb} | 0
...e-running-gyp-files-for-bundled-deps.patch | 6 +-
...-only-as-wide-as-necessary-for-enums.patch | 158 ++++++++++++++++++
.../nodejs/nodejs/gcc13.patch | 70 --------
.../{nodejs_18.12.1.bb => nodejs_18.14.2.bb} | 8 +-
6 files changed, 164 insertions(+), 78 deletions(-)
rename meta-oe/recipes-devtools/nodejs/{nodejs-oe-cache-18.12 => nodejs-oe-cache-18.14}/oe-npm-cache (100%)
rename meta-oe/recipes-devtools/nodejs/{nodejs-oe-cache-native_18.12.bb => nodejs-oe-cache-native_18.14.bb} (100%)
create mode 100644 meta-oe/recipes-devtools/nodejs/nodejs/0001-Make-bitfields-only-as-wide-as-necessary-for-enums.patch
delete mode 100644 meta-oe/recipes-devtools/nodejs/nodejs/gcc13.patch
rename meta-oe/recipes-devtools/nodejs/{nodejs_18.12.1.bb => nodejs_18.14.2.bb} (96%)meta-oe/recipes-devtools/nodejs/nodejs-oe-cache-18.14/oe-npm-cache renamed from meta-oe/recipes-devtools/nodejs/nodejs-oe-cache-18.12/oe-npm-cache +0 -0
meta-oe/recipes-devtools/nodejs/nodejs-oe-cache-native_18.14.bb renamed from meta-oe/recipes-devtools/nodejs/nodejs-oe-cache-native_18.12.bb +0 -0
meta-oe/recipes-devtools/nodejs/nodejs/0001-Disable-running-gyp-files-for-bundled-deps.patch +2 -4
@@ -33,16 +33,14 @@ do_unpack[postfuncs] += "prune_sources" Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -diff --git a/Makefile b/Makefile -index 93d63110..79caaec2 100644 --- a/Makefile +++ b/Makefile -@@ -138,7 +138,7 @@ with-code-cache test-code-cache: +@@ -169,7 +169,7 @@ with-code-cache test-code-cache: $(warning '$@' target is a noop) out/Makefile: config.gypi common.gypi node.gyp \ - deps/uv/uv.gyp deps/llhttp/llhttp.gyp deps/zlib/zlib.gyp \ + deps/llhttp/llhttp.gyp \ + deps/simdutf/simdutf.gyp \ tools/v8_gypfiles/toolchain.gypi tools/v8_gypfiles/features.gypi \ tools/v8_gypfiles/inspector.gypi tools/v8_gypfiles/v8.gyp - $(PYTHON) tools/gyp_node.py -f make
meta-oe/recipes-devtools/nodejs/nodejs/0001-Make-bitfields-only-as-wide-as-necessary-for-enums.patch new file +158 -0
158 lines not on this page · raw message
meta-oe/recipes-devtools/nodejs/nodejs/gcc13.patch deleted +0 -70
70 lines not on this page · raw message
meta-oe/recipes-devtools/nodejs/nodejs_18.14.2.bb renamed from meta-oe/recipes-devtools/nodejs/nodejs_18.12.1.bb +4 -4
@@ -1,7 +1,7 @@ DESCRIPTION = "nodeJS Evented I/O for V8 JavaScript" HOMEPAGE = "http://nodejs.org" -LICENSE = "MIT & ISC & BSD-2-Clause & BSD-3-Clause & Artistic-2.0" -LIC_FILES_CHKSUM = "file://LICENSE;md5=dfd7ae796baf5326016a3865ee1dc632" +LICENSE = "MIT & ISC & BSD-2-Clause & BSD-3-Clause & Artistic-2.0 & Apache-2.0" +LIC_FILES_CHKSUM = "file://LICENSE;md5=2dff1ccca11e333f1388e34f7e2d1de3" CVE_PRODUCT = "nodejs node.js"
@@ -27,7 +27,7 @@ SRC_URI = "http://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz \ file://system-c-ares.patch \ file://0001-liftoff-Correct-function-signatures.patch \ file://0001-mips-Use-32bit-cast-for-operand-on-mips32.patch \ - file://gcc13.patch \ + file://0001-Make-bitfields-only-as-wide-as-necessary-for-enums.patch \ " SRC_URI:append:class-target = " \
@@ -39,7 +39,7 @@ SRC_URI:append:toolchain-clang:x86 = " \ SRC_URI:append:toolchain-clang:powerpc64le = " \ file://0001-ppc64-Do-not-use-mminimal-toc-with-clang.patch \ " -SRC_URI[sha256sum] = "4fa406451bc52659a290e52cfdb2162a760bd549da4b8bbebe6a29f296d938df" +SRC_URI[sha256sum] = "fbc364dd25fee2cacc0f2033db2d86115fc07575310ea0e64408b8170d09c685" S = "${WORKDIR}/node-v${PV}"
Signature · 1 line
2.39.2