Blob Blame History Raw

Name:    kdeedu-data
Summary: Shared icons, artwork and data files for educational applications
Version: 14.12.1
Release: 2%{?dist}

License: GPLv2
URL:     https://projects.kde.org/projects/kde/kdeedu/kdeedu-data
%global revision %(echo %{version} | cut -d. -f3)
%if %{revision} >= 50
%global stable unstable
%else
%global stable stable
%endif
Source0: http://download.kde.org/%{stable}/applications/%{version}/src/%{name}-%{version}.tar.xz
BuildArch: noarch

BuildRequires: kde-filesystem
BuildRequires: extra-cmake-modules
BuildRequires: kf5-rpm-macros

Requires: hicolor-icon-theme
Requires: kde-filesystem

%description
%{summary}.


%prep
%setup -q


%build
mkdir %{_target_platform}
pushd %{_target_platform}
%{cmake_kf5} ..
popd

make %{?_smp_mflags} -C %{_target_platform}


%install
make install/fast DESTDIR=%{buildroot} -C %{_target_platform}

# previous packages shipped %%{_kde4_appsdir}/kvtml , so need to be careful
# not to try replacing that with a symlink.  let's go the other way
# alternatively, can consider using hard-links
mkdir -p %{buildroot}%{_kde4_appsdir}
mv %{buildroot}%{_datadir}/apps/kvtml %{buildroot}%{_kde4_appsdir}/kvtml
ln -s ../../kde4/apps/kvtml %{buildroot}%{_datadir}/apps/kvtml


%post
touch --no-create %{_datadir}/icons/hicolor &> /dev/null || :

%posttrans
gtk-update-icon-cache %{_datadir}/icons/hicolor &> /dev/null || :

%postun
if [ $1 -eq 0 ] ; then
touch --no-create %{_datadir}/icons/hicolor &> /dev/null || :
gtk-update-icon-cache %{_datadir}/icons/hicolor &> /dev/null || :
fi


%files
%{_kde4_appsdir}/kvtml/
%{_datadir}/apps/kvtml
%{_datadir}/icons/hicolor/*/*/*


%changelog
* Fri Jan 23 2015 Rex Dieter <rdieter@fedoraproject.org> 14.12.1-2
- Requires: hicolor-icon-theme
- use %%setup -q

* Fri Jan 16 2015 Rex Dieter <rdieter@fedoraproject.org>  14.12.1-1
- 14.12.1