googletest
googletest copied to clipboard
BUILD_GMOCK variable reset due to cmake policy CMP0077
trafficstars
The cmake flag -DBUILD_GMOCK=OFF will have be reset causing gmock to be built regardless. This will cause issues when building other Google libraries such as protobuf in the same CMake build as the variables will already exist.
Setting CMake policy CMP0077 to NEW instead of OLD in CMakeLists.txt should fix the issue
@dinord now that the CMake min is 3.13 this issue can be closed.
https://cmake.org/cmake/help/latest/policy/CMP0077.html#policy:CMP0077