From: Kefu Chai Date: Mon, 8 Oct 2018 15:32:18 +0000 (+0800) Subject: cmake: remove checking for GCC 5.1 X-Git-Tag: v14.0.1~101^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F24477%2Fhead;p=ceph.git cmake: remove checking for GCC 5.1 this reverts bcc0511d3b857a8810493ca3d3f17ba053651af2, 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 --- diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 874eabfaa13a..f12e6db8642c 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -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)