summaryrefslogtreecommitdiff
path: root/node.gyp
diff options
context:
space:
mode:
Diffstat (limited to 'node.gyp')
-rw-r--r--node.gyp25
1 files changed, 25 insertions, 0 deletions
diff --git a/node.gyp b/node.gyp
index 2ad76020f5..9d6d0dd7cb 100644
--- a/node.gyp
+++ b/node.gyp
@@ -251,6 +251,31 @@
],
},
+ 'target_defaults': {
+ # Putting these explicitly here so not to depend on `common.gypi`.
+ # `common.gypi` need to be more general because it is used to build userland native addons.
+ # Refs: https://github.com/nodejs/node-gyp/issues/1118
+ 'cflags': [ '-Wall', '-Wextra', '-Wno-unused-parameter', ],
+ 'xcode_settings': {
+ 'WARNING_CFLAGS': [
+ '-Wall',
+ '-Wendif-labels',
+ '-W',
+ '-Wno-unused-parameter',
+ '-Werror=undefined-inline',
+ ],
+ },
+
+ # Relevant only for x86.
+ # Refs: https://github.com/nodejs/node/pull/25852
+ # Refs: https://docs.microsoft.com/en-us/cpp/build/reference/safeseh-image-has-safe-exception-handlers
+ 'msvs_settings': {
+ 'VCLinkerTool': {
+ 'ImageHasSafeExceptionHandlers': 'false',
+ },
+ },
+ },
+
'targets': [
{
'target_name': '<(node_core_target_name)',