首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >安装风帆时致命错误- Windows 7上的mongo

安装风帆时致命错误- Windows 7上的mongo
EN

Stack Overflow用户
提问于 2014-02-16 04:04:21
回答 2查看 730关注 0票数 2

我正在尝试安装https://www.npmjs.org/package/sails-mongo,它得到的是0.9.6,而不是0.9.7 (最新版本)。我在Windows 7上有最新的node.js (0.10.25 64位)mongodb (2.4.9 64位)

C:\my_project\backend>npm install sails-mongo

不管怎样,我发现了致命的错误:

代码语言:javascript
复制
npm http GET https://registry.npmjs.org/sails-mongo/0.9.6
npm http 304 https://registry.npmjs.org/sails-mongo/0.9.6
npm http GET https://registry.npmjs.org/underscore/1.4.4
npm http GET https://registry.npmjs.org/underscore.string/2.3.1
npm http GET https://registry.npmjs.org/async/0.2.9
npm http GET https://registry.npmjs.org/mongodb
npm http 304 https://registry.npmjs.org/underscore/1.4.4
npm http 304 https://registry.npmjs.org/underscore.string/2.3.1
npm http 304 https://registry.npmjs.org/async/0.2.9
npm http 304 https://registry.npmjs.org/mongodb
npm http GET https://registry.npmjs.org/bson/0.2.5
npm http GET https://registry.npmjs.org/kerberos/0.0.3
npm http 304 https://registry.npmjs.org/bson/0.2.5
npm http 304 https://registry.npmjs.org/kerberos/0.0.3

> kerberos@0.0.3 install C:\my_project\backend\node_modules\sails-mongo\node_modules\m
ongodb\node_modules\kerberos
> (node-gyp rebuild 2> builderror.log) || (exit 0)


C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\node_modules\kerbe
ros>node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\\..\..\node_
modules\node-gyp\bin\node-gyp.js" rebuild
  kerberos.cc
  worker.cc
  security_credentials.cc
  security_buffer.cc
  security_buffer_descriptor.cc
  security_context.cc
C:\Users\myname\.node-gyp\0.10.25\deps\v8\include\v8.h(179): warning C4506: no
 definition for inline function 'v8::Persistent<T> v8::Persistent<T>::New(v8::H
andle<T>)' [C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\node_
modules\kerberos\build\kerberos.vcxproj]
          with
          [
              T=v8::Object
          ]
C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\xlocale(323): wa
rning C4530: C++ exception handler used, but unwind semantics are not enabled.
Specify /EHsc [C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\no
de_modules\kerberos\build\kerberos.vcxproj]
C:\Users\myname\.node-gyp\0.10.25\deps\v8\include\v8.h(184): warning C4506: no
 definition for inline function 'v8::Persistent<T> v8::Persistent<T>::New(v8::H
andle<T>)' [C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\node_
modules\kerberos\build\kerberos.vcxproj]
          with
          [
              T=v8::Object
          ]
C:\Users\myname\.node-gyp\0.10.25\deps\v8\include\v8.h(184): warning C4506: no
 definition for inline function 'v8::Persistent<T> v8::Persistent<T>::New(v8::H
andle<T>)' [C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\node_
modules\kerberos\build\kerberos.vcxproj]
          with
          [
              T=v8::FunctionTemplate
          ]
C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\xlocale(323): wa
rning C4530: C++ exception handler used, but unwind semantics are not enabled.
Specify /EHsc [C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\no
de_modules\kerberos\build\kerberos.vcxproj]
C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\xlocale(323): wa
rning C4530: C++ exception handler used, but unwind semantics are not enabled.
Specify /EHsc [C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\no
de_modules\kerberos\build\kerberos.vcxproj]
C:\Users\myname\.node-gyp\0.10.25\deps\v8\include\v8.h(179): warning C4506: no
 definition for inline function 'v8::Persistent<T> v8::Persistent<T>::New(v8::H
andle<T>)' [C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\node_
modules\kerberos\build\kerberos.vcxproj]
          with
          [
              T=v8::Object
          ]
C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\xlocale(323): wa
rning C4530: C++ exception handler used, but unwind semantics are not enabled.
Specify /EHsc [C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\no
de_modules\kerberos\build\kerberos.vcxproj]
C:\Users\myname\.node-gyp\0.10.25\deps\v8\include\v8.h(179): warning C4506: no
 definition for inline function 'v8::Persistent<T> v8::Persistent<T>::New(v8::H
andle<T>)' [C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\node_
modules\kerberos\build\kerberos.vcxproj]
          with
          [
              T=v8::FunctionTemplate
          ]
C:\Users\myname\.node-gyp\0.10.25\deps\v8\include\v8.h(218): warning C4506: no
 definition for inline function 'v8::Persistent<T> v8::Persistent<T>::New(v8::H
andle<T>)' [C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\node_
modules\kerberos\build\kerberos.vcxproj]
          with
          [
              T=v8::Object
          ]
C:\Users\myname\.node-gyp\0.10.25\deps\v8\include\v8.h(218): warning C4506: no
 definition for inline function 'v8::Persistent<T> v8::Persistent<T>::New(v8::H
andle<T>)' [C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\node_
modules\kerberos\build\kerberos.vcxproj]
          with
          [
              T=v8::FunctionTemplate
          ]
C:\Users\myname\.node-gyp\0.10.25\deps\v8\include\v8.h(218): warning C4506: no
 definition for inline function 'v8::Persistent<T> v8::Persistent<T>::New(v8::H
