diff options
author | Campbell Barton <ideasman42@gmail.com> | 2013-06-05 23:33:19 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2013-06-05 23:33:19 +0400 |
commit | bbb025214deddc73749b3fa5e3136c19a7871fd1 (patch) | |
tree | 00dbaf69f3b339195541262bc2b38639f4243f2e /CMakeLists.txt | |
parent | ad09731c30d60ff73159f52803e4575768a63a04 (diff) |
issue warning when WITH_RAYOPTIMIZATION is used with MinGW-w32, since this is known to give crashes.
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 369e7f5b03b..86848d10422 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -931,20 +931,26 @@ elseif(WIN32) # include(${CMAKE_ROOT}/Modules/Platform/Windows-cl.cmake) if(CMAKE_COMPILER_IS_GNUCC) - set(LIBDIR ${CMAKE_SOURCE_DIR}/../lib/mingw32) include(CheckCSourceCompiles) # Setup 64bit and 64bit windows systems CHECK_C_SOURCE_COMPILES(" #ifndef __MINGW64__ #error #endif - main(){} + int main(void) { return 0; } " WITH_MINGW64) if(WITH_MINGW64) message(STATUS "Compiling for 64 bit with MinGW-w64.") set(LIBDIR ${CMAKE_SOURCE_DIR}/../lib/mingw64) + else() + message(STATUS "Compiling for 32 bit with MinGW-w32.") + set(LIBDIR ${CMAKE_SOURCE_DIR}/../lib/mingw32) + + if(WITH_RAYOPTIMIZATION) + message(WARNING "MinGW-w32 is known to be unstable with 'WITH_RAYOPTIMIZATION' option enabled.") + endif() endif() else() # Setup 64bit and 64bit windows systems |