From c248b83845e0ad07de6e2e9b433b161a87197b38 Mon Sep 17 00:00:00 2001 From: Stanislaw Halik Date: Wed, 3 Jan 2018 13:56:39 +0100 Subject: cmake/msvc: prevent link failure on msvc preview --- cmake/msvc.cmake | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'cmake') 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") -- cgit v1.2.3