[Cmake] Adjusting compiler optimization for msvc

Wheeler, Frederick W (Research) wheeler at crd.ge.com
Wed May 21 10:24:45 EDT 2003


Is there something analogous to this for msvc?

IF(CMAKE_COMPILER_IS_GNUCXX)
  SET_SOURCE_FILES_PROPERTIES(test_mil.cxx COMPILE_FLAGS -O0)
ENDIF(CMAKE_COMPILER_IS_GNUCXX)

I'd like to disable optimization for one file in VXL when compiling with
msvc 6.0.    With optimization, msvc produces bad code for one particular
file (vxl_src/core/vil2/vil2_bicub_interp.txx).  It's a txx file.  Would I
actually use a SET_SOURCE_FILES_PROPERTIES command on the .cxx files in the
Templates directory?

Thanks,
Fred Wheeler



More information about the CMake mailing list