[SERVER-22017] Mongodb 3.0.8 still does not compile on CentOS7/RHEL7 Created: 27/Dec/15 Updated: 14/Apr/16 Resolved: 08/Jan/16 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Portability, Stability |
| Affects Version/s: | 3.0.5 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Stream PP | Assignee: | Andrew Morrow (Inactive) |
| Resolution: | Incomplete | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Operating System: | ALL | ||||||||
| Steps To Reproduce: | scons all \ |
||||||||
| Sprint: | Platforms E (01/08/16) | ||||||||
| Participants: | |||||||||
| Description |
|
MongoDB stopped to compile in 3.0.4 version. I have fresh CentOS 7.2 installation:
And I have following error while build process:
What am I doing wrong? |
| Comments |
| Comment by Andrew Morrow (Inactive) [ 08/Jan/16 ] |
|
Hi streampp - I'm closing this ticket since I haven't heard back from you. Please feel free to re-open it or comment in the ticket if you need further help. |
| Comment by Andrew Morrow (Inactive) [ 05/Jan/16 ] |
|
streampp - Just checking back in on this ticket. Were you able to get a working build? |
| Comment by Andrew Morrow (Inactive) [ 28/Dec/15 ] |
|
You would build with boost by not building with the --use-system-all flag, and then the bundled version of boost will be used. Unless there is a very good reason to do so, I'd discourage you from using any system version of a C++ language library due to ABI issues like the one you encountered. MongoDB is really designed to be built against the bundled copies of all of the libraries under third_party. |
| Comment by Stream PP [ 28/Dec/15 ] |
|
Hello Andrew, thanks for quick answer. Can you, please, tell me how can I build MongoDB with bundled boost? — a/src/mongo/shell/shell_utils_extended.cpp.orig 2015-12-27 03:31:50.352742000 +0300 #include "mongo/platform/basic.h" +#define BOOST_NO_CXX11_SCOPED_ENUMS — a/src/mongo/shell/shell_utils_launcher.cpp.orig 2015-12-27 18:59:19.720628574 +0300 #define MONGO_LOG_DEFAULT_COMPONENT ::mongo::logger::LogComponent::kDefault #include "mongo/platform/basic.h" — a/src/mongo/db/storage/mmap_v1/repair_database.cpp.orig 2015-12-27 19:12:45.242628574 +0300 #include "mongo/db/storage/mmap_v1/mmap_v1_engine.h" +#define BOOST_NO_CXX11_SCOPED_ENUMS |
| Comment by Andrew Morrow (Inactive) [ 28/Dec/15 ] |
|
I notice that you are building with --use-system-all. This is unlikely to work as you intend. MongoDB 3.0.8 builds with the --std=c++11 flag, but the system boost may or may not be built this way. Our recommendation is to not build with --use-system-all and instead use the bundled third_party libraries. However. to make sure we understand the issue fully, could you please confirm the following:
I strongly suspect that filesystem::copy_option is not ABI stable when mixing C++03 and C++11 builds due to the presence of the BOOST_SCOPED_ENUM macro in its declaration. |