I tried to install xml2json package for node.js but it gives me error.
Error are as below :
My system configuration are as below :
node.js version - v5.4.1
npm version - 3.3.12
Operating system - windows 10 64 bit
python - 2.7.11(set as environment variable )
After installing microsoft windows sdk v7.1 it gives me below error.
After added package.json below error is given.
You have to explicitly specify the Platform Toolset when building with msbuild ( triggered by node-gyp rebuild
) . Try command below, prior running npm
:
call "C:\Program Files\Microsoft SDKs\Windows\v7.1\bin\Setenv.cmd" /Release /x64
See meaning of passed arguments below, from SetEnv.cmd Usage:
/Release - Create a Release configuration build environment
/x64 - Create 64-bit x64 applications
Additional explanations
npm install xml2json
require using Windows SDK under the hood to build projects, while installing packages, with MSBuild. You have faced situation that your Windows SDK configuration isn't compatible with required by node
.
Configuring the Windows SDK Command Prompt Window section:
If you do not have Visual Studio 2010, you can use the Windows SDK Command Prompt window and the SetEnv utility to configure your application build settings.
So my suggestion is to use SetEnv utility to fix your problem ...
Other ways to fix problem
MSBuild uses VCTargetsPath property, which cannot be located because the registry lacks this key.
Check whether key exists and points to proper path
if key doesn't exists or has wrong value, fix problem with steps below:
WinSDKVersion == v4.0 (Looks like that's value of Your WinSDK Version), so replace WinSDKVersion to v4.0.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With