support bootstrap/tests

epel9
Rex Dieter 9 years ago
parent 90d19bbba2
commit fdaf2e6e40

@ -1,6 +1,14 @@
# uncomment to enable bootstrap mode
#global bootstrap 1
%if !0%{?bootstrap}
%global tests 1
%endif
Name: kio-extras Name: kio-extras
Version: 16.04.0 Version: 16.04.0
Release: 1%{?dist} Release: 2%{?dist}
Summary: Additional components to increase the functionality of KIO Framework Summary: Additional components to increase the functionality of KIO Framework
License: GPLv2+ License: GPLv2+
@ -43,6 +51,9 @@ BuildRequires: openslp-devel
BuildRequires: phonon-qt5-devel BuildRequires: phonon-qt5-devel
BuildRequires: qt5-qtbase-devel BuildRequires: qt5-qtbase-devel
BuildRequires: qt5-qtsvg-devel BuildRequires: qt5-qtsvg-devel
%if 0%{?tests}
BuildRequires: xorg-x11-server-Xvfb dbus-x11
%endif
# short-lived subpkg, locale conflicts fixed in kio_mtp instead # short-lived subpkg, locale conflicts fixed in kio_mtp instead
Obsoletes: kio-extras-mtp-common < 5.2.2-3 Obsoletes: kio-extras-mtp-common < 5.2.2-3
@ -68,7 +79,8 @@ BuildArch: noarch
%build %build
mkdir %{_target_platform} mkdir %{_target_platform}
pushd %{_target_platform} pushd %{_target_platform}
%{cmake_kf5} .. %{cmake_kf5} .. \
%{?tests:-DBUILD_TESTING:BOOL=ON}
popd popd
make %{?_smp_mflags} -C %{_target_platform} make %{?_smp_mflags} -C %{_target_platform}
@ -78,6 +90,14 @@ make %{?_smp_mflags} -C %{_target_platform}
make install/fast DESTDIR=%{buildroot} -C %{_target_platform} make install/fast DESTDIR=%{buildroot} -C %{_target_platform}
%check
%if 0%{?tests}
export CTEST_OUTPUT_ON_FAILURE=1
xvfb-run -a dbus-launch --exit-with-session \
time make test -C %{_target_platform} ARGS="--output-on-failure --timeout 10" ||:
%endif
%post %post
/sbin/ldconfig /sbin/ldconfig
touch --no-create %{_datadir}/mime/packages &> /dev/null || : touch --no-create %{_datadir}/mime/packages &> /dev/null || :
@ -155,6 +175,9 @@ update-mime-database %{?fedora:-n} %{_datadir}/mime &> /dev/null || :
%changelog %changelog
* Fri Apr 29 2016 Rex Dieter <rdieter@fedoraproject.org> - 16.04.0-2
- support bootstrap/tests
* Tue Apr 19 2016 Rex Dieter <rdieter@fedoraproject.org> - 16.04.0-1 * Tue Apr 19 2016 Rex Dieter <rdieter@fedoraproject.org> - 16.04.0-1
- 16.04.0 - 16.04.0

Loading…
Cancel
Save