summaryrefslogtreecommitdiffhomepage
path: root/cmake
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2018-01-03 13:56:39 +0100
committerStanislaw Halik <sthalik@misaki.pl>2018-01-03 14:35:55 +0100
commitc248b83845e0ad07de6e2e9b433b161a87197b38 (patch)
tree6b377d0436d27b7b8a19777a93f7ab4e771791e3 /cmake
parent672e1df0c4a6fe4f5cca0bd76172feb86060b2a4 (diff)
cmake/msvc: prevent link failure on msvc preview
Diffstat (limited to 'cmake')
-rw-r--r--cmake/msvc.cmake8
1 files changed, 6 insertions, 2 deletions
diff --git a/cmake/msvc.cmake b/cmake/msvc.cmake
index 9136e2eb..379bf9b4 100644
--- a/cmake/msvc.cmake
+++ b/cmake/msvc.cmake
@@ -65,11 +65,15 @@ set(_CXXFLAGS_RELEASE "${cc}")
set(_CXXFLAGS_DEBUG "${_CFLAGS_DEBUG}")
set(_LDFLAGS "-machine:X86 -DEBUG")
-set(_LDFLAGS_RELEASE "-LTCG:INCREMENTAL -OPT:REF -OPT:ICF=10")
+
+set(_ltcg "-LTCG")
+#set(_ltcg "-LTCG:INCREMENTAL")
+
+set(_LDFLAGS_RELEASE "-OPT:REF,ICF ${_ltcg}")
set(_LDFLAGS_DEBUG "")
set(_LDFLAGS_STATIC "-machine:X86 -WX")
-set(_LDFLAGS_STATIC_RELEASE "-LTCG:INCREMENTAL")
+set(_LDFLAGS_STATIC_RELEASE "${_ltcg}")
set(_LDFLAGS_STATIC_DEBUG "")
set(CMAKE_RC_FLAGS "/nologo -DWIN32")