Commit graph

151 commits

Author SHA1 Message Date
Michaël Zasso
0946c8b28b
tools: disable nullability-completeness warnings
Seems Clang-specific and doesn't only affect macOS.
This is a very noisy warning from abseil-cpp.

PR-URL: https://github.com/nodejs/node/pull/59392
Reviewed-By: Richard Lau <richard.lau@ibm.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Filip Skokan <panva.ip@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2025-08-09 12:15:01 +00:00
Yao Zi
7be2528e05
tools: compile maglev files into v8_compiler if maglev is disabled
v8_compiler needs maglev graph builder even if maglev is disabled. But
the required files shouldn't be compiled into v8_internal_headers, which
both v8_base_without_compiler and v8_compiler depends on, causing
duplicate symbols during linking if maglev is disabled or not available
for the target. Let's move the files into v8_compiler target where they
are used.

Fixes: https://github.com/nodejs/node/issues/58954
PR-URL: https://github.com/nodejs/node/pull/58861
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Richard Lau <richard.lau@ibm.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
2025-07-07 13:52:02 +00:00
Chengzhong Wu
4623d46b7c
tools: include toolchain.gypi in abseil.gyp
This sets proper SIMD build flags for abseil on ia32.

PR-URL: https://github.com/nodejs/node/pull/58678
Fixes: https://github.com/nodejs/node/issues/58569
Reviewed-By: Michaël Zasso <targos@protonmail.com>
2025-06-20 09:27:25 +00:00
hqzing
7964eb3a3b
build: add support for OpenHarmony operating system
PR-URL: https://github.com/nodejs/node/pull/58350
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Michael Dawson <midawson@redhat.com>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
2025-05-21 13:18:38 +00:00
Joyee Cheung
ac8706196b build: fix pointer compression builds
- Remove usage of deprecated V8::InitializeSandbox().
- External code space and pointer compression shared cage must
  be enabled when pointer compression builds are enabled.
- We cannot enable the sandbox because that requires allocating
  the array buffer backing stores in the sandbox - we currently
  have many backing stores tied to pointers from C++ land that
  are not even necessarily dynamic (e.g. in static storage).
  Until we manage to get rid of all those, sandbox cannot be
  enabled. Note that enabling pointer compression without
  enabling sandbox is unsupported by V8, and can be broken
  at any time.

PR-URL: https://github.com/nodejs/node/pull/58171
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Juan José Arboleda <soyjuanarbol@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2025-05-18 23:24:01 +00:00
Michaël Zasso
a8217a9eb8 tools: update V8 gypfiles for 13.7
Refs: 1eb7d3ce47
Refs: f942a499fe
PR-URL: https://github.com/nodejs/node/pull/58064
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
Reviewed-By: Paolo Insogna <paolo@cowtech.it>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
2025-05-18 07:42:54 +00:00
Abdirahim Musse
41b926366f
tools: add missing highway defines for IBM i
This was added for AIX but should have included IBM i as well.

PR-URL: https://github.com/nodejs/node/pull/58335
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Michael Dawson <midawson@redhat.com>
2025-05-17 04:29:12 +00:00
Michaël Zasso
85a397f1f1
tools: update V8 gypfiles for 13.6
PR-URL: https://github.com/nodejs/node/pull/58070
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
2025-05-02 15:10:38 +02:00
Michaël Zasso
7557584cba
tools: update V8 gypfiles for 13.5
PR-URL: https://github.com/nodejs/node/pull/58070
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
2025-05-02 15:10:38 +02:00
Michaël Zasso
7963548186
build: fix V8 TLS config for shared lib builds
PR-URL: https://github.com/nodejs/node/pull/58070
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
2025-05-02 15:10:37 +02:00
Michaël Zasso
96c5ee1fc1
build: add /bigobj to compile V8 on Windows
PR-URL: https://github.com/nodejs/node/pull/58070
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
2025-05-02 15:10:35 +02:00
Michaël Zasso
e9a75322eb
tools: update V8 gypfiles for 13.4
Build Node.js with simdutf version from V8.

