From ce460eea929d2c4c270f556b5a26213f39b6ec7c Mon Sep 17 00:00:00 2001 From: Jing Dong Date: Fri, 30 Nov 2018 15:48:16 -0500 Subject: [PATCH] fix virtual memory range for PCH exceeded --- CMakeLists.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 45a57827d..f9196aced 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -121,6 +121,10 @@ if(MSVC) add_definitions(-DBOOST_ALL_NO_LIB) add_definitions(-DBOOST_ALL_DYN_LINK) endif() + # Virtual memory range for PCH exceeded on VS2015 + if(MSVC_VERSION LESS 1910) # older than VS2017 + add_definitions(-Zm295) + endif() endif() find_package(Boost 1.43 COMPONENTS serialization system filesystem thread program_options date_time timer chrono regex)