diff options
author | Andrei Polushin <polushin@gmail.com> | 2022-01-07 21:44:10 +0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-01-07 09:44:10 -0500 |
commit | 4799f6225a4fcf1fa2383d2eff25830c343bc9e9 (patch) | |
tree | ea428a385a0a7577e032116a84018e1eca69f991 /CMake/AbseilHelpers.cmake | |
parent | 294166fcbeae8c19b8817330a0874c186d147266 (diff) | |
download | abseil-4799f6225a4fcf1fa2383d2eff25830c343bc9e9.tar.gz abseil-4799f6225a4fcf1fa2383d2eff25830c343bc9e9.tar.bz2 abseil-4799f6225a4fcf1fa2383d2eff25830c343bc9e9.zip |
cmake: make `random_mocking_bit_gen` library public. (#1084)
An external project may depend on an Abseil `TESTONLY` library like
`absl::random_mocking_bit_gen`. Such a library should not be excluded
from build when Abseil's own tests are not built.
fixes #997
Diffstat (limited to 'CMake/AbseilHelpers.cmake')
-rw-r--r-- | CMake/AbseilHelpers.cmake | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/CMake/AbseilHelpers.cmake b/CMake/AbseilHelpers.cmake index 9ad2627d..ed87dde0 100644 --- a/CMake/AbseilHelpers.cmake +++ b/CMake/AbseilHelpers.cmake @@ -83,7 +83,8 @@ function(absl_cc_library) ${ARGN} ) - if(ABSL_CC_LIB_TESTONLY AND NOT (BUILD_TESTING AND ABSL_BUILD_TESTING)) + if(NOT ABSL_CC_LIB_PUBLIC AND ABSL_CC_LIB_TESTONLY AND + NOT (BUILD_TESTING AND ABSL_BUILD_TESTING)) return() endif() |