Refs: d62905147c
Refs: 616c87580c
Refs: e3204d589e
Refs: e8293d2b87
Refs: aeb2220058
Refs: 5621164e3c
Co-authored-by: Abdirahim Musse <abdirahim.musse@ibm.com>
PR-URL: https://github.com/nodejs/node/pull/58070
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
2025-05-02 15:10:35 +02:00
Michaël Zasso
cff3fa5f03
build,src,tools: adapt build config for V8 13.3
Refs: 1c9f59c80f
Refs: b1c5eba50a
Refs: b3054f77d6
Refs: f81e87ee5c
Refs: dc0e305223
Refs: 41d42cec13
PR-URL: https://github.com/nodejs/node/pull/58070
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
2025-05-02 15:10:35 +02:00
Michaël Zasso
bd198ea8cd
tools: update V8 gypfiles for 13.2
Refs: cee178fe7c
PR-URL: https://github.com/nodejs/node/pull/58070
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
2025-05-02 15:10:34 +02:00
Michaël Zasso
0c089ce405
tools: update V8 gypfiles for 13.1
Refs: 74e68ab3e4
Refs: 8390dabf93
PR-URL: https://github.com/nodejs/node/pull/58070
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
2025-05-02 15:10:34 +02:00
Richard Lau
4805586fa6
build: remove support for s390 32-bit
V8 removed support for it.

Refs: 9565a9a721
PR-URL: https://github.com/nodejs/node/pull/58070
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
2025-05-02 15:10:34 +02:00
Luigi Pinca
2cff98c853
build: fix missing files warning
This commit fixes the following warning:

    Warning: Missing input files:
    C:\Users\lpinca\node\tools\v8_gypfiles\..\..\deps\v8\third_party\abseil-cpp\absl\strings\internal\has_absl_stringify.h
    C:\Users\lpinca\node\deps\ncrypto\dh-primes.h

bd3c25cf31 removed
`'<(ABSEIL_ROOT)/absl/strings/has_absl_stringify.h'` instead of
`'<(ABSEIL_ROOT)/absl/strings/internal/has_absl_stringify.h'`

Refs: 5ab3140dfb
Refs: b9b4cb7731
PR-URL: https://github.com/nodejs/node/pull/57870
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
2025-04-19 15:22:06 +00:00
Michaël Zasso
2b76dca0fa
build: remove redundant -mXX flags for V8
They are already set by `common.gypi`.

PR-URL: https://github.com/nodejs/node/pull/57907
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2025-04-19 10:22:10 +00:00
Chengzhong Wu
78af51cfe6
src: disable abseil deadlock detection
Abseil deadlock detection is reporting false positives in tests.
Disable it for now.

PR-URL: https://github.com/nodejs/node/pull/57582
Refs: https://github.com/nodejs/node-v8/issues/301
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Stefan Stojanovic <stefan.stojanovic@janeasystems.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
2025-04-02 09:01:03 +00:00
Chengzhong Wu
4e222aea82
tools: extract target abseil to abseil.gyp
Both V8 and perfetto depends on abseil. When perfetto support is
enabled, V8 also depends on perfetto.

In order to share abseil between perfetto and V8 targets, and avoid
cycle dependencies between `v8.gyp` and `perfetto.gyp`, this extracts
target `abseil` from `v8.gyp` to an independent file `abseil.gyp`.

PR-URL: https://github.com/nodejs/node/pull/57289
Refs: https://github.com/nodejs/diagnostics/issues/654
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
2025-03-05 12:30:33 +00:00
Chengzhong Wu
464485397a
tools: remove deps/zlib/GN-scraper.py
Gyp appends search path for `pymod_do_main`, so `GN-scraper.py` in
`v8_gypfiles` always takes precedence over `deps/zlib/GN-scraper.py`,
and `deps/zlib/GN-scraper.py` is never loaded.

PR-URL: https://github.com/nodejs/node/pull/57238
Refs: 46fc91f1fa/pylib/gyp/input.py (L935)
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2025-03-02 12:36:30 +00:00
Stefan Stojanovic
a017307e7e
build,win: enable ccache
PR-URL: https://github.com/nodejs/node/pull/56847
Refs: https://github.com/nodejs/node/pull/56705
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
2025-02-09 12:11:15 +00:00
Chengzhong Wu
297a4dd339 src: add a hard dependency v8_inspector_headers
A GYP hard dependency instructs GYP to not remove the dependency link
between two static library targets in its generated output. This
allows V8 dependents to include V8 inspector protocol headers.

PR-URL: https://github.com/nodejs/node/pull/56805
Refs: https://github.com/nodejs/node/issues/53946
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Kohei Ueno <kohei.ueno119@gmail.com>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
2025-02-08 13:39:18 +00:00
Michaël Zasso
89f661dd66
build: link V8 with atomic library
Closes: https://github.com/nodejs/node-v8/issues/290
PR-URL: https://github.com/nodejs/node/pull/55014
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
2025-01-31 12:47:16 +01:00
Michaël Zasso
6f965260dd
tools: update V8 gypfiles for 13.0
Refs: 568f50df74
Refs: 643753953a
PR-URL: https://github.com/nodejs/node/pull/55014
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
2025-01-31 12:47:07 +01:00
Xiao-Tao
8c19a5c885
tools: fix loong64 build failed
PR-URL: https://github.com/nodejs/node/pull/56466
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2025-01-07 16:31:45 +00:00
Joyee Cheung
756077867b
build: build v8 with -fvisibility=hidden on macOS
V8 should be built with -fvisibility=hidden, otherwise
the resulting binary would contain unnecessary symbols. In
particular, on macOS, this leads to 5000+ weak symbols
resolved at runtime, leading to a startup regression.

