When building with CMake, it is not possible to build google test with external abseil-cpp and re2 libraries. Specifying the GTEST_HAS_ABSL=ON expects the abseil and re2 targets to be built by the same project. However, in that case the googletest targets can't be installed since the CMake build system warns that they refer to other targets which aren't installed.
Describe the proposal.
The CMake build script can test if the absl and re2 targets exist. If they don't, invoking find_package for absl and re2 would import the external targets. The Config.cmake.in also needs to be modified to look for absl and re2.
Is the feature specific to an operating system, compiler, or build system version?
Does the feature exist in the most recent commit?
No.
Why do we need this feature?
When building with CMake, it is not possible to build google test with external abseil-cpp and re2 libraries. Specifying the
GTEST_HAS_ABSL=ON
expects the abseil and re2 targets to be built by the same project. However, in that case the googletest targets can't be installed since the CMake build system warns that they refer to other targets which aren't installed.Describe the proposal.
The CMake build script can test if the absl and re2 targets exist. If they don't, invoking
find_package
for absl and re2 would import the external targets. TheConfig.cmake.in
also needs to be modified to look for absl and re2.Is the feature specific to an operating system, compiler, or build system version?
It's specific to the CMake build system.