From 38e67b1e4114a86809345297214cc63215214a4a Mon Sep 17 00:00:00 2001 From: Rex Dieter Date: Sat, 30 Apr 2016 19:16:06 -0500 Subject: [PATCH] 5.21.0-2 - update URL - support bootstrap - add %check - own %{_kf5_qtplugindir}/ktexteditor --- kf5-ktexteditor.spec | 41 ++++++++++++++++++++++++++++++++++++----- 1 file changed, 36 insertions(+), 5 deletions(-) diff --git a/kf5-ktexteditor.spec b/kf5-ktexteditor.spec index 9955ac2..d6cf9d7 100644 --- a/kf5-ktexteditor.spec +++ b/kf5-ktexteditor.spec @@ -1,12 +1,19 @@ %global framework ktexteditor +# uncomment to enable bootstrap mode +#global bootstrap 1 + +%if !0%{?bootstrap} +%global tests 1 +%endif + Name: kf5-%{framework} Version: 5.21.0 -Release: 1%{?dist} +Release: 2%{?dist} Summary: KDE Frameworks 5 Tier 3 with advanced embeddable text editor License: LGPLv2+ -URL: https://projects.kde.org/ktexteditor +URL: https://quickgit.kde.org/?p=%{framework}.git %global versiondir %(echo %{version} | cut -d. -f1-2) %global revision %(echo %{version} | cut -d. -f3) @@ -19,7 +26,6 @@ Source0: http://download.kde.org/%{stable}/frameworks/%{versiondir}/%{fra ## Upstream patches - BuildRequires: extra-cmake-modules >= %{version} BuildRequires: kf5-karchive-devel >= %{version} BuildRequires: kf5-kconfig-devel >= %{version} @@ -33,10 +39,14 @@ BuildRequires: kf5-sonnet-devel >= %{version} BuildRequires: qt5-qtbase-devel BuildRequires: qt5-qtscript-devel BuildRequires: qt5-qtxmlpatterns-devel - %if 0%{?fedora} >= 22 BuildRequires: libgit2-devel >= 0.22.0 %endif +%if 0%{?tests} +BuildRequires: dbus-x11 +BuildRequires: time +BuildRequires: xorg-x11-server-Xvfb +%endif Requires: kf5-filesystem >= %{version} @@ -66,7 +76,8 @@ developing applications that use %{name}. %build mkdir %{_target_platform} pushd %{_target_platform} -%{cmake_kf5} .. +%{cmake_kf5} .. \ + -DBUILD_TESTING:BOOL=%{?tests:ON}%{!?tests:OFF} popd make %{?_smp_mflags} -C %{_target_platform} @@ -77,6 +88,19 @@ make install/fast DESTDIR=%{buildroot} -C %{_target_platform} %find_lang ktexteditor5_qt --with-qt --all-name +# create/own dirs +mkdir -p %{buildroot}%{_kf5_qtplugindir}/ktexteditor + + +%check +%if 0%{?tests} +export CTEST_OUTPUT_ON_FAILURE=1 +xvfb-run -a \ +dbus-launch --exit-with-session \ +time \ +make test ARGS="--output-on-failure --timeout 300" -C %{_target_platform} ||: +%endif + %post -p /sbin/ldconfig %postun -p /sbin/ldconfig @@ -86,6 +110,7 @@ make install/fast DESTDIR=%{buildroot} -C %{_target_platform} %license COPYING.LIB %{_kf5_libdir}/libKF5TextEditor.so.* %{_kf5_plugindir}/parts/katepart.so +%{_kf5_qtplugindir}/ktexteditor/ %{_kf5_datadir}/kservices5/katepart.desktop %{_kf5_datadir}/kservicetypes5/*.desktop %{_kf5_datadir}/katepart5/ @@ -99,6 +124,12 @@ make install/fast DESTDIR=%{buildroot} -C %{_target_platform} %changelog +* Sat Apr 30 2016 Rex Dieter - 5.21.0-2 +- update URL +- support bootstrap +- add %%check +- own %%{_kf5_qtplugindir}/ktexteditor + * Mon Apr 04 2016 Rex Dieter - 5.21.0-1 - KDE Frameworks 5.21.0