Skip to content

Commit

Permalink
cmake: googletest fixup
Browse files Browse the repository at this point in the history
  • Loading branch information
Mizux committed Feb 3, 2025
1 parent aff397d commit ec8199b
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions patches/googletest-v1.15.2.patch
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ index e9d9e32..ca55646 100644
#define GMOCK_FLAG_GET(name) ::absl::GetFlag(GMOCK_FLAG(name))
#define GMOCK_FLAG_SET(name, value) \
diff --git a/googletest/cmake/internal_utils.cmake b/googletest/cmake/internal_utils.cmake
index 580ac1c..96fe3ac 100644
index 580ac1c..014e74c 100644
--- a/googletest/cmake/internal_utils.cmake
+++ b/googletest/cmake/internal_utils.cmake
@@ -11,6 +11,7 @@
Expand Down Expand Up @@ -46,9 +46,11 @@ index 580ac1c..96fe3ac 100644
# Make PDBs match library name.
get_target_property(pdb_debug_postfix ${name} DEBUG_POSTFIX)
set_target_properties(${name}
@@ -190,6 +191,13 @@ function(cxx_library_with_type name type cxx_flags)
@@ -189,7 +190,15 @@ function(cxx_library_with_type name type cxx_flags)
PROPERTIES
COMPILE_DEFINITIONS "GTEST_CREATE_SHARED_LIBRARY=1")
target_compile_definitions(${name} INTERFACE
+ $<BUILD_INTERFACE:GTEST_LINKED_AS_SHARED_LIBRARY=1>
$<INSTALL_INTERFACE:GTEST_LINKED_AS_SHARED_LIBRARY=1>)
+ if(APPLE)
+ set_target_properties(${name} PROPERTIES
Expand Down

0 comments on commit ec8199b

Please sign in to comment.