2013-09-16 132 views
1

我想从node.js的连接上的Windows8的MSSQL但我不能得到它的工作:(的node.js:建筑msnodesql失败

,如果我跑node-gyp configure build

我得到这个错误

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:\Users\mkirchweger\AppData\Roaming\ 
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.2.9200 
gyp ERR! command "node" "C:\\Users\\mkirchweger\\AppData\\Roaming\\npm\\node_mod 
ules\\node-gyp\\bin\\node-gyp.js" "configure" "build" 
gyp ERR! cwd D:\Bibliotheken\node_test\node_modules\msnodesql 
gyp ERR! node -v v0.10.18 
gyp ERR! node-gyp -v v0.10.10 
gyp ERR! not ok 

如果我试图当然没有构建运行我的node.js应用程序,我得到的消息

Error: Cannot find module '../build/Release/sqlserver.node' 

回答

1

我应该说,node.js模块“Node-sqlserver”已重命名为“MSNodeSQL”。

我能够在https://github.com/WindowsAzure/node-sqlserver/tree/master/src

在上面的链接找到要去模块github上所要求的变化,变化Operation.h

变化概述了从(38行):

int result = uv_queue_work(uv_default_loop(), &operation->work, OnBackground, OnForeground); 

要:

int result = uv_queue_work(uv_default_loop(), &operation->work, OnBackground, (uv_after_work_cb)OnForeground); 

我希望这答案就足够了。