From 4971c1e0ad77251a1258f25a49d4ce76e567d4dd Mon Sep 17 00:00:00 2001 From: Rex Dieter Date: Thu, 15 Dec 2016 09:50:28 -0600 Subject: [PATCH] enable tests on f24+, support bootstrap I think something (glib?) is too old on f23 for the tests --- lensfun.spec | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/lensfun.spec b/lensfun.spec index 5f12dbf..c3b87f1 100644 --- a/lensfun.spec +++ b/lensfun.spec @@ -1,4 +1,8 @@ +%if !0%{?bootstrap} && 0%{?fedora} > 23 +%global tests 1 +%endif + Name: lensfun Version: 0.3.2 Summary: Library to rectify defects introduced by photographic lenses @@ -78,7 +82,7 @@ mkdir %{_target_platform} pushd %{_target_platform} %{cmake} .. \ -DBUILD_DOC:BOOL=ON \ - -DBUILD_TESTS:BOOL=ON \ + -DBUILD_TESTS:BOOL=%{?tests:ON}%{!?tests:OFF} \ -DCMAKE_BUILD_TYPE:STRING=Release popd @@ -97,11 +101,14 @@ mkdir -p %{buildroot}/var/lib/lensfun-updates rm -fv %{buildroot}%{_bindir}/g-lensfun-update-data \ %{buildroot}%{_mandir}/man1/g-lensfun-update-data.* + %check +%if 0%{?tests} pushd %{_target_platform} export CTEST_OUTPUT_ON_FAILURE=1 ctest -vv popd +%endif %post -p /sbin/ldconfig