Mercurial > hg > orthanc
comparison Resources/CMake/Compiler.cmake @ 3251:fcfd4f73228c
using masm if compiling icu with Visual Studio
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Sat, 16 Feb 2019 14:28:53 +0100 |
parents | 212abfffc44d |
children | ce6a98f8ed85 |
comparison
equal
deleted
inserted
replaced
3250:212abfffc44d | 3251:fcfd4f73228c |
---|---|
34 CMAKE_CXX_FLAGS_RELWITHDEBINFO) | 34 CMAKE_CXX_FLAGS_RELWITHDEBINFO) |
35 string(REGEX REPLACE "/MD" "/MT" ${flag_var} "${${flag_var}}") | 35 string(REGEX REPLACE "/MD" "/MT" ${flag_var} "${${flag_var}}") |
36 string(REGEX REPLACE "/MDd" "/MTd" ${flag_var} "${${flag_var}}") | 36 string(REGEX REPLACE "/MDd" "/MTd" ${flag_var} "${${flag_var}}") |
37 endforeach(flag_var) | 37 endforeach(flag_var) |
38 | 38 |
39 if (BOOST_LOCALE_BACKEND STREQUAL "icu") | 39 # Add /Zm256 compiler option to Visual Studio to fix PCH errors |
40 # If compiling icu, the heap space must be further increased: | 40 set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /Zm256") |
41 # "icudt58l_dat.c(1638339): fatal error C1060: compiler is out of heap space" | |
42 set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /Zm1024") | |
43 else() | |
44 # Add /Zm256 compiler option to Visual Studio to fix PCH errors | |
45 set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /Zm256") | |
46 endif() | |
47 | 41 |
48 add_definitions( | 42 add_definitions( |
49 -D_CRT_SECURE_NO_WARNINGS=1 | 43 -D_CRT_SECURE_NO_WARNINGS=1 |
50 -D_CRT_SECURE_NO_DEPRECATE=1 | 44 -D_CRT_SECURE_NO_DEPRECATE=1 |
51 ) | 45 ) |