<div dir="ltr"><div>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&#39;t work.</div>
<div>&nbsp;</div>
<div>project(testcmake)<br></div>
<div># None of this works<br>#set(CMAKE_CXX_FLAGS &quot;${CMAKE_CXX_FLAGS} /wd4669&quot;)<br>set(CMAKE_CXX_FLAGS &quot;${CMAKE_CXX_FLAGS} /wd4669&quot; CACHE STRING &quot;Compilation flags&quot; FORCE)<br>#set(CMAKE_CXX_FLAGS &quot;${CMAKE_CXX_FLAGS} -wd4669&quot;)<br>
#set(CMAKE_CXX_FLAGS &quot;${CMAKE_CXX_FLAGS} -wd4669&quot; CACHE STRING &quot;Compilation flags&quot; FORCE)<br></div>
<div>add_executable(foo foo.cxx)</div>
<div>&nbsp;</div>
<div>I have tried the same variants with COMPILE_FLAGS and CMAKE_CXX_FLAGS_DEBUG / RELEASE with the same unsuccess.</div>
<div>&nbsp;</div>
<div>I only have VS Express 2008 so I can&#39;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.</div>
<div>&nbsp;</div>
<div>Thanks for your help,</div>
<div>&nbsp;</div>
<div>Tom</div>
<div>&nbsp;</div></div>