[SERVER-4304] Add Visual Studio pre-build steps so we can eliminate mongo_vstudio.cpp Created: 17/Nov/11 Updated: 11/Jul/16 Resolved: 20/Nov/11 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Build |
| Affects Version/s: | None |
| Fix Version/s: | 2.1.0 |
| Type: | Improvement | Priority: | Trivial - P5 |
| Reporter: | Tad Marshall | Assignee: | Tad Marshall |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
Used by Windows Visual Studio, but affects the SCons build and commands like "git status" on all platforms |
||
| Participants: |
| Description |
|
SConstruct has code to create .cpp code based on JavaScript source files, but the Visual Studio build projects don't have a matching feature. The workaround of having SConstruct create a mongo_vstudio.cpp file is kind of clumsy. We can simplify things a little by adding a pre-build step to the Visual Studio solution/project files to do what the jsToH routine in Sconstruct does and then drop mongo_vstudio.cpp from the repository. |
| Comments |
| Comment by Tad Marshall [ 20/Nov/11 ] |
|
Fixed by commit c67b01be01ee3c7ef84f57834380f287d83ebf61. |
| Comment by auto [ 20/Nov/11 ] |
|
Author: {u'login': u'', u'name': u'Tad Marshall', u'email': u'tad@10gen.com'}Message: We no longer need mongo_vstudio.cpp and it is removed from the Git |
| Comment by Tad Marshall [ 19/Nov/11 ] |
|
The other problem with the way we've been doing this is that there are two generated .CPP files (shell/mongo.cpp and shell/mongo-server.cpp) but only one of them (mongo.cpp -> mongo_vstudio.cpp) is stored in Git. This means that Visual Studio builders can't build mongo.exe without running SCons at least once, because the file mongo-server.cpp doesn't exist until SCons creates it. This also means that if shell/servers.js is updated, the Visual Studio builder has to run SCons again to update mongo-server.cpp, otherwise the old version will be used and the update will not show up in the Visual Studio build. |