[Cmake-commits] [cmake-commits] king committed CMakeLists.txt 1.154 1.155
cmake-commits at cmake.org
cmake-commits at cmake.org
Mon Nov 23 15:31:32 EST 2009
Update of /cvsroot/CMake/CMake/Source/kwsys
In directory public:/mounts/ram/cvs-serv12113/Source/kwsys
Modified Files:
CMakeLists.txt
Log Message:
KWSys: Work-around llvm-gcc-4.2 optimizer bug
Under -O3 optimization this compiler breaks our testProcess.c source file.
We force -O0 for the file to avoid the problem.
Index: CMakeLists.txt
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/kwsys/CMakeLists.txt,v
retrieving revision 1.154
retrieving revision 1.155
diff -C 2 -d -r1.154 -r1.155
*** CMakeLists.txt 20 Nov 2009 17:04:08 -0000 1.154
--- CMakeLists.txt 23 Nov 2009 20:31:29 -0000 1.155
***************
*** 1096,1099 ****
--- 1096,1104 ----
ENDFOREACH(n)
+ # Some Apple compilers produce bad optimizations in this source.
+ IF(APPLE AND "${CMAKE_C_COMPILER_ID}" MATCHES "^(GNU|LLVM)$")
+ SET_SOURCE_FILES_PROPERTIES(testProcess.c PROPERTIES COMPILE_FLAGS -O0)
+ ENDIF()
+
# Test SharedForward
CONFIGURE_FILE(${PROJECT_SOURCE_DIR}/testSharedForward.c.in
More information about the Cmake-commits
mailing list