build: enable loading builtin modules at runtime #36215
Closed
Description
Is your feature request related to a problem? Please describe.
It might be a problem to build node entirely every time the path to the node builtin modules is changed.
Describe the solution you'd like
- During the configuration stage, instead of using
--node-builtin-modules-path
with a path value, we can use an--enable-runtime-node-builtin-modules
flag to enable this feature. - At runtime, the path to the builtin modules can be read in from an environment variable
NODE_BUILTIN_MODULES_PATH
usinglibuv
OR it can be passed to node as a command line argument using--node-builtin-modules-path
with a path value.
Fixes: nodejs/help#3087
Ref: #31321
Activity