commit:     bda61b8496d6d7d698797f2451e5235abab34628
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Wed May 10 20:17:33 2023 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Wed May 10 20:19:32 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=bda61b84

sci-libs/gdal: make USE_EXTERNAL_GTEST conditional on tests

Closes: https://bugs.gentoo.org/906092
Signed-off-by: Sam James <sam <AT> gentoo.org>

 sci-libs/gdal/gdal-3.7.0.ebuild | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/sci-libs/gdal/gdal-3.7.0.ebuild b/sci-libs/gdal/gdal-3.7.0.ebuild
index ef7fc667de4d..7015e10d415d 100644
--- a/sci-libs/gdal/gdal-3.7.0.ebuild
+++ b/sci-libs/gdal/gdal-3.7.0.ebuild
@@ -122,7 +122,6 @@ src_configure() {
                -DENABLE_IPO=OFF
                -DGDAL_USE_EXTERNAL_LIBS=ON
                -DGDAL_USE_INTERNAL_LIBS=OFF
-               -DUSE_EXTERNAL_GTEST=ON
                -DBUILD_TESTING=$(usex test)
 
                # bug #844874 and bug #845150
@@ -233,6 +232,10 @@ src_configure() {
                #-Dtest_xop=$(usex cpu_flags_x86_xop)
        )
 
+       if use test ; then
+               mycmakeargs+=( -DUSE_EXTERNAL_GTEST=ON )
+       fi
+
        cmake_src_configure
 }
 

Reply via email to