[SERVER-10066] globals.h(127) Unexpected end-of-file found when building with MSVC2012 Created: 01/Jul/13 Updated: 11/Jul/16 Resolved: 29/Jul/13 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Build |
| Affects Version/s: | 2.4.4 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Critical - P2 |
| Reporter: | Raul Guerrero | Assignee: | Unassigned |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
Windows 7 x64 with MSVC 2012 and Boost 1.4.2 |
||
| Operating System: | Windows |
| Steps To Reproduce: | Go into the mongodb source code folder and run: scons --64 |
| Participants: |
| Description |
|
When trying to build MongoDB 2.4.4 with the MSVC 2012 compiler and using Boost 1.4.2, I get the following error: c:\mongodb-src-r2.4.4\src\third_party\v8\src\globals.h(127) : fatal error C1004: unexpected end-of-file found |
| Comments |
| Comment by Stennie Steneker (Inactive) [ 29/Jul/13 ] |
|
Hi Raul, Since we haven't heard anything further from you on this issue in a few weeks, I'm going to close the issue. I would also note that the SERVER project is for reporting bugs or feature suggestions for the MongoDB server. For MongoDB-related support discussion please post on the mongodb-users group (http://groups.google.com/group/mongodb-user). Thanks, |
| Comment by Tad Marshall [ 14/Jul/13 ] |
|
I suspect that you somehow have a corrupted file (src\third_party\v8\src\globals.h) and perhaps this isn't the only one. Can you check at least this file and see if it has 405 lines? The file is supposed to look like this (for version 2.4.4): https://github.com/mongodb/mongo/blob/r2.4.4/src/third_party/v8/src/globals.h . You might want to re-clone the mongodb code (git clone https://github.com/mongodb/mongo.git) into a new directory (followed by "git checkout r2.4.4" if you want to use version 2.4.4 specifically) and compare contents with your existing directory or just try building again in the new directory. From the excerpt you showed above, it looks like you have the prerequisites: Python, scons and the Visual Studio compiler. The versions that I use are Python 2.7.3, scons 2.1.0 and Visual Studio Professional 2010 SP1 with all WindowsUpdate patches applied. To build all MongoDB executables with scons, you should be able to build with a command line like "scons --64 --dd all" to build a full debug version or "scons --64 --release all" to build an optimized version. We have ongoing work to make the C++ driver easier to work with on all platforms, and to address some specific issues on Windows. For example, see |
| Comment by Raul Guerrero [ 14/Jul/13 ] |
|
Hi Tad, Thanks for the response. I meant Boost 1.42 as a tutorial shows that some guy built it with no issues, but I didn't know that mongodb source came with boost, and as there is no tutorial or anything whatsoever for building mongodb in windows (i mean a full step by step from what needs to be installed up to scons build) and I installed and build boost in my PC because even if mongo builds its boost, I still need boost to use the mongodb client driver in my program, as tutorials ask for shared pointers and other boost stuff. So, maybe you could tell me please how am I supposed to build mongodb on windows? and what I need to have installed with their correspondent versions. And I used the full mongodb source, not the tarball as it's known to not build on windows, I only use the tarball for mac. Thanks |
| Comment by Tad Marshall [ 14/Jul/13 ] |
|
I'm confused by your Boost reference. Do you mean Boost version 1.42? The 2.4.4 MongoDB source code tree includes Boost version 1.49, or the portions of Boost that are used by MongoDB. Your command "scons --64" should be using the version of Boost in the source tree unless you have replaced it somehow. My copy of src\third_party\v8\src\globals.h has 405 lines; I'm not sure why you would hit end-of-file at line 127. Can you verify that this file is correct and not truncated somehow? Is this source code from a source tarball or from running "git clone" against the github repository? Can you post a full log from a clean build? We are currently using Visual Studio 2010 as our Windows compiler for MongoDB, but sporadic testing against VS2012 has shown no issues. |