gtest: fix includedir in cmake config files
This commit is contained in:
parent
bc8f67e37f
commit
a2fe6bca05
@ -12,6 +12,10 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "0270msj6n7mggh4xqqjp54kswbl7mkcc8px1p5dqdpmw5ngh9fzk";
|
||||
};
|
||||
|
||||
patches = [
|
||||
./fix-cmake-config-includedir.patch
|
||||
];
|
||||
|
||||
nativeBuildInputs = [ cmake ninja ];
|
||||
|
||||
cmakeFlags = [
|
||||
|
@ -0,0 +1,30 @@
|
||||
--- a/googlemock/CMakeLists.txt
|
||||
+++ b/googlemock/CMakeLists.txt
|
||||
@@ -106,10 +106,10 @@
|
||||
if (DEFINED CMAKE_VERSION AND NOT "${CMAKE_VERSION}" VERSION_LESS "2.8.11")
|
||||
target_include_directories(gmock SYSTEM INTERFACE
|
||||
"$<BUILD_INTERFACE:${gmock_build_include_dirs}>"
|
||||
- "$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/${CMAKE_INSTALL_INCLUDEDIR}>")
|
||||
+ "$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>")
|
||||
target_include_directories(gmock_main SYSTEM INTERFACE
|
||||
"$<BUILD_INTERFACE:${gmock_build_include_dirs}>"
|
||||
- "$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/${CMAKE_INSTALL_INCLUDEDIR}>")
|
||||
+ "$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>")
|
||||
endif()
|
||||
|
||||
########################################################################
|
||||
--- a/googletest/CMakeLists.txt
|
||||
+++ b/googletest/CMakeLists.txt
|
||||
@@ -126,10 +126,10 @@
|
||||
if (DEFINED CMAKE_VERSION AND NOT "${CMAKE_VERSION}" VERSION_LESS "2.8.11")
|
||||
target_include_directories(gtest SYSTEM INTERFACE
|
||||
"$<BUILD_INTERFACE:${gtest_build_include_dirs}>"
|
||||
- "$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/${CMAKE_INSTALL_INCLUDEDIR}>")
|
||||
+ "$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>")
|
||||
target_include_directories(gtest_main SYSTEM INTERFACE
|
||||
"$<BUILD_INTERFACE:${gtest_build_include_dirs}>"
|
||||
- "$<INSTALL_INTERFACE:$<INSTALL_PREFIX>/${CMAKE_INSTALL_INCLUDEDIR}>")
|
||||
+ "$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>")
|
||||
endif()
|
||||
target_link_libraries(gtest_main PUBLIC gtest)
|
||||
|
Loading…
Reference in New Issue
Block a user