From 1fe959b564ff4a59cb723ffca9d9a81531695d24 Mon Sep 17 00:00:00 2001 From: Dan Vrátil Date: Mar 23 2016 19:29:54 +0000 Subject: Initial import --- diff --git a/.gitignore b/.gitignore index e69de29..7cc44b6 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/kjots-5.0.1.tar.xz diff --git a/kjots.spec b/kjots.spec new file mode 100644 index 0000000..3e4e628 --- /dev/null +++ b/kjots.spec @@ -0,0 +1,115 @@ +Name: kjots +Summary: KDE Notes application +Version: 5.0.1 +Release: 2%{?dist} +License: GPLv2 +URL: https://projects.kde.org/projects/playground/pim/kjots + +%global revision %(echo %{version} | cut -d. -f3) +%if %{revision} >= 50 +%global stable unstable +%else +%global stable stable +%endif +Source0: http://download.kde.org/%{stable}/%{name}/%{version}/src/%{name}-%{version}.tar.xz + +## upstream patches +Patch0: 0001-fix-exec-in-desktop-file.patch + +BuildRequires: kf5-rpm-macros +BuildRequires: extra-cmake-modules + +BuildRequires: cmake(KF5KCMUtils) +BuildRequires: cmake(KF5KIO) +BuildRequires: cmake(KF5Config) +BuildRequires: cmake(KF5ConfigWidgets) +BuildRequires: cmake(KF5Parts) +BuildRequires: cmake(KF5Bookmarks) +BuildRequires: cmake(KF5XmlGui) + +BuildRequires: cmake(KF5Akonadi) +BuildRequires: cmake(KF5Mime) +BuildRequires: cmake(KF5AkonadiNotes) +BuildRequires: cmake(KF5PimTextEdit) +BuildRequires: cmake(KF5KontactInterface) + +BuildRequires: cmake(Grantlee5) + +# xsltproc +BuildRequires: libxslt + +BuildRequires: desktop-file-utils +BuildRequires: libappstream-glib + +%description +KJots is an application for writing and organizing notes. + +%prep +%setup -q -n %{name}-%{version} + +%patch0 -p1 -b .0001 + + +%build +mkdir -p %{_target_platform} +pushd %{_target_platform} +%{cmake_kf5} .. +popd + +make %{?_smp_mflags} -C %{_target_platform} + + +%install +make install/fast DESTDIR=%{buildroot} -C %{_target_platform} +# Fixed upstream in next release +mv %{buildroot}%{_kf5_datadir}/appdata/Kjots.appdata.xml \ + %{buildroot}%{_kf5_datadir}/appdata/org.kde.kjots.appdata.xml + +%find_lang kjots --with-kde + +%check +for f in %{buildroot}%{_kf5_datadir}/applications/*.desktop ; do + desktop-file-validate $f +done +appstream-util validate-relax --nonet %{buildroot}/%{_kf5_datadir}/appdata/*.appdata.xml + + +%post +touch --no-create %{_kf5_datadir}/icons/hicolor &> /dev/null ||: + +%posttrans +gtk-update-icon-cache %{_kf5_datadir}/icons/hicolor &> /dev/null ||: +update-desktop-database -q &> /dev/null ||: + +%postun +if [ $1 -eq 0 ] ; then + touch --no-create %{_kf5_datadir}/icons/hicolor &> /dev/null ||: + gtk-update-icon-cache %{_kf5_datadir}/icons/hicolor &> /dev/null ||: + update-desktop-database -q &> /dev/null ||: +fi + +%files -f kjots.lang +%license COPYING COPYING.LIB +%doc README +%{_kf5_bindir}/kjots +%{_kf5_qtplugindir}/kjotspart.so +%{_kf5_qtplugindir}/kcm_kjots.so +%{_kf5_datadir}/kservices5/kjotspart.desktop +%{_kf5_datadir}/kservices5/kjots_config_misc.desktop +%{_kf5_datadir}/applications/org.kde.kjots.desktop +%{_kf5_datadir}/appdata/org.kde.kjots.appdata.xml +%{_kf5_datadir}/icons/hicolor/*/apps/kjots.* +%{_kf5_datadir}/icons/oxygen/*/actions/* +%{_kf5_datadir}/kjots/ +%{_kf5_datadir}/kxmlgui5/kjots/ +%{_kf5_datadir}/config.kcfg/kjots.kcfg + +%changelog +* Mon Mar 14 2016 Daniel Vrátil - 5.0.1-2 +- fix url +- fix scriptlets +- fix %%license and %%doc +- validate appdata + +* Sat Feb 13 2016 Daniel Vrátil - 5.0.1-1 +- initial package diff --git a/sources b/sources index e69de29..7d59acb 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +edb0a82781dbb75d1fe69f2eb6f7cf28 kjots-5.0.1.tar.xz