Created attachment 265362 [details] Poudriere build log mongosh started failing to build at 2025-11-12_03h05m01s Both 2.5.5_2 and 2.5.5_3 fail in the same way: Applying patch from /wrkdirs/usr/ports/databases/mongosh/work/mongosh-2.5.5/scripts/nodejs-patches/001-configure-bz2.patch... Applying patch from /wrkdirs/usr/ports/databases/mongosh/work/mongosh-2.5.5/scripts/nodejs-patches/002-workaround-node-bug-52229... Applying patch from /wrkdirs/usr/ports/databases/mongosh/work/mongosh-2.5.5/scripts/nodejs-patches/003-no-sys-random-on-older-glibc-node-52223.patch... Applying patch from /wrkdirs/usr/ports/databases/mongosh/work/mongosh-2.5.5/scripts/nodejs-patches/004-build-fix-arm64-cross-compilation.patch... Applying patch from /wrkdirs/usr/ports/databases/mongosh/work/mongosh-2.5.5/scripts/nodejs-patches/010-src-cares_wrap.h... Applying patch from /wrkdirs/usr/ports/databases/mongosh/work/mongosh-2.5.5/scripts/nodejs-patches/011-deps-v8-src-base-small-vector.h... error: patch failed: deps/v8/src/base/small-vector.h:22 error: deps/v8/src/base/small-vector.h: patch does not apply ✖ Failed: applying patch failed with code 1 /wrkdirs/usr/ports/databases/mongosh/work/mongosh-2.5.5/packages/build/src/compile/signable-compiler.ts:67 throw new Error(`applying patch failed with code ${code}`); ^ Error: applying patch failed with code 1 at Object.preCompileHook (/wrkdirs/usr/ports/databases/mongosh/work/mongosh-2.5.5/packages/build/src/compile/signable-compiler.ts:67:13) at processTicksAndRejections (node:internal/process/task_queues:105:5) at async compileJSFileAsBinaryImpl (/wrkdirs/usr/ports/databases/mongosh/work/mongosh-2.5.5/node_modules/boxednode/src/index.ts:387:5) at async compileJSFileAsBinary (/wrkdirs/usr/ports/databases/mongosh/work/mongosh-2.5.5/node_modules/boxednode/src/index.ts:509:5) at async SignableCompiler.compile (/wrkdirs/usr/ports/databases/mongosh/work/mongosh-2.5.5/packages/build/src/compile/signable-compiler.ts:172:5) at async runCompile (/wrkdirs/usr/ports/databases/mongosh/work/mongosh-2.5.5/packages/build/src/compile/run-compile.ts:21:3) at async release (/wrkdirs/usr/ports/databases/mongosh/work/mongosh-2.5.5/packages/build/src/release.ts:86:5) at async /wrkdirs/usr/ports/databases/mongosh/work/mongosh-2.5.5/packages/build/src/index.ts:115:9 npm error Lifecycle script `evergreen-release` failed with error: npm error code 1 npm error path /wrkdirs/usr/ports/databases/mongosh/work/mongosh-2.5.5/packages/build npm error workspace @mongosh/build@3.7.0 npm error location /wrkdirs/usr/ports/databases/mongosh/work/mongosh-2.5.5/packages/build npm error command failed npm error command sh -c ts-node -r ../../scripts/import-expansions.js src/index.ts compile *** Error code 1 Stop. make: stopped in /usr/ports/databases/mongosh
This is due to the newly set node24 as lts. My mongosh port follow node's lts so I have to update some patches.
I removed that patch file locally and eventually wound up dying with this at the end of the output → Running ./configure --disable-shared-readonly-heap --prefix=/usr/local --shared-brotli --shared-cares --shared-libuv --shared-nghttp2 --shared-nghttp3 --shared-ngtcp2 --shared-simdjson --shared-zlib --shared-zstd --shared-openssl --openssl-use-def-ca-store --with-intl=system-icu --without-npm --link-module ./lib-boxednode/mongosh.js ... Node.js configure: Found Python 3.11.12... gyp: --disable-shared-readonly-heap not found (cwd: /usr/ports/databases/mongosh/work/boxednode/mongosh/node-v24.11.0) while trying to load --disable-shared-readonly-heap Error running GYP ✖ Failed: Command failed: ./configure --disable-shared-readonly-heap --prefix=/usr/local --shared-brotli --shared-cares --shared-libuv --shared-nghttp2 --shared-nghttp3 --shared-ngtcp2 --shared-simdjson --shared-zlib --shared-zstd --shared-openssl --openssl-use-def-ca-store --with-intl=system-icu --without-npm --link-module ./lib-boxednode/mongosh.js (code 1) Error: Command failed: ./configure --disable-shared-readonly-heap --prefix=/usr/local --shared-brotli --shared-cares --shared-libuv --shared-nghttp2 --shared-nghttp3 --shared-ngtcp2 --shared-simdjson --shared-zlib --shared-zstd --shared-openssl --openssl-use-def-ca-store --with-intl=system-icu --without-npm --link-module ./lib-boxednode/mongosh.js (code 1) at Object.spawnBuildCommand (/usr/ports/databases/mongosh/work/mongosh-2.5.5/node_modules/boxednode/src/helpers.ts:47:11) at processTicksAndRejections (node:internal/process/task_queues:105:5) at async compileNode (/usr/ports/databases/mongosh/work/mongosh-2.5.5/node_modules/boxednode/src/index.ts:212:5) at async writeMainFileAndCompile (/usr/ports/databases/mongosh/work/mongosh-2.5.5/node_modules/boxednode/src/index.ts:441:12) at async compileJSFileAsBinaryImpl (/usr/ports/databases/mongosh/work/mongosh-2.5.5/node_modules/boxednode/src/index.ts:454:18) at async compileJSFileAsBinary (/usr/ports/databases/mongosh/work/mongosh-2.5.5/node_modules/boxednode/src/index.ts:509:5) at async SignableCompiler.compile (/usr/ports/databases/mongosh/work/mongosh-2.5.5/packages/build/src/compile/signable-compiler.ts:172:5) at async runCompile (/usr/ports/databases/mongosh/work/mongosh-2.5.5/packages/build/src/compile/run-compile.ts:21:3) at async release (/usr/ports/databases/mongosh/work/mongosh-2.5.5/packages/build/src/release.ts:86:5) at async /usr/ports/databases/mongosh/work/mongosh-2.5.5/packages/build/src/index.ts:115:9 npm error Lifecycle script `evergreen-release` failed with error: npm error code 1 npm error path /usr/ports/databases/mongosh/work/mongosh-2.5.5/packages/build npm error workspace @mongosh/build@3.7.0 npm error location /usr/ports/databases/mongosh/work/mongosh-2.5.5/packages/build npm error command failed npm error command sh -c ts-node -r ../../scripts/import-expansions.js src/index.ts compile *** Error code 1
Created attachment 265639 [details] patch that fixes build with node24 I did not update mongosh to the latest version for now. This is just to fix the build of mongosh 2.5.5.
mongosh built with that patch but I get ">mongosh Assertion failed: (EmbedderSnapshotData::CanUseCustomSnapshotPerIsolate()), function RunNodeInstance, file ../src/node_main.cc, line 251." when I try to run it.
I opened an issue upstream: https://jira.mongodb.org/projects/MONGOSH/issues/MONGOSH-3046 I guess I'll have to set node22 as default build version for now.