Installation on nodej.js pg module issue (Cannot open include file: 'pg_config.h')

While installing the pg module on Windows I can to this problem:

c:\Program Files (x86)\nodejs\node_modules\pg>node "c:\Program Files (x86)\nodejs\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node
  -gyp\bin\node-gyp.js" rebuild
  ..\src\ fatal error C1083: Cannot open include file: 'pg_config.h': No such file or directory [c:\Program Files (x86)\nodejs\
  gyp ERR! build error
  gyp ERR! stack Error: `C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe` failed with exit code: 1
  gyp ERR! stack     at ChildProcess.onExit (c:\Program Files (x86)\nodejs\node_modules\npm\node_modules\node-gyp\lib\build.js:267:23)
  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 (x86)\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
  gyp ERR! cwd c:\Program Files (x86)\nodejs\node_modules\pg
  gyp ERR! node -v v0.10.24
  gyp ERR! node-gyp -v v0.12.1
  gyp ERR! not ok
  pg@2.11.1 node_modules\pg
  ├── nan@0.6.0
  ├── generic-pool@2.0.3
  ├── buffer-writer@1.0.0
  └── pgpass@0.0.1 (split@0.2.10)


My environment:

win - 8.1
vs - 2012
pg - 9.3
nodejs - 0.10.29
npm - 1.4.14

pg path "D:\Program Files\PostgreSQL\9.3\bin" has been manually added into the system env var "PATH".

I got the same error, and noticed the path in the \pg\build\binding.vcxproj file was D:\Program;..\Files\PostgreSQL\9.3\include\;...

so the space in the pg path could be the problem. After changed the pg install path, problem solved.

Need Your Help

Update with last known location?

sql postgresql timestamp geometry postgis

I have a large table of data which has about 75,000 people's locations

Deploying spark-jobserver to BlueMix Spark Node

apache-spark docker ibm-cloud spark-jobserver

I'm trying to deploy and connect instance of spark-jobserver in a docker container to BlueMix Spark service. Locally, container start perfectly with a command docker -d -p 8090:8090 {image-name}, b...