File gwenview.spec of Package gwenview4
#
# spec file for package gwenview
#
# Copyright (c) 2014 SUSE LINUX Products 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/
#
Name: gwenview
Version: 4.14.3
Release: 0
Summary: Simple Image Viewer for KDE
License: GPL-2.0+
Group: Productivity/Graphics/Viewers
Url: http://www.kde.org
Source0: %{name}-%{version}.tar.xz
# PATCH-FIX-UPSTREAM
Patch0: 0001-Compile-more-files-with-enabled-exceptions-required-.patch
Patch1: 0002-Use-forward-declaration-for-Exiv2-Image-port-to-std-.patch
Patch2: Fix-build-with-exiv2-0.27.1.patch
Patch3: Fix-building-against-Exiv2-main-branch.patch
Patch4: Fix-build-with-exiv2_0.28.patch
BuildRequires: baloo-devel
BuildRequires: libexiv2-devel
BuildRequires: libkactivities-devel
BuildRequires: libkdcraw-devel
BuildRequires: libkipi-devel
BuildRequires: libkonq-devel
BuildRequires: liblcms2-devel
BuildRequires: xz
Recommends: kipi-plugins
Provides: kde4-gwenview = 4.2.90
Obsoletes: kde4-gwenview < 4.2.90
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%kde4_runtime_requires
# Needed for 42.3
%if 0%{?suse_version} < 1330
# It does not build with the default compiler (GCC 4.8) on Leap 42.x
%if 0%{?sle_version} < 120300
BuildRequires: gcc6-c++
%else
BuildRequires: gcc7-c++
%endif
%endif
%description
Gwenview is a simple image viewer for KDE. It features a folder tree
window and a file list window, providing easy navigation of your file
hierarchy.
%prep
%autosetup -p1
%build
%if 0%{?suse_version} < 1330
# It does not build with the default compiler (GCC 4.8) on Leap 42.x
%if 0%{?sle_version} < 120300
export CC=gcc-6
export CXX=g++-6
%else
export CC=gcc-7
export CXX=g++-7
%endif
%endif
%cmake_kde4 -d build
%make_jobs
%install
cd build
%kde4_makeinstall
%suse_update_desktop_file -r gwenview Graphics RasterGraphics Viewer
%kde_post_install
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files
%defattr(-,root,root)
%doc COPYING
%{_kde4_appsdir}/gwenview/
%{_kde4_appsdir}/gvpart/
%{_kde4_appsdir}/solid
%{_kde4_applicationsdir}/gwenview.desktop
%{_kde4_bindir}/gwenview
%{_kde4_bindir}/gwenview_importer
%{_kde4_htmldir}/en/gwenview/
%{_kde4_libdir}/libgwenviewlib.*
%{_kde4_modulesdir}/gvpart.so
%{_kde4_servicesdir}/gvpart.desktop
%{_kde4_servicesdir}/ServiceMenus/slideshow.desktop
%{_kde4_iconsdir}/hicolor/*/*/*
%changelog