1 2 3 4 5
add_library(autoexport2 SHARED sub.cxx) if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") # Try msvc "big" object format. target_compile_options(autoexport2 PRIVATE /bigobj) endif()