diff --git a/qmlexport/CMakeLists.txt b/qmlexport/CMakeLists.txt index b3d88227..a6edc8b1 100644 --- a/qmlexport/CMakeLists.txt +++ b/qmlexport/CMakeLists.txt @@ -66,7 +66,11 @@ if (CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") ${QSK_INSTALL_LIBS} OPTIONAL) endif() -if (CMAKE_CXX_COMPILER_ID STREQUAL "GNU") +get_filename_component(compiler ${CMAKE_CXX_COMPILER} NAME_WE) +if (CMAKE_CXX_COMPILER_ID STREQUAL "GNU" AND CMAKE_SYSTEM_NAME STREQUAL "Windows" AND compiler STREQUAL "g++") + message(STATUS "CMAKE_CXX_COMPILER_ID: ${CMAKE_CXX_COMPILER_ID}") + message(STATUS "CMAKE_SYSTEM_NAME: ${CMAKE_SYSTEM_NAME}") + message(STATUS "compiler: ${compiler}") #target_compile_options(${target} PRIVATE "-Wa,-mbig-obj") set_source_files_properties(QskQml.cpp PROPERTIES COMPILE_FLAGS "-Wa,-mbig-obj") endif()