From ea3409455e657754183779bdfff62e0ce288ddde Mon Sep 17 00:00:00 2001 From: Sergiu Deitsch Date: Thu, 21 Dec 2023 22:26:02 +0100 Subject: [PATCH] cmake: remove pre C++11 warning options --- CMakeLists.txt | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 845037e65..7729bfbd3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -15,7 +15,6 @@ set (CPACK_PACKAGE_VERSION ${PROJECT_VERSION}) list (APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake) -include (CheckCXXCompilerFlag) include (CheckCXXSourceCompiles) include (CheckCXXSourceRuns) include (CheckCXXSymbolExists) @@ -132,16 +131,6 @@ check_cxx_symbol_exists (backtrace_symbols execinfo.h HAVE_EXECINFO_BACKTRACE_SYMBOLS) check_cxx_symbol_exists (_chsize_s io.h HAVE__CHSIZE_S) -# NOTE gcc does not fail if you pass a non-existent -Wno-* option as an -# argument. However, it will happily fail if you pass the corresponding -W* -# option. So, we check whether options that disable warnings exist by testing -# the availability of the corresponding option that enables the warning. This -# eliminates the need to check for compiler for several (mainly Clang) options. - -check_cxx_compiler_flag (-Wdeprecated HAVE_NO_DEPRECATED) -check_cxx_compiler_flag (-Wunnamed-type-template-args - HAVE_NO_UNNAMED_TYPE_TEMPLATE_ARGS) - cmake_push_check_state (RESET) set (CMAKE_REQUIRED_DEFINITIONS -D_XOPEN_SOURCE=500) @@ -399,8 +388,6 @@ configure_file (src/glog/raw_logging.h.in glog/raw_logging.h @ONLY) configure_file (src/glog/stl_logging.h.in glog/stl_logging.h @ONLY) configure_file (src/glog/vlog_is_on.h.in glog/vlog_is_on.h @ONLY) -add_compile_options ($<$,$>>:-Wno-unnamed-type-template-args>) - set (_glog_CMake_BINDIR ${CMAKE_INSTALL_BINDIR}) set (_glog_CMake_INCLUDE_DIR ${CMAKE_INSTALL_INCLUDEDIR}) set (_glog_CMake_LIBDIR ${CMAKE_INSTALL_LIBDIR}) @@ -640,11 +627,6 @@ if (BUILD_TESTING) target_link_libraries (stl_logging_unittest PRIVATE glog_test) - if (HAVE_NO_DEPRECATED) - set_property (TARGET stl_logging_unittest APPEND PROPERTY COMPILE_OPTIONS - -Wno-deprecated) - endif (HAVE_NO_DEPRECATED) - if (HAVE_SYMBOLIZE) add_executable (symbolize_unittest src/symbolize_unittest.cc