The following issue has been SUBMITTED. 
====================================================================== 
http://public.kitware.com/Bug/view.php?id=14149 
====================================================================== 
Reported By:                Daniel Raviart
Assigned To:                
====================================================================== 
Project:                    CMake
Issue ID:                   14149
Category:                   CMake
Reproducibility:            always
Severity:                   block
Priority:                   urgent
Status:                     new
====================================================================== 
Date Submitted:             2013-05-16 10:42 EDT
Last Modified:              2013-05-16 10:42 EDT
====================================================================== 
Summary:                    /EHsc flag cannot be removed from CMAKE_CXX_FLAGS
for Visual Studio 2010
Description: 
CMake 2.8.11-rc2
I tried several ways to remove the exception handling /EHsc flag from the cache.
1 - string(REPLACE "/EHsc" "/EHs-c-" CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}")
2 - set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}" FORCE )
3 - set( CMAKE_CXX_FLAGS_INIT "/DWIN32 /D_WINDOWS /W3 /GR" )
After each try, the variable is still the same in the cache:
//Flags used by the compiler during all build types.
CMAKE_CXX_FLAGS:STRING= /DWIN32 /D_WINDOWS /W3 /GR /EHsc
I am unable to remove the /EHsc flag.
I saw that this bug was reported here:
http://www.cmake.org/pipermail/cmake/2010-December/041638.html
It is said that:
"This is because cmake automatically adds /EHsc to the command line
options."
If this is true, how do we do to remove this option?
Thanks in advance.
====================================================================== 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2013-05-16 10:42 Daniel Raviart New Issue                                    
======================================================================

--

Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers

Reply via email to