On macOS this also reduces the binary size about ~10MB.

It's only enabled on macOS in this patch as gcc can time out
or run out of memory on some machines in the CI with
-fvisibility=hidden.

PR-URL: https://github.com/nodejs/node/pull/56275
Fixes: https://github.com/nodejs/performance/issues/180
Reviewed-By: Juan José Arboleda <soyjuanarbol@gmail.com>
Reviewed-By: Daniel Lemire <daniel@lemire.me>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
2024-12-19 03:24:51 +00:00
Joyee Cheung
8253290d60
build: fix missing fp16 dependency in d8 builds
PR-URL: https://github.com/nodejs/node/pull/56266
Reviewed-By: Juan José Arboleda <soyjuanarbol@gmail.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2024-12-17 22:18:32 +00:00
Michaël Zasso
bd3c25cf31
tools: remove has_absl_stringify from gyp file
File was removed in https://github.com/nodejs/node/pull/54536

PR-URL: https://github.com/nodejs/node/pull/56157
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2024-12-10 10:10:16 +00:00
Yolanda-Chen
b5056be854
v8,tools: expose experimental wasm revectorize feature
PR-URL: https://github.com/nodejs/node/pull/54896
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2024-12-08 00:24:47 +01:00
Lu Yahan
bdaa898cea
tools: fix riscv64 build failed
PR-URL: https://github.com/nodejs/node/pull/52888
Reviewed-By: Stewart X Addison <sxa@redhat.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
2024-11-18 15:41:23 +00:00
Nathan Baulch
0f375db9c6
tools: fix typos
PR-URL: https://github.com/nodejs/node/pull/55061
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2024-10-15 13:59:49 +00:00
Stefan Stojanovic
27f8d9e9d2
build,win: enable pch for clang-cl
Fixes: https://github.com/nodejs/node/issues/55208
PR-URL: https://github.com/nodejs/node/pull/55249
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
2024-10-11 10:28:55 +00:00
Abdirahim Musse
c8c108f9b0 tools: add additonal include dirs for V8 on AIX
On AIX, we now include src/wasm/float16.h from within src/utils/utils.h
and src/wasm/float16.h includes additional header files.

PR-URL: https://github.com/nodejs/node/pull/54536
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
2024-09-19 14:25:42 +00:00
Michaël Zasso
c6269cb069
tools: fix path of abseil file in v8.gyp
PR-URL: https://github.com/nodejs/node/pull/54659
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
2024-09-17 11:47:08 +00:00
Stefan Stojanovic
79a33a7433
build,win: enable clang-cl compilation
This uses the backported ICU fix needed for compiling with ClangCL.

Refs: https://github.com/nodejs/node/pull/54502
Fixes: https://github.com/nodejs/node/issues/34201
PR-URL: https://github.com/nodejs/node/pull/54655
Refs: https://github.com/nodejs/node/issues/52809
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Steven R Loomis <srl295@gmail.com>
2024-09-09 10:26:00 +00:00
Michaël Zasso
64e8646618
tools: update V8 gypfiles for 12.8
Refs: 06847fbbd4
PR-URL: https://github.com/nodejs/node/pull/54077
Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
2024-08-16 16:05:31 +02:00
Richard Lau
dc352a5ff2
tools: update V8 gypfiles for 12.7
Add/remove abseil files introduced by V8 12.7 update found by:

```
git diff-tree --no-commit-id --name-status 0ec8f7eea3 -r
  | grep '^[AD].*abseil.*'
```

PR-URL: https://github.com/nodejs/node/pull/54077
Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
2024-08-16 16:05:13 +02:00
Michaël Zasso
8044051ce3
tools: update V8 gypfiles for 12.6
Refs: f8fa22073a
PR-URL: https://github.com/nodejs/node/pull/54077
Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
2024-08-16 16:04:30 +02:00
Leszek Swirski
9d0748c5df
build: disable ICF for mksnapshot
Refs: 5447267
Co-authored-by: Michaël Zasso <targos@protonmail.com>
PR-URL: https://github.com/nodejs/node/pull/54077
Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
2024-08-16 16:04:25 +02:00
Michaël Zasso
2573f74b0d
build: always disable strict aliasing
V8 relies on it.

