Temporary fix only, node-gyp needs to be aware of whether it can even
download this file for the current runtime so that information needs to
come from the process itself.
Floating patch on npm.
PR-URL: https://github.com/nodejs/io.js/pull/2066
Reviewed-By: Johan Bergström <bugs@bergstroem.nu>
Reviewed-By: Ryan Graham <ryan@strongloop.com>
'product_prefix': '',
'include_dirs': [
'product_prefix': '',
'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)/src',
'<(node_root_dir)/deps/uv/include',
'<(node_root_dir)/deps/v8/include'
// this logic ported from the old `gyp_addon` python file
var gyp_script = path.resolve(__dirname, '..', 'gyp', 'gyp_main.py')
var addon_gypi = path.resolve(__dirname, '..', 'addon.gypi')
// this logic ported from the old `gyp_addon` python file
var gyp_script = path.resolve(__dirname, '..', 'gyp', 'gyp_main.py')
var addon_gypi = path.resolve(__dirname, '..', 'addon.gypi')
- var common_gypi = path.resolve(nodeDir, 'common.gypi')
+ var common_gypi = path.resolve(nodeDir, 'include/node/common.gypi')
+ //TODO: ideally async
+ if (!fs.existsSync(common_gypi))
+ common_gypi = path.resolve(nodeDir, 'common.gypi')
+
var output_dir = 'build'
if (win) {
// Windows expects an absolute path
var output_dir = 'build'
if (win) {
// Windows expects an absolute path
// now download the node tarball
var tarPath = gyp.opts['tarball']
// now download the node tarball
var tarPath = gyp.opts['tarball']
- var tarballUrl = tarPath ? tarPath : distUrl + '/v' + version + '/iojs-v' + version + '.tar.gz'
+ var tarballUrl = tarPath ? tarPath : distUrl + '/v' + version + '/iojs-v' + version + '-headers.tar.gz'
, badDownload = false
, extractCount = 0
, gunzip = zlib.createGunzip()
, badDownload = false
, extractCount = 0
, gunzip = zlib.createGunzip()