Merge pull request #1769 from dakotahawkins/fix-1764_CMake-errors-in-googlemock
Use `$<INSTALL_PREFIX>` in `target_include_directories`
This commit is contained in:
commit
2e68926a9d
@ -118,10 +118,10 @@ endif()
|
|||||||
if (DEFINED CMAKE_VERSION AND NOT "${CMAKE_VERSION}" VERSION_LESS "2.8.11")
|
if (DEFINED CMAKE_VERSION AND NOT "${CMAKE_VERSION}" VERSION_LESS "2.8.11")
|
||||||
target_include_directories(gmock SYSTEM INTERFACE
|
target_include_directories(gmock SYSTEM INTERFACE
|
||||||
"$<BUILD_INTERFACE:${gmock_build_include_dirs}>"
|
"$<BUILD_INTERFACE:${gmock_build_include_dirs}>"
|
||||||
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>)
|
"$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/${CMAKE_INSTALL_INCLUDEDIR}>")
|
||||||
target_include_directories(gmock_main SYSTEM INTERFACE
|
target_include_directories(gmock_main SYSTEM INTERFACE
|
||||||
"$<BUILD_INTERFACE:${gmock_build_include_dirs}>"
|
"$<BUILD_INTERFACE:${gmock_build_include_dirs}>"
|
||||||
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>)
|
"$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/${CMAKE_INSTALL_INCLUDEDIR}>")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
########################################################################
|
########################################################################
|
||||||
|
@ -138,10 +138,10 @@ cxx_library(gtest_main "${cxx_strict}" src/gtest_main.cc)
|
|||||||
if (DEFINED CMAKE_VERSION AND NOT "${CMAKE_VERSION}" VERSION_LESS "2.8.11")
|
if (DEFINED CMAKE_VERSION AND NOT "${CMAKE_VERSION}" VERSION_LESS "2.8.11")
|
||||||
target_include_directories(gtest SYSTEM INTERFACE
|
target_include_directories(gtest SYSTEM INTERFACE
|
||||||
"$<BUILD_INTERFACE:${gtest_build_include_dirs}>"
|
"$<BUILD_INTERFACE:${gtest_build_include_dirs}>"
|
||||||
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>)
|
"$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/${CMAKE_INSTALL_INCLUDEDIR}>")
|
||||||
target_include_directories(gtest_main SYSTEM INTERFACE
|
target_include_directories(gtest_main SYSTEM INTERFACE
|
||||||
"$<BUILD_INTERFACE:${gtest_build_include_dirs}>"
|
"$<BUILD_INTERFACE:${gtest_build_include_dirs}>"
|
||||||
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>)
|
"$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/${CMAKE_INSTALL_INCLUDEDIR}>")
|
||||||
endif()
|
endif()
|
||||||
target_link_libraries(gtest_main PUBLIC gtest)
|
target_link_libraries(gtest_main PUBLIC gtest)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user