From 28379bd9aac2643b6e45b1e5973c480d1b34b770 Mon Sep 17 00:00:00 2001 From: Refael Ackermann Date: Thu, 17 May 2018 11:54:11 -0400 Subject: [PATCH] deps, v8: fix build torque on windows On windows the torque binary needs to be compiled and linked with exception semantics and assume V8 is embedded Fixes: https://github.com/nodejs/node-v8/issues/57 --- deps/v8/gypfiles/v8.gyp | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/deps/v8/gypfiles/v8.gyp b/deps/v8/gypfiles/v8.gyp index 450cc9084ca..a890f780aaa 100644 --- a/deps/v8/gypfiles/v8.gyp +++ b/deps/v8/gypfiles/v8.gyp @@ -2526,10 +2526,33 @@ 'GCC_ENABLE_CPP_RTTI': 'YES', # -frtti }, 'defines': ['ANTLR4CPP_STATIC'], + 'defines!': [ + '_HAS_EXCEPTIONS=0', + 'BUILDING_V8_SHARED=1', + ], 'include_dirs': [ '../third_party/antlr4/runtime/Cpp/runtime/src', '../src/torque', ], + # This is defined trough `configurations` for GYP+ninja compatibility + 'configurations': { + 'Debug': { + 'msvs_settings': { + 'VCCLCompilerTool': { + 'RuntimeTypeInfo': 'true', + 'ExceptionHandling': 1, + }, + } + }, + 'Release': { + 'msvs_settings': { + 'VCCLCompilerTool': { + 'RuntimeTypeInfo': 'true', + 'ExceptionHandling': 1, + }, + } + }, + }, 'sources': [ '../src/torque/TorqueBaseVisitor.cpp', '../src/torque/TorqueBaseVisitor.h',