diff --git a/googletest/cmake/internal_utils.cmake b/googletest/cmake/internal_utils.cmake index ca76f42d7..c1faf3fed 100644 --- a/googletest/cmake/internal_utils.cmake +++ b/googletest/cmake/internal_utils.cmake @@ -199,6 +199,8 @@ function(cxx_library_with_type name type cxx_flags) INSTALL_RPATH "$ORIGIN") endif() endif() + target_compile_definitions(${name} INTERFACE + $>) if (DEFINED GTEST_HAS_PTHREAD) target_link_libraries(${name} PUBLIC Threads::Threads) endif()