andle<T>)' [C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\node_
modules\kerberos\build\kerberos.vcxproj]
          with
          [
              T=v8::Object
          ]
C:\Users\myname\.node-gyp\0.10.25\deps\v8\include\v8.h(218): warning C4506: no
 definition for inline function 'v8::Persistent<T> v8::Persistent<T>::New(v8::H
andle<T>)' [C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\node_
modules\kerberos\build\kerberos.vcxproj]
          with
          [
              T=v8::FunctionTemplate
          ]
C:\Users\myname\.node-gyp\0.10.25\deps\v8\include\v8.h(179): warning C4506: no
 definition for inline function 'v8::Persistent<T> v8::Persistent<T>::New(v8::H
andle<T>)' [C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\node_
modules\kerberos\build\kerberos.vcxproj]
          with
          [
              T=v8::Object
          ]
C:\Users\myname\.node-gyp\0.10.25\deps\v8\include\v8.h(179): warning C4506: no
 definition for inline function 'v8::Persistent<T> v8::Persistent<T>::New(v8::H
andle<T>)' [C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\node_
modules\kerberos\build\kerberos.vcxproj]
          with
          [
              T=v8::FunctionTemplate
          ]
  kerberos_sspi.c
  base64.c
LINK : fatal error LNK1181: cannot open input file 'kernel32.lib' [C:\my_project\back
end\node_modules\sails-mongo\node_modules\mongodb\node_modules\kerberos\build\k
erberos.vcxproj]

> bson@0.2.5 install C:\my_project\backend\node_modules\sails-mongo\node_modules\mongo
db\node_modules\bson
> (node-gyp rebuild 2> builderror.log) || (exit 0)


C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\node_modules\bson>
node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\\..\..\node_modu
les\node-gyp\bin\node-gyp.js" rebuild
  bson.cc
C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\xlocale(323): wa
rning C4530: C++ exception handler used, but unwind semantics are not enabled.
Specify /EHsc [C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\no
de_modules\bson\build\bson.vcxproj]
C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\intrin.h(26): fa
tal error C1083: Cannot open include file: 'ammintrin.h': No such file or direc
tory [C:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\node_module
s\bson\build\bson.vcxproj]
sails-mongo@0.9.6 node_modules\sails-mongo
├── async@0.2.9
├── underscore@1.4.4
├── underscore.string@2.3.1
└── mongodb@1.3.23 (kerberos@0.0.3, bson@0.2.5)

这是为了让你更容易:

代码语言:javascript
复制
LINK : fatal error LNK1181: cannot open input file 'kernel32.lib' [C:\my_project\back
end\node_modules\sails-mongo\node_modules\mongodb\node_modules\kerberos\build\k
erberos.vcxproj]

知道为什么吗?以及如何解决这个问题?

更新1:

我遵循这篇文章singh/archive/2009/01/30/getting-fatal-error-lnk1181-cannot-open-input-file-kernel32-lib.aspx,它似乎修复了一个问题,现在我得到了不同的错误:

代码语言:javascript
复制
npm http GET https://registry.npmjs.org/sails-mongo/0.9.6
npm http 304 https://registry.npmjs.org/sails-mongo/0.9.6
npm http GET https://registry.npmjs.org/async/0.2.9
npm http GET https://registry.npmjs.org/underscore/1.4.4
npm http GET https://registry.npmjs.org/underscore.string/2.3.1
npm http GET https://registry.npmjs.org/mongodb
npm http 304 https://registry.npmjs.org/async/0.2.9
npm http 304 https://registry.npmjs.org/underscore/1.4.4
npm http 304 https://registry.npmjs.org/mongodb
npm http 304 https://registry.npmjs.org/underscore.string/2.3.1
npm http GET https://registry.npmjs.org/bson/0.2.5
npm http 304 https://registry.npmjs.org/bson/0.2.5

> bson@0.2.5 install c:\my_project\backend\node_modules\sails-mongo\node_modules\mongo
db\node_modules\bson
> (node-gyp rebuild 2> builderror.log) || (exit 0)


c:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\node_modules\bson>
node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\\..\..\node_modu
les\node-gyp\bin\node-gyp.js" rebuild
Building the projects in this solution one at a time. To enable parallel build,
please add the "/m" switch.
  bson.cc
c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\xlocale(323): wa
rning C4530: C++ exception handler used, but unwind semantics are not enabled.
Specify /EHsc [c:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\no
de_modules\bson\build\bson.vcxproj]
c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\intrin.h(26): fa
tal error C1083: Cannot open include file: 'ammintrin.h': No such file or direc
tory [c:\my_project\backend\node_modules\sails-mongo\node_modules\mongodb\node_module
s\bson\build\bson.vcxproj]
sails-mongo@0.9.6 node_modules\sails-mongo
├── underscore@1.4.4
├── async@0.2.9
├── underscore.string@2.3.1
└── mongodb@1.3.23 (bson@0.2.5)
EN

回答 2

Stack Overflow用户

发布于 2014-02-18 20:42:53

kerberos需要蟒蛇。安装python for Windows并添加到环境变量中。

票数 2
EN

Stack Overflow用户

发布于 2015-04-29 10:16:42

您是否检查了是否使用了正确的软件版本?

如果使用64位操作系统,则必须安装64位版本的Node.js(x64)。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/21807142

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档