commit c26db650a1e93573e4c09d4612ad45ae1e219854
Author: Kornel Benko <[email protected]>
Date: Wed Sep 29 17:53:50 2021 +0200
Cmake build: Fix the invalid test for '-Wno-deprecated-copy' flag
The original test was always successfull, even if the flag was invalid.
But checking for '-Wdeprecated-copy' instead yields to error if the warning
does not exist.
Existent warning for 'deprecated-copy' implies that 'no-deprecated-copy'
also exist.
---
CMakeLists.txt | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index ecebdc9..5e9c7c8 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -714,7 +714,7 @@ else()
# check_cxx_source_compiles("..." HAVE_DEF_MAKE_UNIQUE)
include(CheckCXXCompilerFlag)
unset(CHECK_WNODEPRECATEDCOPY_FLAG CACHE)
- CHECK_CXX_COMPILER_FLAG("-Wno-deprecated-copy"
CHECK_WNODEPRECATEDCOPY_FLAG)
+ CHECK_CXX_COMPILER_FLAG("-Wdeprecated-copy"
CHECK_WNODEPRECATEDCOPY_FLAG)
if(${CHECK_WNODEPRECATEDCOPY_FLAG})
set(LYX_CXX_FLAGS "-Wall -Wextra -Wno-deprecated-copy
${LYX_GCC11_MODE}${LYX_CXX_FLAGS}")
else()
--
lyx-cvs mailing list
[email protected]
http://lists.lyx.org/mailman/listinfo/lyx-cvs