summaryrefslogtreecommitdiffstats
path: root/googletest/cmake
diff options
context:
space:
mode:
authorDavid Neto <dneto@google.com>2018-02-26 19:54:16 (GMT)
committerDavid Neto <dneto@google.com>2018-02-26 20:58:49 (GMT)
commit20074be19a9c1d6568a4554da2fee3f2e3dbac09 (patch)
treeb87f723f43db948f12e3d49f1f893472d66f4364 /googletest/cmake
parentac34e6c950925df7165e626becd3f9d64dcd584b (diff)
downloadgoogletest-20074be19a9c1d6568a4554da2fee3f2e3dbac09.zip
googletest-20074be19a9c1d6568a4554da2fee3f2e3dbac09.tar.gz
googletest-20074be19a9c1d6568a4554da2fee3f2e3dbac09.tar.bz2
Use DEBUG_POSTFIX instead of CMAKE_DEBUG_POSTFIX
CMAKE_DEBUG_POSTFIX is a global configuration parameter, and changing it pollutes the configuration space for other projects that enclose this project. DEBUG_POSTFIX is better to use since it is a target-specific poperty. Fixes #1334 Fixes #1268
Diffstat (limited to 'googletest/cmake')
-rw-r--r--googletest/cmake/internal_utils.cmake4
1 files changed, 4 insertions, 0 deletions
diff --git a/googletest/cmake/internal_utils.cmake b/googletest/cmake/internal_utils.cmake
index 2c97833..01f9fe5 100644
--- a/googletest/cmake/internal_utils.cmake
+++ b/googletest/cmake/internal_utils.cmake
@@ -158,6 +158,10 @@ function(cxx_library_with_type name type cxx_flags)
set_target_properties(${name}
PROPERTIES
COMPILE_FLAGS "${cxx_flags}")
+ # Generate debug library name with a postfix.
+ set_target_properties(${name}
+ PROPERTIES
+ DEBUG_POSTFIX "d")
if (BUILD_SHARED_LIBS OR type STREQUAL "SHARED")
set_target_properties(${name}
PROPERTIES