Buildsystem/MSVC: Only use /bigobj on x64 platforms - should solve x86 debug compilations (needs feedback)
--HG-- branch : trunk
This commit is contained in:
1 parent
258398ed30
commit
174f2884b7
1 file changed
+7
-8
@@ -17,13 +17,16 @@ if((NOT USE_COREPCH) AND (NOT USE_SCRIPTPCH))
|
|||||||
message(STATUS "- MSVC: PCH not used - enabled multithreaded compiling")
|
message(STATUS "- MSVC: PCH not used - enabled multithreaded compiling")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# This definition is necessary to work around a bug with Intellisense described
|
|
||||||
# here: http://tinyurl.com/2cb428. Syntax highlighting is important for proper
|
|
||||||
# debugger functionality.
|
|
||||||
|
|
||||||
if(${PLATFORM} STREQUAL "X64")
|
if(${PLATFORM} STREQUAL "X64")
|
||||||
|
# This definition is necessary to work around a bug with Intellisense described
|
||||||
|
# here: http://tinyurl.com/2cb428. Syntax highlighting is important for proper
|
||||||
|
# debugger functionality.
|
||||||
add_definitions("-D_WIN64")
|
add_definitions("-D_WIN64")
|
||||||
message(STATUS "- MSVC: 64-bit platform, enforced -D_WIN64 parameter")
|
message(STATUS "- MSVC: 64-bit platform, enforced -D_WIN64 parameter")
|
||||||
|
|
||||||
|
#Enable extended object support for debug compiles on X64 (not required on X86)
|
||||||
|
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS} /bigobj")
|
||||||
|
message(STATUS "- MSVC: Enabled extended object-support for debug-compiles")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# Define _CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES - eliminates the warning by changing the strcpy call to strcpy_s, which prevents buffer overruns
|
# Define _CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES - eliminates the warning by changing the strcpy call to strcpy_s, which prevents buffer overruns
|
||||||
@@ -38,10 +41,6 @@ message(STATUS "- MSVC: Disabled NON-SECURE warnings")
|
|||||||
add_definitions(-D_CRT_NONSTDC_NO_WARNINGS)
|
add_definitions(-D_CRT_NONSTDC_NO_WARNINGS)
|
||||||
message(STATUS "- MSVC: Disabled POSIX warnings")
|
message(STATUS "- MSVC: Disabled POSIX warnings")
|
||||||
|
|
||||||
#Enable extended object support for debug compiles
|
|
||||||
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS} /bigobj")
|
|
||||||
message(STATUS "- MSVC: Enabled extended object-support for debug-compiles")
|
|
||||||
|
|
||||||
# disable warnings in Visual Studio 8 and above if not wanted
|
# disable warnings in Visual Studio 8 and above if not wanted
|
||||||
if(NOT WITH_WARNINGS)
|
if(NOT WITH_WARNINGS)
|
||||||
if(MSVC AND NOT CMAKE_GENERATOR MATCHES "Visual Studio 7")
|
if(MSVC AND NOT CMAKE_GENERATOR MATCHES "Visual Studio 7")
|
||||||
|
|||||||
Reference in new issue
Block a user