From ac35bf9e4a1d04b4fec70ea2c13fbe898fbccfb3 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Thu, 5 Nov 2020 14:04:37 +0100 Subject: use bcond --- php-pecl-mongodb.spec | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/php-pecl-mongodb.spec b/php-pecl-mongodb.spec index a7bf5be..bacc5fc 100644 --- a/php-pecl-mongodb.spec +++ b/php-pecl-mongodb.spec @@ -23,7 +23,7 @@ %global ini_name 50-%{pecl_name}.ini # test suite requires a MongoDB server -%global with_tests 0%{?_with_tests:1} +%bcond_with tests # temp for EL-8 until available in EPEL %if 0%{?fedora} >= 31 || 0%{?rhel} >= 8 @@ -72,7 +72,7 @@ Provides: bundled(libbson) = %{libmongo} Provides: bundled(mongo-c-driver) = %{libmongo} Provides: bundled(libmongocrypt) = %{libcrypt} %endif -%if %{with_tests} +%if %{with tests} BuildRequires: mongodb-server %endif @@ -271,7 +271,7 @@ OPT="-n" --modules | grep %{pecl_name} %endif -%if %{with_tests} +%if %{with tests} ret=0 %global mongo_version %(mongod --version | sed -n '/db version/{s/.*v//;p}' 2>/dev/null) -- cgit