Closed Lug16 closed 10 years ago
That's a gyp issue. It tries to auto-detect the VS version but that frequently fails. Try setting GYP_MSVS_VERSION=2013 (or 2013e) in the environment.
I've tried npm install iconv --msvs_version=2013e
and got this:
npm http GET https://registry.npmjs.org/iconv
npm http 304 https://registry.npmjs.org/iconv
> iconv@2.0.7 install c:\Users\Paul\Workspace\test\node_modules\iconv
> node-gyp rebuild
c:\Users\Paul\Workspace\test\node_modules\iconv>node "c:\Bin\nodejs\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild
Traceback (most recent call last):
File "c:\Bin\nodejs\node_modules\npm\node_modules\node-gyp\gyp\gyp", line 18, in <module>
sys.exit(gyp.main(sys.argv[1:]))
File "c:\Bin\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp\__init__.py", line 526, in main
return gyp_main(args)
File "c:\Bin\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp\__init__.py", line 502, in gyp_main
options.circular_check)
File "c:\Bin\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp\__init__.py", line 98, in Load
generator.CalculateVariables(default_variables, params)
File "c:\Bin\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp\generator\msvs.py", line 1713, in CalculateVariables
generator_flags.get('msvs_version', 'auto'))
File "c:\Bin\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp\MSVSVersion.py", line 366, in SelectVisualStudioVersion
versions = _DetectVisualStudioVersions(version_map[version], 'e' in version)
KeyError: '2013e'
gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack at ChildProcess.onCpExit (c:\Bin\nodejs\node_modules\npm\node_modules\node-gyp\lib\configure.js:467:16)
gyp ERR! stack at ChildProcess.EventEmitter.emit (events.js:98:17)
gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:789:12)
gyp ERR! System Windows_NT 6.2.9200
gyp ERR! command "node" "c:\\Bin\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd c:\Users\Paul\Workspace\test\node_modules\iconv
gyp ERR! node -v v0.10.22
gyp ERR! node-gyp -v v0.11.0
gyp ERR! not ok
npm ERR! iconv@2.0.7 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the iconv@2.0.7 install script.
npm ERR! This is most likely a problem with the iconv package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get their info via:
npm ERR! npm owner ls iconv
npm ERR! There is likely additional logging output above.
npm ERR! System Windows_NT 6.2.9200
npm ERR! command "c:\\Bin\\nodejs\\node.exe" "c:\\Bin\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "iconv" "--msvs_version=2013e"
npm ERR! cwd c:\Users\Paul\Workspace\test
npm ERR! node -v v0.10.22
npm ERR! npm -v 1.3.14
npm ERR! code ELIFECYCLE
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! c:\Users\Paul\Workspace\test\npm-debug.log
npm ERR! not ok code 0
Your copy of npm is too old, you need at least v1.3.15. That's the npm that ships with node v0.10.23.
Works, thanks!
@bnoordhuis This worked for me thanks!
@bnoordhuis works like a gem (no pun)
Hey! I just want to tell you, I'm running a Win8-64 with just visual studio 2013 Ultimate installed, and when I try to use iconv (npm install iconv) I getting the following error:
Hope you can check that...
Thanks for all