cmake: remove checking for GCC 5.1

this reverts bcc0511d3b,

because

* we already check for C++17 support in the same cmake list
* it's non trivial to check the O(1) std::list::size().
* we always build using the GCC 7.3 from SCLs on CentOS and RHEL. so the
  error message is always printed if we could have detected the O(1)
  std::list::size(). and we cannot fail the build if we are using an
  standard library with O(1) std::list::size().

so, this check is pointless.

Signed-off-by: Kefu Chai <kchai@redhat.com>
This commit is contained in:
Kefu Chai 2018-10-08 23:32:18 +08:00
parent fb1a75c6c1
commit d6072b9571

View File

@ -138,17 +138,6 @@ int main() {
}
" HAVE_STDLIB_MAP_SPLICING)
if(CMAKE_COMPILER_IS_GNUCXX AND
CMAKE_CXX_COMPILER_VERSION VERSION_LESS 5.1)
# this is not always correct, as one can use clang with libstdc++ or
# 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(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.
CHECK_C_COMPILER_FLAG("-fdiagnostics-color=always"
COMPILER_SUPPORTS_DIAGNOSTICS_COLOR)