PR-URL: https://github.com/nodejs/node/pull/54339
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2024-08-14 18:33:43 +00:00
Michaël Zasso
a5decd4c8d
build: drop experimental support for Windows <10
V8 now uses Windows APIs that are not available in older Windows
versions.

PR-URL: https://github.com/nodejs/node/pull/54079
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
Reviewed-By: Stefan Stojanovic <stefan.stojanovic@janeasystems.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2024-07-30 12:29:17 +00:00
Chengzhong Wu
e192a32c27
build: fix conflict gyp configs
Gyp generated build files can be built in either Release/Debug mode.

- make: single directory, two configurations by cli:
  `make -C out BUILDTYPE=Release` and `make -C out BUILDTYPE=Debug`.
- msbuild: single directory, two configurations by cli:
  `msbuild node.sln /p:Configuration=Release` and
  `msbuild node.sln /p:Configuration=Debug`.
- ninja: two directories in `out/`, build with
  `ninja -C out/Release` or `ninja -C out/Debug`.

Variables that changes with either Release or Debug configuration
should be defined in a configuration level, instead of the root level.
This fixes generating invalid build files.

Additionally, `v8_gypfiles/toolchain.gypi` duplicates defines in
`v8_gypfiles/features.gypi`. Remove the duplications in
`toolchains.gypi`

PR-URL: https://github.com/nodejs/node/pull/53605
Fixes: https://github.com/nodejs/node/issues/53446
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2024-07-23 08:56:44 +00:00
Daeyeon Jeong
58711c2f8d
build: fix --v8-lite-mode build
Signed-off-by: Daeyeon Jeong <daeyeon.dev@gmail.com>
PR-URL: https://github.com/nodejs/node/pull/52725
Fixes: https://github.com/nodejs/node/issues/52710
Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2024-06-03 11:00:47 +00:00
Michaël Zasso
7ad0cc3e57
build: remove support for 32-bit Windows
Closes: https://github.com/nodejs/node/issues/42543
PR-URL: https://github.com/nodejs/node/pull/53184
Fixes: https://github.com/nodejs/node/issues/42543
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Michael Dawson <midawson@redhat.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io>
Reviewed-By: Robert Nagy <ronagy@icloud.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
Reviewed-By: Stefan Stojanovic <stefan.stojanovic@janeasystems.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
2024-05-30 14:28:47 +00:00
Richard Lau
bc13f23f7e
build: fix --enable-d8 builds
Add `v8_abseil` as a dependency for `d8` and use scraping to pick up
the list of source files (including the previously missing
`src/d8/d8-test.cc`).

PR-URL: https://github.com/nodejs/node/pull/53106
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Michael Dawson <midawson@redhat.com>
Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
2024-05-24 17:32:09 +00:00
Michaël Zasso
efa63f3d05
build: add option to enable clang-cl on Windows
Most changes are gated by the `clang==1` condition to avoid breaking
MSVC builds.

Select C/C++ language standard with ClCompile options.
This avoids passing the `-std:c++20` flag while compiling C code.
Do it only under clang option to avoid breaking addons until node-gyp
supports the new LanguageStandard options.

Disable precompiled header configuration for now as it doesn't seem to
work with clang-cl.

Disable C++20 warnings emitted by the Visual Studio C++ STL.
They're very noisy and not our responsibility to fix.

Co-authored-by: Daniel Lemire <daniel@lemire.me>
Co-authored-by: Stefan Stojanovic <stefan.stojanovic@janeasystems.com>
PR-URL: https://github.com/nodejs/node/pull/52870
Reviewed-By: Daniel Lemire <daniel@lemire.me>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2024-05-13 19:05:05 +00:00
Michaël Zasso
2b657ccfb3 build: sync V8 warning cflags with BUILD.gn
PR-URL: https://github.com/nodejs/node/pull/52873
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io>
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com>
2024-05-09 12:11:00 +00:00
Michaël Zasso
25c788009f build: harmonize Clang checks
- Set the clang variable in `config.gypi` so it depends on compiler
  checks made by the configure script.
- Replace gyp conditions with `llvm_version` and "0.0" with conditions
  that use the `clang` variable.
- Always use `clang==1` or `clang==0` in gyp conditions

PR-URL: https://github.com/nodejs/node/pull/52873
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io>
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com>
2024-05-09 12:10:59 +00:00
Michaël Zasso
763602d698 tools: update V8 gypfiles for 12.4
Refs: 6196de89e3
Refs: 4af6461ae3
Refs: 7ba16eadb3
PR-URL: https://github.com/nodejs/node/pull/52465
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Michael Dawson <midawson@redhat.com>
2024-04-22 21:25:24 +00:00