diff --git a/code/CMakeLists.txt b/code/CMakeLists.txt index 4a201a536..3eafbdc62 100644 --- a/code/CMakeLists.txt +++ b/code/CMakeLists.txt @@ -463,9 +463,13 @@ ADD_ASSIMP_IMPORTER( IFC STEPFileEncoding.cpp STEPFileEncoding.h ) -if (MSVC AND ASSIMP_BUILD_IFC_IMPORTER) - set_source_files_properties(IFCReaderGen1.cpp IFCReaderGen2.cpp PROPERTIES COMPILE_FLAGS "/bigobj") -endif (MSVC AND ASSIMP_BUILD_IFC_IMPORTER) +if (ASSIMP_BUILD_IFC_IMPORTER) + if (MSVC) + set_source_files_properties(IFCReaderGen1.cpp IFCReaderGen2.cpp PROPERTIES COMPILE_FLAGS "/bigobj") + elseif(CMAKE_COMPILER_IS_MINGW) + set_source_files_properties(IFCReaderGen1.cpp IFCReaderGen2.cpp PROPERTIES COMPILE_FLAGS "-O2 -Wa,-mbig-obj") + endif() +endif (ASSIMP_BUILD_IFC_IMPORTER) ADD_ASSIMP_IMPORTER( XGL XGLLoader.cpp