diff --git a/addon.gypi b/addon.gypi index 3be0f591bd..1422900390 100644 --- a/addon.gypi +++ b/addon.gypi @@ -1,14 +1,25 @@ { + 'variables' : { + 'node_engine_include_dir%': 'deps/v8/include', + }, 'target_defaults': { 'type': 'loadable_module', 'win_delay_load_hook': 'true', 'product_prefix': '', + 'conditions': [ + [ 'node_engine=="chakracore"', { + 'variables': { + 'node_engine_include_dir%': 'deps/chakrashim/include' + }, + }] + ], + 'include_dirs': [ '<(node_root_dir)/include/node', '<(node_root_dir)/src', '<(node_root_dir)/deps/uv/include', - '<(node_root_dir)/deps/v8/include' + '<(node_root_dir)/<(node_engine_include_dir)' ], 'defines!': [ 'BUILDING_UV_SHARED=1', # Inherited from common.gypi. @@ -79,6 +90,12 @@ ], }], [ 'OS=="win"', { + 'conditions': [ + ['node_engine=="chakracore"', { + 'library_dirs': [ '<(node_root_dir)/$(ConfigurationName)' ], + 'libraries': [ '<@(node_engine_libs)' ], + }], + ], 'libraries': [ '-lkernel32.lib', '-luser32.lib', diff --git a/gyp/pylib/gyp/generator/msvs.py b/gyp/pylib/gyp/generator/msvs.py index 2ecf964c68..29c0cea5d7 100644 --- a/gyp/pylib/gyp/generator/msvs.py +++ b/gyp/pylib/gyp/generator/msvs.py @@ -338,6 +338,8 @@ def _BuildCommandLineForRuleRaw(spec, cmd, cygwin_shell, has_input_path, command = ['type'] else: command = [cmd[0].replace('/', '\\')] + if quote_cmd: + command = ['"%s"' % i for i in command] # Add call before command to ensure that commands can be tied together one # after the other without aborting in Incredibuild, since IB makes a bat # file out of the raw command string, and some commands (like python) are @@ -3209,6 +3211,9 @@ def _GetMSBuildProjectReferences(project): ['ReferenceOutputAssembly', 'false'] ] for config in dependency.spec.get('configurations', {}).itervalues(): + if config.get('msvs_use_library_dependency_inputs', 0): + project_ref.append(['UseLibraryDependencyInputs', 'true']) + break # If it's disabled in any config, turn it off in the reference. if config.get('msvs_2010_disable_uldi_when_referenced', 0): project_ref.append(['UseLibraryDependencyInputs', 'false']) diff --git a/lib/configure.js b/lib/configure.js index 54bb2ccb3a..d52b2902b0 100644 --- a/lib/configure.js +++ b/lib/configure.js @@ -272,6 +272,8 @@ function configure (gyp, argv, callback) { argv.push('-Dnode_gyp_dir=' + nodeGypDir) argv.push('-Dnode_lib_file=' + release.name + '.lib') argv.push('-Dmodule_root_dir=' + process.cwd()) + argv.push('-Dnode_engine=' + + (gyp.opts.node_engine || process.jsEngine || 'v8')) argv.push('--depth=.') argv.push('--no-parallel')