Merge pull request #19344 from tchaikov/wip-we-need-cxx11-and-more

cmake: bail out if GCC version is less than 5.1

Reviewed-by: Sage Weil <sage@redhat.com>
This commit is contained in:
Kefu Chai 2017-12-06 22:11:17 +08:00 committed by GitHub
commit ef7359d4e2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -173,7 +173,9 @@ if(CMAKE_COMPILER_IS_GNUCXX AND
# use old gcc with new libstdc++, but it covers the most cases.
#
# libstdc++ 4.9 has O(n) list::size(), and its regex is buggy
message(WARNING "performance regression is expected due to an O(n) implementation of 'std::list::size()' in libstdc++ older than 5.1.0")
message(SEND_ERROR "performance regression is expected due to an O(n) "
"implementation of 'std::list::size()' in libstdc++ older than 5.1.0, "
"Please use GCC 5.1 and up.")
endif()
## Handle diagnostics color if compiler supports them.