From 080ea1902dcccc9e53a3b0d9130dc81fe11e6d43 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Mon, 2 Jan 2023 13:49:35 +0100 Subject: make test suite optional --- php-pecl-vips.spec | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'php-pecl-vips.spec') diff --git a/php-pecl-vips.spec b/php-pecl-vips.spec index d116fc9..73febcb 100644 --- a/php-pecl-vips.spec +++ b/php-pecl-vips.spec @@ -10,6 +10,8 @@ %scl_package php-pecl-vips %endif +%bcond_with tests + %global pecl_name vips %global with_zts 0%{!?_without_zts:%{?__ztsphp:1}} %global ini_name 40-%{pecl_name}.ini @@ -160,12 +162,13 @@ cd NTS --define extension=%{buildroot}%{php_extdir}/%{pecl_name}.so \ --modules | grep '^%{pecl_name}$' +%if %{with tests} : Upstream test suite for NTS extension TEST_PHP_EXECUTABLE=%{_bindir}/php \ TEST_PHP_ARGS="-n $DEPMOD -d extension=%{buildroot}%{php_extdir}/%{pecl_name}.so" \ REPORT_EXIT_STATUS=1 \ %{_bindir}/php -n run-tests.php -q --show-diff - +%endif %if %{with_zts} : Minimal load test for ZTS extension @@ -175,12 +178,14 @@ cd ../ZTS --define extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so \ --modules | grep '^%{pecl_name}$' +%if %{with tests} : Upstream test suite for ZTS extension TEST_PHP_EXECUTABLE=%{__ztsphp} \ TEST_PHP_ARGS="-n $DEPMOD -d extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so" \ REPORT_EXIT_STATUS=1 \ %{__ztsphp} -n run-tests.php -q --show-diff %endif +%endif %files -- cgit