File plasma5-openSUSE.spec of Package plasma5-openSUSE.openSUSE_13.2_Update
#
# spec file for package plasma5-openSUSE
#
# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
%define plasma_version 5.2.1
Name: plasma5-openSUSE
Version: 13.2
Release: 0
Summary: openSUSE KDE Extension
License: GPL-2.0+
Group: System/GUI/KDE
# git clone git://github.com/openSUSE/kdebase-opensuse.git
Url: http://www.opensuse.org/
Source: plasma5-openSUSE-%{version}.tar.xz
Source2: oS.diff
Source3: plasma-change-defaults.diff
BuildRequires: extra-cmake-modules
BuildRequires: kdelibs4support-devel
BuildRequires: kf5-filesystem
BuildRequires: oxygen-icon-theme
BuildRequires: plasma5-desktop >= %plasma_version
BuildRequires: plasma5-desktop-branding-upstream >= %plasma_version
BuildRequires: plasma5-workspace >= %plasma_version
BuildRequires: update-desktop-files
Requires: plasma5-desktop-branding-openSUSE
Requires: plasma5-workspace-branding-openSUSE
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
This package contains the standard openSUSE desktop and extensions.
%package -n plasma5-desktop-branding-openSUSE
Summary: openSUSE KDE Extension
Group: System/GUI/KDE
PreReq: %fillup_prereq
Requires: plasma5-desktop >= %plasma_version
Requires: plasma5-workspace-branding-openSUSE = %{version}
Requires: plasma5-workspace-branding-openSUSE = %{version}
Requires: susegreeter-branding-openSUSE = %{version}
Requires: wallpaper-branding-openSUSE = %{version}
Supplements: packageand(plasma5-desktop:branding-openSUSE)
Provides: plasma5-desktop-branding = %{_plasma5_branding_version}
Conflicts: otherproviders(plasma5-desktop-branding)
%description -n plasma5-desktop-branding-openSUSE
This package contains the standard openSUSE desktop and extensions.
%package -n plasma5-workspace-branding-openSUSE
Summary: The KDE Runtime Components
Group: System/GUI/KDE
PreReq: %fillup_prereq
Supplements: packageand(plasma5-workspace:branding-openSUSE)
Provides: plasma5-workspace-branding = %{_plasma5_branding_version}
Conflicts: otherproviders(plasma5-workspace-branding)
Conflicts: plasma5-desktop-branding-upstream
Requires: plasma5-workspace >= %plasma_version
Requires: wallpaper-branding-openSUSE
Conflicts: kdebase4-openSUSE
Conflicts: kdebase4-workspace-branding-openSUSE
%description -n plasma5-workspace-branding-openSUSE
This package contains all run-time dependencies of KDE applications.
%prep
%setup -q -n %{name}
echo "OnlyShowIn=KDE;" >> greeter/SUSEgreeter.desktop
%build
pushd greeter
%cmake_kf5 -d build
%make_jobs
popd
%install
pushd greeter
%kf5_makeinstall -C build
popd
%suse_update_desktop_file -u %{buildroot}%{_kf5_applicationsdir}/SUSEgreeter.desktop System Documentation
mv config-files/COPYING .
cp -a config-files/* %{buildroot}
cp /usr/share/plasma/look-and-feel/org.kde.breeze.desktop/contents/splash/Splash.qml %{buildroot}%{_kf5_plasmadir}/look-and-feel/org.openSUSE.desktop/contents/splash/
cp /usr/share/plasma/look-and-feel/org.kde.breeze.desktop/contents/lockscreen/LockScreen.qml %{buildroot}%{_kf5_plasmadir}/look-and-feel/org.openSUSE.desktop/contents/lockscreen/
pushd %{buildroot}%{_kf5_plasmadir}/look-and-feel/org.openSUSE.desktop/contents/
ln -s ../../org.kde.breeze.desktop/contents/components .
patch -p0 < %{SOURCE2}
popd
pushd %{buildroot}%{_kf5_plasmadir}
mkdir -p %{buildroot}%{_kf5_plasmadir}/layout-templates/org.kde.plasma.desktop.defaultPanel/contents/
cp %{_kf5_plasmadir}/layout-templates/org.kde.plasma.desktop.defaultPanel/contents/layout.js %{buildroot}%{_kf5_plasmadir}/layout-templates/org.kde.plasma.desktop.defaultPanel/contents/layout.js
mkdir -p %{buildroot}%{_kf5_plasmadir}/shells/org.kde.plasma.desktop/contents/
cp %{_kf5_plasmadir}/shells/org.kde.plasma.desktop/contents/layout.js %{buildroot}%{_kf5_plasmadir}/shells/org.kde.plasma.desktop/contents/layout.js
patch -p0 < %{SOURCE3}
popd
%files
%defattr(-,root,root)
%doc COPYING
%files -n plasma5-workspace-branding-openSUSE
%defattr(-,root,root)
%doc COPYING
%config %{_kf5_configdir}/*rc
%config %{_kf5_configdir}/kdeglobals
%{_kf5_servicesdir}/
%{_kf5_sharedir}/color-schemes/
%{_kf5_sharedir}/icons/*/*/*/*.*
%{_kf5_plasmadir}/
%{_kf5_sharedir}/SUSEgreeter
%{_kf5_bindir}/SUSEgreeter
%{_kf5_applicationsdir}/SUSEgreeter.desktop
%{_kf5_configdir}/autostart/SUSEgreeter.desktop
%files -n plasma5-desktop-branding-openSUSE
%defattr(-,root,root)
%doc COPYING
%changelog