[LyX/master] Windows: fix in CMakeLists for warning flags.

Thibaut Cuvelier tcuvelier at lyx.org
Wed Sep 2 12:39:54 UTC 2020


commit 9d8ef32d137245faccc7307dac32b2bbbdba270d
Author: Thibaut Cuvelier <tcuvelier at lyx.org>
Date:   Wed Sep 2 15:05:20 2020 +0200

    Windows: fix in CMakeLists for warning flags.
    
    /Wp64 was used to debug 64-bit incompatibilities. /W4 is used for warnings.
    
    Don't enable /Wx to turn warnings into errors, as the dependencies won't build.
---
 CMakeLists.txt |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 62eff71..d3aa192 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1072,9 +1072,9 @@ if(MSVC)
 		# add here warnings which should be disabled /wdXXXX
 		set(MSVC_W_DISABLE "/wd4288 /wd4355 /wd4800 /wd4996 /wd4311 /wd4312 /wd4505 /wd4267 /wd4512 /wd4245 /wd4127 /wd4180 /wd4231")
 
-		set(CMAKE_CXX_FLAGS_DEBUG      "${CMAKE_CXX_FLAGS_DEBUG} /Wp64 ${MSVC_W_ERROR} ${MSVC_W_DISABLE}")
-		set(CMAKE_CXX_FLAGS_RELEASE    "${CMAKE_CXX_FLAGS_RELEASE} /Wp64 ${MSVC_W_ERROR} ${MSVC_W_DISABLE}")
-		set(CMAKE_CXX_FLAGS_MINSIZEREL "${CMAKE_CXX_FLAGS_MINSIZEREL} /Wp64 ${MSVC_W_ERROR} ${MSVC_W_DISABLE}")
+		set(CMAKE_CXX_FLAGS_DEBUG      "${CMAKE_CXX_FLAGS_DEBUG} /W4 ${MSVC_W_ERROR} ${MSVC_W_DISABLE}")
+		set(CMAKE_CXX_FLAGS_RELEASE    "${CMAKE_CXX_FLAGS_RELEASE} /W4 ${MSVC_W_ERROR} ${MSVC_W_DISABLE}")
+		set(CMAKE_CXX_FLAGS_MINSIZEREL "${CMAKE_CXX_FLAGS_MINSIZEREL} /W4 ${MSVC_W_ERROR} ${MSVC_W_DISABLE}")
 
 	else()
 		set(CMAKE_CXX_WARNING_LEVEL 3 CACHE STRING "Warning level" FORCE)


More information about the lyx-cvs mailing list