2
0
mirror of https://github.com/gentoo-mirror/gentoo.git synced 2026-01-19 00:09:37 +03:00

dev-cpp/gtest: fix running gtest_help_test test

Signed-off-by: Peter Levine <plevine457@gmail.com>
Signed-off-by: Florian Schmaus <flow@gentoo.org>
This commit is contained in:
Peter Levine
2024-10-08 05:33:46 -04:00
committed by Florian Schmaus
parent ac1b61f6f7
commit 11790c99bb
2 changed files with 21 additions and 1 deletions

View File

@@ -0,0 +1,17 @@
Similar to the bazel build, gtest is supposed to pass --has_absl_flags to
gtest_help_test if building with abseil support but neglects to.
--- a/googletest/CMakeLists.txt
+++ b/googletest/CMakeLists.txt
@@ -293,7 +293,11 @@
py_test(googletest-filter-unittest)
cxx_executable(gtest_help_test_ test gtest_main)
+ if(NOT GTEST_HAS_ABSL)
py_test(gtest_help_test)
+ else()
+ py_test(gtest_help_test --has_absl_flags)
+ endif()
cxx_executable(googletest-list-tests-unittest_ test gtest)
py_test(googletest-list-tests-unittest)

View File

@@ -41,7 +41,10 @@ RDEPEND="${DEPEND}"
# Exclude tests that fail with FEATURES="usersandbox"
CMAKE_SKIP_TESTS=( "googletest-(death-test|port)-test" )
PATCHES=( "${FILESDIR}"/gtest-find-re2-with-pkgconfig.patch )
PATCHES=(
"${FILESDIR}"/gtest-find-re2-with-pkgconfig.patch
"${FILESDIR}"/gtest-1.15.2-fix-gtest_help_test.patch
)
pkg_setup() {
use test && python-any-r1_pkg_setup