Build fail - windows 7 - npm install mogodb

1,287 views
Skip to first unread message

Roger Tremblay

unread,
Aug 29, 2013, 10:19:30 AM8/29/13
to nod...@googlegroups.com
Hey there, pretty new to node and even newer to mongodb but loving it so far.
 
I had a hell of a night trying to get around two build errors last night while trying to install mongodb. I don't have my errors to paste but these are the exact ones I was getting only in my environment:
 
$ npm install mongodb
npm http GET https://registry.npmjs.org/mongodb
npm http 304 https://registry.npmjs.org/mongodb
npm http GET https://registry.npmjs.org/bson/0.1.9
npm http GET https://registry.npmjs.org/kerberos
npm http 304 https://registry.npmjs.org/bson/0.1.9
npm http 304 https://registry.npmjs.org/kerberos

> kerberos@0.0.2 install c:\Users\Ludicritz\Desktop\Umass-running-app\node_modules\mongodb\node_modules\kerberos
> (node-gyp rebuild 2> builderror.log) || (exit 0)


c:\Users\Ludicritz\Desktop\Umass-running-app\node_modules\mongodb\node_modules\kerberos>node "c:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bi
n\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild

> bson@0.1.9 install c:\Users\Ludicritz\Desktop\Umass-running-app\node_modules\mongodb\node_modules\bson
> (node-gyp rebuild 2> builderror.log) || (exit 0)


c:\Users\Ludicritz\Desktop\Umass-running-app\node_modules\mongodb\node_modules\bson>node "c:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\\.
.\..\node_modules\node-gyp\bin\node-gyp.js" rebuild
C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\Microsoft.Cpp.InvalidPlatform.Targets(23,7): error MSB8007: The Platform for project 'kerberos.vcxp
roj' is invalid.  Platform='x64'. You may be seeing this message because you are trying to build a project without a solution file, and have specifie
d a non-default Platform that doesn't exist for this project. [c:\Users\Ludicritz\Desktop\Umass-running-app\node_modules\mongodb\node_modules\kerbero
s\build\kerberos.vcxproj]
C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\Microsoft.Cpp.InvalidPlatform.Targets(23,7): error MSB8007: The Platform for project 'bson.vcxproj'
 is invalid.  Platform='x64'. You may be seeing this message because you are trying to build a project without a solution file, and have specified a
non-default Platform that doesn't exist for this project. [c:\Users\Ludicritz\Desktop\Umass-running-app\node_modules\mongodb\node_modules\bson\build\
bson.vcxproj]
mongodb@1.3.9 node_modules\mongodb
├── kerberos@0.0.2
└── bson@0.1.9
 
I searched high and low and anything suggested failed for me. Any chance someone there is someone out there that can help be solve this? I was able to code with what installed but the builds are broken and I'm guessing I'll need what's broken if it's a dependency.
 
Help and thanks!
 
Roger 

Jeroen Janssen

unread,
Aug 29, 2013, 3:25:26 PM8/29/13
to nod...@googlegroups.com
Hi,

So it seems it fails while trying to actually build 64bit native modules.
Building (native) modules is done through node-gyp: https://github.com/TooTallNate/node-gyp

Since you are getting a failure about x64 I am assuming that you are actually running on a 64bit machine?
If so, can you verify that you have installed the items listed on the node-gyp page related to Windows 7 64-bit building and try again?

Hopefully that will solve your problem.

Best regards,

Jeroen Janssen

Op donderdag 29 augustus 2013 16:19:30 UTC+2 schreef Roger Tremblay:
└── bs...@0.1.9

Roger Tremblay

unread,
Aug 30, 2013, 10:55:27 AM8/30/13
to nod...@googlegroups.com
Thanks Jeroen, I thought I did have all that was required but will double check. Many thanks!
 
Roger Tremblay

Glenn Block

unread,
Sep 1, 2013, 2:42:07 PM9/1/13
to nod...@googlegroups.com
Hi Roger

It should still work as "kerberos" is an optional dependency: https://github.com/mongodb/node-mongodb-native/blob/master/package.json#L79. Admittedly the npm output doesn't make it clear that the module can still function "mongodb" because it's an optional dependency.

As Jeroen said you need to have the right setup for native modules to work today for windows i.e. python and the right version of VS Express / VS installed.

On the plus side I can say we are working on a better story and very soon "mongodb" should just work on windows without requiring to build anything.


--
--
Job Board: http://jobs.nodejs.org/
Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to nod...@googlegroups.com
To unsubscribe from this group, send email to
nodejs+un...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en
 
---
You received this message because you are subscribed to the Google Groups "nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nodejs+un...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Roger Tremblay

unread,
Sep 1, 2013, 2:54:40 PM9/1/13
to nod...@googlegroups.com
Hey Gelnn,

Thanks a bunch for the feedback. I've been developing with mongodb as is and it's been working fine, was just trying to get everything built as it should be but this works for what I need.

Cheers and thanks again :)

Roger


You received this message because you are subscribed to a topic in the Google Groups "nodejs" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/nodejs/N9ujUD5Ahz8/unsubscribe.
To unsubscribe from this group and all its topics, send an email to nodejs+un...@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.



--
Roger Tremblay
kra...@gmail.com
Reply all
Reply to author
Forward
0 new messages