aboutsummaryrefslogtreecommitdiffstats
path: root/googletest
diff options
context:
space:
mode:
Diffstat (limited to 'googletest')
-rw-r--r--googletest/CMakeLists.txt17
-rw-r--r--googletest/cmake/internal_utils.cmake3
-rw-r--r--googletest/include/gtest/internal/gtest-port.h2
-rw-r--r--googletest/test/gtest-printers_test.cc6
4 files changed, 15 insertions, 13 deletions
diff --git a/googletest/CMakeLists.txt b/googletest/CMakeLists.txt
index 3b907fd7..cb2cbaed 100644
--- a/googletest/CMakeLists.txt
+++ b/googletest/CMakeLists.txt
@@ -74,8 +74,8 @@ config_compiler_and_linker() # Defined in internal_utils.cmake.
# Where Google Test's .h files can be found.
include_directories(
- ${gtest_SOURCE_DIR}/include
- ${gtest_SOURCE_DIR})
+ "${gtest_SOURCE_DIR}/include"
+ "${gtest_SOURCE_DIR}")
# Summary of tuple support for Microsoft Visual Studio:
# Compiler version(MS) version(cmake) Support
@@ -85,10 +85,11 @@ include_directories(
# VS 2013 12 1800 std::tr1::tuple
# VS 2015 14 1900 std::tuple
# VS 2017 15 >= 1910 std::tuple
+
if (MSVC AND MSVC_VERSION EQUAL 1700)
add_definitions(/D _VARIADIC_MAX=10)
endif()
-
+
########################################################################
#
# Defines the gtest & gtest_main libraries. User tests should link
@@ -114,11 +115,11 @@ endif()
# Install rules
if(INSTALL_GTEST)
install(TARGETS gtest gtest_main
- RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
- ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
- LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR})
- install(DIRECTORY ${gtest_SOURCE_DIR}/include/gtest
- DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
+ RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}"
+ ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}"
+ LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}")
+ install(DIRECTORY "${gtest_SOURCE_DIR}/include/gtest"
+ DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}")
# configure and install pkgconfig files
configure_file(
diff --git a/googletest/cmake/internal_utils.cmake b/googletest/cmake/internal_utils.cmake
index c54bc94f..d1f81e63 100644
--- a/googletest/cmake/internal_utils.cmake
+++ b/googletest/cmake/internal_utils.cmake
@@ -62,7 +62,8 @@ macro(config_compiler_and_linker)
if (MSVC)
# Newlines inside flags variables break CMake's NMake generator.
# TODO(vladl@google.com): Add -RTCs and -RTCu to debug builds.
- set(cxx_base_flags "-GS -W4 -WX -wd4251 -wd4275 -nologo -J -Zi")
+ # -J does not set path correctly for pdb with spaces
+ set(cxx_base_flags "-GS -W4 -WX -wd4251 -wd4275 -nologo -Zi")
if (MSVC_VERSION LESS 1400) # 1400 is Visual Studio 2005
# Suppress spurious warnings MSVC 7.1 sometimes issues.
# Forcing value to bool.
diff --git a/googletest/include/gtest/internal/gtest-port.h b/googletest/include/gtest/internal/gtest-port.h
index 0a0cd1d7..704dc022 100644
--- a/googletest/include/gtest/internal/gtest-port.h
+++ b/googletest/include/gtest/internal/gtest-port.h
@@ -646,7 +646,7 @@ typedef struct _RTL_CRITICAL_SECTION GTEST_CRITICAL_SECTION;
// Prevent `warning C4996: 'std::tr1': warning STL4002: The non-Standard std::tr1 namespace and TR1-only machinery are deprecated and will be REMOVED.`
# define GTEST_HAS_TR1_TUPLE 0
# else
-// The user didn't tell us not to do it, so we assume it's OK.
+ // The user didn't tell us not to do it, so we assume it's OK.
# define GTEST_HAS_TR1_TUPLE 1
# endif
#endif // GTEST_HAS_TR1_TUPLE
diff --git a/googletest/test/gtest-printers_test.cc b/googletest/test/gtest-printers_test.cc
index 2a6c017e..a48489c0 100644
--- a/googletest/test/gtest-printers_test.cc
+++ b/googletest/test/gtest-printers_test.cc
@@ -1092,8 +1092,8 @@ TEST(PrintTr1TupleTest, VariousSizes) {
::std::tr1::tuple<bool, char, short, testing::internal::Int32, // NOLINT
testing::internal::Int64, float, double, const char*, void*,
std::string>
- t10(false, 'a', static_cast<short>(3), 4, 5, 1.5F, -2.5, str,
- ImplicitCast_<void*>(NULL), "10");
+ t10(false, 'a', ImplicitCast_<short>(3), 4, 5, 1.5F, -2.5, str, ImplicitCast_<void*>(NULL),
+ "10");
EXPECT_EQ("(false, 'a' (97, 0x61), 3, 4, 5, 1.5, -2.5, " + PrintPointer(str) +
" pointing to \"8\", NULL, \"10\")",
Print(t10));
@@ -1152,7 +1152,7 @@ TEST(PrintStdTupleTest, VariousSizes) {
::std::tuple<bool, char, short, testing::internal::Int32, // NOLINT
testing::internal::Int64, float, double, const char*, void*,
std::string>
- t10(false, 'a', static_cast<short>(3), 4, 5, 1.5F, -2.5, str,
+ t10(false, 'a', ImplicitCast_<short>(3), 4, 5, 1.5F, -2.5, str,
ImplicitCast_<void*>(NULL), "10");
EXPECT_EQ("(false, 'a' (97, 0x61), 3, 4, 5, 1.5, -2.5, " + PrintPointer(str) +
" pointing to \"8\", NULL, \"10\")",