Disabling specific warnings is a simple task so I thought I could do it
myself but I must admit defeat. A simple CMakeLists.txt like this won't
work.
<code>

project(testcmake)
# None of this works
#set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4669")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4669" CACHE STRING "Compilation
flags" FORCE)
#set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /wd4669")
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /wd4669" CACHE STRING
"Compilation flags" FORCE)#set(CMAKE_CXX_FLAGS_RELEASE
"${CMAKE_CXX_FLAGS_RELEASE} /wd4669")
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /wd4669" CACHE
STRING "Compilation flags" FORCE)
add_executable(foo foo.cxx)
#doesn't work either
set_target_properties(foo PROPERTIES COMPILE_FLAGS "/wd4996")
</code>

I only have VS Express 2008 so I can't check whether I am doing something
wrong or if there is some issue with this particular IDE -- not even sure if
it is explicitely not supported.

Thanks for your help,

Tom
_______________________________________________
CMake mailing list
CMake@cmake.org
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to