Gyp ERR! stack Error: `C: \ Program Files (x86) \ MSBuild \ 12.0 \ bin \ msbuild.exe` failed with exit code: 1

When I do npm install, I encounter the following error. I can not find the problem.

I need help finding this problem.

d:\testing\node-sample-module\node_modules\ffi\node_modules\ref\node_modules\nan\nan_implementation_pre_12_inl.h(112): error C2668: 'v8::FunctionTemplate::New' :  ambiguous call to overloaded function [d:\TESTING\node-sample-module\node_modules \ffi\node_modules\ref\build\binding.vcxproj]
C:\Users\SELVA\.nw-gyp\0.8.5\deps\v8\include\v8.h(3344): could be 'v8::Local<v8::FunctionTemplate> v8::FunctionTemplate::New(v8::FunctionCallback,v8::Handle<v8::Value>,v8::Handle<v8::Signature>,int)'
C:\Users\SELVA\.nw-gyp\0.8.5\deps\v8\include\v8.h(3343): or v8::Local<v8::FunctionTemplate> v8::FunctionTemplate::New(v8::InvocationCallback,v8::Handle<v8::Value>,v8::Handle<v8::Signature>,int)' while trying to match the argument list '(int, v8::Local<v8::Value>,    v8::Local<v8::Signature>)'

gyp ERR! build error
gyp ERR! stack Error: `C:\Program Files (x86)\MSBuild\12.0\bin\msbuild.exe` failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit (c:\Users\SELVA\AppData\Roaming\npm\node_modules\nw-gyp\lib\build.js:267:23)
gyp ERR! stack at ChildProcess.emit (events.js:98:17)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (child_process.js:820:12)
gyp ERR! System Windows_NT 6.1.7601
gyp ERR! command "node" "c:\\Users\\SELVA\\AppData\\Roaming\\npm\\node_modules\\nw-gyp\\bin\\nw-gyp.js" "clean" "configure" "--target=0.8.5" "build" "--arch=ia32"
gyp ERR! cwd d:\TESTING\node-sample-module\node_modules\ffi\node_modules\ref
gyp ERR! node -v v0.10.35
gyp ERR! nw-gyp -v v0.12.4
gyp ERR! not ok

FYI, I am using a Windows 7 machine.

In addition, install the following.

Distributed in C ++ 2013 (32-bit)

Python 2.7.3 (env variable set to path / python.exe)

Visual studio express 2013

.Net framework 4.5 SDK

Thanks at Advance.

+4
source share
1 answer

Update:

The new package will do it all for us now.

Make sure you have sufficient permissions at startup:

Set-ExecutionPolicy Unrestricted -Scope CurrentUser -Force

then do:

npm install -g windows-build-tools

wait for its installation and subsequent launch:

window-build-tools

.


:

, . Windows 8.1 Hyper-V, . , .

, , , , ( ), msvs_version -flag npm install - , :

npm install --msvs_version=2013

, , , , , - .

:

1) Node.js

2) git

  • CLI
  • " Git Unix Windows

    • git-add-to-path

3) npm npm 3.x.x ( )

Node.js, , npm 3.

  • CLI
  • npm install -g npm-windows-upgrade .
  • Set-ExecutionPolicy Unrestricted -Scope CurrentUser -Force
  • npm-windows-upgrade
  • npm --version , - 3.x.x

4) Python 2.7.x

5) Visual Studio Express 2013 Windows Desktop 4

Visual Studio, , .

npm install --msvs_version=2013, node -gyp throwing.

+13

Source: https://habr.com/ru/post/1610369/


All Articles