Search code examples
node-gyp

node-gyp troubles with installation


I'm trying to install webworker-threads, a node addon that requires gyp. I followed the gyp instructions for setup, so far I'm still getting an error when trying to "rebuild":

C:\Program Files\nodejs\node_modules\webworker-threads>node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\....\node_modules\node-gyp\bin\node-gyp.js" rebuild
gyp ERR! configure error
gyp ERR! stack Error: spawn ENOENT
gyp ERR! stack at errnoException (child_process.js:980:11)
gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:771:34)
gyp ERR! System Windows_NT 6.1.7601
gyp ERR! command "node" "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js" "rebuild"
gyp ERR! cwd C:\Program Files\nodejs\node_modules\webworker-threads
gyp ERR! node -v v0.10.8
gyp ERR! node-gyp -v v0.9.5
gyp ERR! not ok
npm ERR! weird error 1
npm ERR! not ok code 0

I'm on a Windows 7 32 bit system. Sooo to spare some time here's my personal checklist:

Paths: node is in both user and system path. npm is in user path. Python path is set too.

  • Python: 2.7.3 installed at C:\Python27
  • VisualStudio C++ 2010 AND 2012 Express installed
  • node version v0.10.8
  • ran everything with administrator privileges
  • Commands executed: npm install -g node-gyp
  • npm install webworker-threads
  • Then the error appears.

Do you guys by any chance notice something I'm doing wrong?

Thanks a lot in advance for your guidance!


Solution

  • try npm install –msvs_version=2012. This command will ask NPM to use visual studio 2012 to build.

    http://www.kevgriffin.com/specifying-visual-studio-version-in-npm-installs/