serialport / node-serialport

Access serial ports with JavaScript. Linux, OSX and Windows. Welcome your robotic JavaScript overlords. Better yet, program them!
https://serialport.io
MIT License
5.82k stars 1.01k forks source link

Problems compiling with windows 7 64 bits #201

Closed sarahpy closed 11 years ago

sarahpy commented 11 years ago

I´ve installed:

  1. windows 7 64bit
  2. VS Express 2013 preview for Windows Desktop
  3. node js version 0.10.15
  4. python version 2.7.5

when i open "Visual Studio Command Prompt' and set environment varialble as follow:

set path=%path%;C:\Python27

And install serial port:

npm install serialport --msvs_version=2012

I get this error:

serialport@1.1.3 install C:\Users\cpo-wh2\Documents\GitHub\node-serialport node-gyp rebuild C:\Users\cpo-wh2\Documents\GitHub\node-serialport>node "C:\Program Files\nodejs\ node_modules\npm\bin\node-gyp-bin....\node_modules\node-gyp\bin\node-gyp.js" rebuild gyp: C:\Users\cpo-wh2.node-gyp\0.10.15\common.gypi not found (cwd: C:\Users\cpo -wh2\Documents\GitHub\node-serialport) while reading includes of binding.gyp whi le trying to load binding.gyp gyp ERR! configure error gyp ERR! stack Error: gyp failed with exit code: 1 gyp ERR! stack at ChildProcess.onCpExit (C:\Program Files\nodejs\node_module s\npm\node_modules\node-gyp\lib\configure.js:424: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.1.7601 gyp ERR! command "node" "C:\Program Files\nodejs\node_modules\npm\node_modu les\node-gyp\bin\node-gyp.js" "rebuild" gyp ERR! cwd C:\Users\cpo-wh2\Documents\GitHub\node-serialport gyp ERR! node -v v0.10.15 gyp ERR! node-gyp -v v0.10.6 gyp ERR! not ok npm ERR! weird error 1 npm ERR! not ok code 0

any suggestions?

PS. 1. I have already install node-gyp (npm install -g node-gyp)

  1. I've Install SDK
  2. I have try clone node-serial and install (git clone https://github.com/voodootikigod/node-serialport.git cd node-serialport npm install --msvs-version=2012) but the result still the same
JayBeavers commented 11 years ago

I'm not really certain what's causing it, I couldn't reproduce the problem. However it seems to be related to node-gyp. Here are a few things for you to try:

npm remove -g node-gyp

You don't need to have node-gyp installed directly, npm will do the right thing. Alternatively, update node-gyp. You are running v0.10.6 and when I attempted to reproduce it installed v0.10.9. With v0.10.9 I did not reproduce your issue.

adrai commented 11 years ago

Could this be because of https://github.com/joyent/node/issues/5947 ?

JayBeavers commented 11 years ago

I think adrai confirmed the cause. If you remove node-gyp or update, issues should be resolved.