File calligra.spec of Package calligra

#
# spec file for package calligra
#
# 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/
#


Name:           calligra
Version:        2.9.8
Release:        0
Summary:        Libraries and Base Files for the KDE Office Suite
License:        GPL-2.0+ and LGPL-2.1+ and GFDL-1.2
Group:          Productivity/Office/Suite
Url:            http://www.calligra.org/
Source0:        http://download.kde.org/stable/%{name}-%{version}/%{name}-%{version}.tar.xz
# PATCH-FIX-OPENSUSE adapt-to-libwps-0.4.patch boo#942107 -- makes it build against libwps 0.4 (taken from Fedora)
Patch:          adapt-to-libwps-0.4.patch
%if 0%{?suse_version} > 1230
BuildRequires:  OpenColorIO-devel
%endif
BuildRequires:  OpenEXR-devel
%if 0%{?suse_version} > 1320
BuildRequires:  Vc-devel-static
%endif
BuildRequires:  create-resources
BuildRequires:  eigen3-devel
BuildRequires:  fdupes
BuildRequires:  fftw3-devel
BuildRequires:  freetds-devel
BuildRequires:  libgsf-devel
BuildRequires:  libicu-devel
BuildRequires:  libkdcraw-devel
BuildRequires:  libkdepimlibs4-devel
BuildRequires:  libmysqld-devel
BuildRequires:  libpqxx-devel
BuildRequires:  librcps-devel
BuildRequires:  libspnav-devel
BuildRequires:  marble-devel
BuildRequires:  mysql-devel
BuildRequires:  okular-devel
BuildRequires:  openjpeg-devel
BuildRequires:  postgresql-devel
BuildRequires:  pstoedit
BuildRequires:  sqlite-devel
BuildRequires:  xbase-devel
BuildRequires:  pkgconfig(QtWebKit)
BuildRequires:  pkgconfig(exiv2)
BuildRequires:  pkgconfig(gl)
BuildRequires:  pkgconfig(glew)
BuildRequires:  pkgconfig(glu)
BuildRequires:  pkgconfig(gsl)
BuildRequires:  pkgconfig(lcms)
BuildRequires:  pkgconfig(lcms2)
BuildRequires:  pkgconfig(libkactivities)
BuildRequires:  pkgconfig(poppler-qt4)
BuildRequires:  pkgconfig(qca2)
%if 0%{?suse_version} > 1310
BuildRequires:  libetonyek-devel >= 0.1.0
BuildRequires:  libodfgen-devel >= 0.1.0
BuildRequires:  librevenge-devel >= 0.0.0
BuildRequires:  pkgconfig(libvisio-0.1)
BuildRequires:  pkgconfig(libwpd-0.10)
BuildRequires:  pkgconfig(libwpg-0.3)
%if 0%{?suse_version} > 1320 || 0%{?is_opensuse}
BuildRequires:  pkgconfig(libwps-0.4)
%else
BuildRequires:  pkgconfig(libwps-0.3)
%endif
%else
BuildRequires:  libodfgen-devel
BuildRequires:  libvisio-devel
BuildRequires:  libwpd-devel
BuildRequires:  libwpg-devel
BuildRequires:  libwps-devel
%endif
Requires(post): shared-mime-info
Requires(postun): shared-mime-info
Recommends:     %{name}-doc = %{version}
Recommends:     kdepim4-runtime
Suggests:       calligra-braindump
Suggests:       calligra-flow
Suggests:       calligra-karbon
Suggests:       calligra-kexi
Suggests:       calligra-krita
Suggests:       calligra-plan
Suggests:       calligra-sheets
Suggests:       calligra-stage
Suggests:       calligra-words
# calligra-kformula was last used at version 2.3.73 in KDE:Unstable:Playground
Provides:       calligra-kformula = %{version}
Obsoletes:      calligra-kformula < %{version}
# calligra-kthesaurus was last used at version 2.4.92 in KDE:Release:49
Provides:       calligra-kthesaurus = %{version}
Obsoletes:      calligra-kthesaurus < %{version}
# koffice2 was last used at version 2.3.1 in openSUSE 12.1
Obsoletes:      koffice2 < %{version}
Obsoletes:      koffice2-kformula < %{version}
Obsoletes:      koffice2-kthesaurus < %{version}
%kde4_runtime_requires
%kde4_pimlibs_requires
Requires(post): shared-mime-info
Requires(postun): shared-mime-info
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
The Calligra Suite is a set of applications that allows you to easily complete
your work. There are office applications, as well as Graphic applications.
There is also a comprehensive set of plug-ins. The Calligra Suite is unique
because not only does it consist of the normal word processor (Words) and
spreadsheet (Sheets) applications, but it also brings you Graphic applications
as well.

The Calligra Suite consists of 8 applications, the office applications are
Words, Sheets, Stage, Kexi, Flow, and Plan, and the graphic applications are
Krita and Karbon. Each application is unique and aimed towards normal personal
and professional uses.

This package contains the base files and libraries for the Suite.

%package author
Summary:        Minimalistic Word Processor
License:        GPL-2.0 and GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
Requires:       calligra-words-common = %{version}
%{kde4_runtime_requires}

%description author
Author is the minimalistic word processor application of the Calligra Suite.

%package braindump
Summary:        Mind Mapper Application
License:        GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
%{kde4_runtime_requires}

%description braindump
Braindump is the mind mapper application of the Calligra Suite.

%package devel
Summary:        The Build Enviroment from the KDE Office Suite
License:        GPL-2.0+ and LGPL-2.1+
Group:          Development/Libraries/KDE
Requires:       %{name} = %{version}
Requires:       calligra-flow
Requires:       calligra-karbon
Requires:       calligra-kexi
Requires:       calligra-krita
Requires:       calligra-plan
Requires:       calligra-sheets
Requires:       calligra-words-common
# koffice2 was last used at version 2.3.1 in openSUSE 12.1
Obsoletes:      koffice2-devel < %{version}

%description devel
This package contains the build environment needed to compile Calligra
applications.

%package doc
Summary:        Documentation of the Calligra Suite
License:        GFDL-1.2
Group:          Documentation/HTML
Requires:       %{name} = %{version}
BuildArch:      noarch

%description doc
Documentation of the Calligra Office Suite applications.

%package flow
Summary:        Flow Chart Drawing Application
License:        GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
Requires:       %{name} = %{version}
# koffice2 was last used at version 2.3.1 in openSUSE 12.1
Obsoletes:      koffice2-kivio < %{version}
%{kde4_runtime_requires}

%description flow
Flow is the flow chart drawing application of the Calligra Suite.

%package active
Summary:        Tablet UI
License:        GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
Requires:       %{name} = %{version}
%{kde4_runtime_requires}

%description active
Calligra interface tailored specifically for use with Plasma Active on tablet
devices.

%package gemini
Summary:        Traditional Desktop and Touch Friendly Interface
License:        GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
Requires:       %{name} = %{version}
%{kde4_runtime_requires}

%description gemini
A combination between a traditional desktop application and a touch friendly
application for Calligra Words and Stage.

%package karbon
Summary:        Vector Drawing Application
License:        GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
Requires:       %{name} = %{version}
Requires:       pstoedit
# koffice2 was last used at version 2.3.1 in openSUSE 12.1
Obsoletes:      koffice2-karbon < %{version}
%{kde4_runtime_requires}

%description karbon
Karbon is the vector drawing application of the Calligra Suite.

%package kexi
Summary:        Database Application
License:        GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
Requires:       %{name} = %{version}
Requires:       libktexteditor
Recommends:     kexi-sqlite3-driver
Suggests:       kexi-mssql-driver
Suggests:       kexi-mysql-driver
Suggests:       kexi-postgresql-driver
Suggests:       kexi-spreadsheet-import
Suggests:       kexi-xbase-driver
# koffice2 was last used at version 2.3.1 in openSUSE 12.1
Obsoletes:      koffice2-kexi < %{version}
%{kde4_runtime_requires}

%description kexi
Kexi is the database application of the Calligra Suite.

%package kexi-mssql-driver
Summary:        Database Application - MS SQL & Sybase Server driver
License:        GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
%{kde4_runtime_requires}

%description kexi-mssql-driver
Kexi is the database application of the Calligra Suite.

This package contains Kexi MS SQL & Sybase Server driver.

%package kexi-mysql-driver
Summary:        Database Application - MySQL driver
License:        GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
%{kde4_runtime_requires}

%description kexi-mysql-driver
Kexi is the database application of the Calligra Suite.

This package contains Kexi MySQL driver.

%package kexi-postgresql-driver
Summary:        Database Application - PostgreSQL driver
License:        GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
%{kde4_runtime_requires}

%description kexi-postgresql-driver
Kexi is the database application of the Calligra Suite.

This package contains Kexi PostgreSQL driver.

%package kexi-spreadsheet-import
Summary:        Spreadsheet-to-Kexi-table import plugin
License:        GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
%{kde4_runtime_requires}

%description kexi-spreadsheet-import
Kexi is the database application of the Calligra Suite.

This package contains a Spreadsheet-to-Kexi-table import plugin.

%package kexi-sqlite3-driver
Summary:        Database Application - SQLite3 driver
License:        GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
%{kde4_runtime_requires}

%description kexi-sqlite3-driver
Kexi is the database application of the Calligra Suite.

This package contains Kexi SQLite3 driver.

%package kexi-xbase-driver
Summary:        Database Application - XBase driver
License:        GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
%{kde4_runtime_requires}

%description kexi-xbase-driver
Kexi is the database application of the Calligra Suite.

This package contains Kexi XBase driver.

%package krita
Summary:        Image Manipulation Application
License:        GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
Requires:       %{name} = %{version}
Requires(post): shared-mime-info
Requires(postun): shared-mime-info
Recommends:     create-resources
Recommends:     libwacom2
Suggests:       kcm_tablet
# koffice2 was last used at version 2.3.1 in openSUSE 12.1
Obsoletes:      koffice2-krita < %{version}
%{kde4_runtime_requires}

%description krita
Krita is the image manipulation application of the Calligra Suite.

%package plan
Summary:        Project Management Application
License:        GPL-2.0 and GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
Requires:       %{name} = %{version}
# koffice2 was last used at version 2.3.1 in openSUSE 12.1
Obsoletes:      koffice2-kplato < %{version}
%{kde4_runtime_requires}
%{kde4_pimlibs_requires}

%description plan
Plan is the project management application of the Calligra Suite.

%package stage
Summary:        Application for Creating Presentations
License:        GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
Requires:       %{name} = %{version}
# koffice2 was last used at version 2.3.1 in openSUSE 12.1
Obsoletes:      koffice2-kpresenter < %{version}
%{kde4_runtime_requires}

%description stage
Stage is the presentation application of the Calligra Suite.

%package sheets
Summary:        Spreadsheet Application
License:        GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
Requires:       %{name} = %{version}
# koffice2 was last used at version 2.3.1 in openSUSE 12.1
Obsoletes:      koffice2-kspread < %{version}
%{kde4_runtime_requires}

%description sheets
Sheets is the spreadsheet application of the Calligra Suite.

%package tools
Summary:        Various tools for the Calligra Suite
License:        GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
Requires:       %{name} = %{version}
%{kde4_runtime_requires}

%description tools
This package contains various tools for the Calligra Suite.

%package words
Summary:        Word Processor
License:        GPL-2.0 and GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
Requires:       %{name} = %{version}
Requires:       calligra-words-common = %{version}
# koffice2 was last used at version 2.3.1 in openSUSE 12.1
Obsoletes:      koffice2-kword < %{version}
%{kde4_runtime_requires}

%description words
Words is the word processor application of the Calligra Suite.

%package words-common
Summary:        Common files for the Author and Word Processor
License:        GPL-2.0 and GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
Requires:       %{name} = %{version}
%{kde4_runtime_requires}

%description words-common
Common files for the Author and Words applications of the Calligra Suite.

%package extras-converter
Summary:        Commandline tool for conversion
License:        GPL-2.0 and GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
%{kde4_runtime_requires}

%description extras-converter
Commandline tool for conversion between any file formats for which
there is a chain of Calligra import/export filters.

%package extras-okular
Summary:        Plugin for Okular
License:        GPL-2.0 and GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
Requires:       calligra-stage = %{version}
Supplements:    packageand(%{name}-stage:okular)
%{kde4_runtime_requires}

%description extras-okular
Plugins for Okular supporting files in the formats ODP, ODT, MS DOC/DOCX, MS PPT/PPTX, and WPD.

%package extras-dolphin
Summary:        Diverse plugins for Dolphin
License:        GPL-2.0 and GPL-2.0+ and LGPL-2.1+
Group:          Productivity/Office/Suite
Supplements:    packageand(%{name}:dolphin)
%{kde4_runtime_requires}

%description extras-dolphin
Plugin for the Dolphin file properties dialog, displaying the
metadata of files in the ODF formats and a plugin adding a "Print"
action for several formats to the filemanager context menu and
calling the related Calligra programs.

%prep
%setup -q
%if 0%{?suse_version} > 1320 || 0%{?is_opensuse}
%patch -p1
%endif

# Remove build time references so build-compare can do its work
FAKE_BUILDTIME=$(LC_ALL=C date -u -r %{_sourcedir}/%{name}.changes '+%%H:%%M')
FAKE_BUILDDATE=$(LC_ALL=C date -u -r %{_sourcedir}/%{name}.changes '+%%b %%e %%Y')
sed -i "s/__TIME__/\"$FAKE_BUILDTIME\"/" krita/plugins/extensions/gmic/3rdparty/gmic/CImg.h
sed -i "s/__DATE__/\"$FAKE_BUILDDATE\"/" krita/plugins/extensions/gmic/3rdparty/gmic/CImg.h
# icons are missing
sed -i /^Icon=calligramobile/d active/calligraactive.desktop
sed -i /^Icon=calligragemini/d gemini/calligragemini.desktop

%build
%cmake_kde4 -d build -- -DIHAVEPATCHEDQT=true
%{make_jobs}

%install
cd build
%{kde4_makeinstall}

# Create filelists
%create_subdir_filelist -d 3rdparty -f main -v devel
%create_subdir_filelist -d active -f active -v devel
%create_subdir_filelist -d braindump -v devel
%create_subdir_filelist -d data -f main -v devel
%create_subdir_filelist -d devtools -f tools -v devel
# TODO how to split this?
%create_subdir_filelist -d extras/calligra -f main -v devel
%create_subdir_filelist -d extras/converter -f converter -v devel
%create_subdir_filelist -d extras/filemanagertemplates -f dolphin -v devel
%create_subdir_filelist -d extras/okularodpgenerator -f okular -v devel
%create_subdir_filelist -d extras/properties -f dolphin -v devel
%create_subdir_filelist -d extras/quickprint -f dolphin -v devel
%create_subdir_filelist -d extras/thumbnail -f main -v devel
%create_subdir_filelist -d filters/flow -f flow -v devel
%create_subdir_filelist -d filters/karbon -f karbon -v devel
%create_subdir_filelist -d filters/libmso -f main -v devel
%create_subdir_filelist -d filters/libmsooxml -f main -v devel
%create_subdir_filelist -d filters/libodf2 -f main -v devel
%create_subdir_filelist -d filters/libodfreader -f main -v devel
%create_subdir_filelist -d filters/plan -f plan -v devel
%create_subdir_filelist -d filters/sheets -f sheets -v devel
%create_subdir_filelist -d filters/stage -f stage -v devel
%create_subdir_filelist -d filters/words -f words -v devel
%create_subdir_filelist -d flow -v devel
%create_subdir_filelist -d gemini -v devel
%create_subdir_filelist -d interfaces -f main -v devel
%create_subdir_filelist -d karbon -v devel
%create_subdir_filelist -d kexi -v devel
%create_subdir_filelist -d krita -v devel
%create_subdir_filelist -d libs -f main -v devel
%create_subdir_filelist -d pics -f main -v devel
%create_subdir_filelist -d plan -v devel
%create_subdir_filelist -d plugins -f main -v devel
%create_subdir_filelist -d servicetypes -f main -v devel
%create_subdir_filelist -d sheets -v devel
%create_subdir_filelist -d stage -f stage -v devel
%create_subdir_filelist -d words -v devel
cd ..

# Remove doc files from filelists (packaged in calligra-doc)
sed -ri s,.*%{_datadir}/doc/kde/HTML/en/.*,, filelists/*

# Remove ome sketch files from krita filelist (filelists doesn't like spaces in filenames)
sed -ri s,.*/calligra/imports/org/krita/sketch/panels/filterconfigpages/.*,, filelists/krita

# Do not use fdupes in %%{buildroot} as this causes icons in the calligra-package to be symlinks against the kexi-package, so that these are missing in krita (bnc#688012)
%fdupes -s %{buildroot}%{_kde4_datadir}/color/icc/krita/
%fdupes -s %{buildroot}%{_kde4_datadir}/locale/
%fdupes -s %{buildroot}%{_kde4_appsdir}/calligra/
%fdupes -s %{buildroot}%{_kde4_appsdir}/flow/stencils/
%fdupes -s %{buildroot}%{_kde4_appsdir}/kexi/
%fdupes -s %{buildroot}%{_kde4_appsdir}/krita/
%fdupes -s %{buildroot}%{_kde4_iconsdir}/
%fdupes -s %{buildroot}%{_kde4_includedir}/

%suse_update_desktop_file -r author     Qt KDE Office WordProcessor
%suse_update_desktop_file -r braindump  Qt KDE Office Database
%suse_update_desktop_file -r calligraactive Qt KDE Graphics RasterGraphics
%suse_update_desktop_file -r calligragemini Qt KDE Office WordProcessor Presentation
%suse_update_desktop_file -r flow       Qt KDE Office FlowChart
%suse_update_desktop_file -r karbon     Qt KDE Graphics VectorGraphics
%suse_update_desktop_file -r kexi       Qt KDE Office Database
%suse_update_desktop_file -r krita      Qt KDE Graphics RasterGraphics
%suse_update_desktop_file -r plan       Qt KDE Office ProjectManagement
%suse_update_desktop_file -r planwork   Qt KDE Office ProjectManagement
%suse_update_desktop_file -r stage      Qt KDE Office Presentation
%suse_update_desktop_file -r sheets     Qt KDE Office Spreadsheet
%suse_update_desktop_file -r words      Qt KDE Office WordProcessor

%{kde_post_install}

%post
/sbin/ldconfig
%{_bindir}/update-mime-database %{_kde4_datadir}/mime > /dev/null 2>&1 || :

%postun
/sbin/ldconfig
%{_bindir}/update-mime-database %{_kde4_datadir}/mime > /dev/null 2>&1 || :

%post   author -p /sbin/ldconfig

%postun author -p /sbin/ldconfig

%post   braindump -p /sbin/ldconfig

%postun braindump -p /sbin/ldconfig

%post   flow -p /sbin/ldconfig

%postun flow -p /sbin/ldconfig

%post   karbon -p /sbin/ldconfig

%postun karbon -p /sbin/ldconfig

%post   kexi -p /sbin/ldconfig

%postun kexi -p /sbin/ldconfig

%post krita
/sbin/ldconfig
%{_bindir}/update-mime-database %{_kde4_datadir}/mime > /dev/null 2>&1 || :

%postun krita
/sbin/ldconfig
%{_bindir}/update-mime-database %{_kde4_datadir}/mime > /dev/null 2>&1 || :

%post   plan -p /sbin/ldconfig

%postun plan -p /sbin/ldconfig

%post   sheets -p /sbin/ldconfig

%postun sheets -p /sbin/ldconfig

%post   stage -p /sbin/ldconfig

%postun stage -p /sbin/ldconfig

%post   tools -p /sbin/ldconfig

%postun tools -p /sbin/ldconfig

%post   words -p /sbin/ldconfig

%postun words -p /sbin/ldconfig

%post   words-common -p /sbin/ldconfig

%postun words-common -p /sbin/ldconfig

%files -f filelists/main
%defattr(-,root,root,-)
%doc COPYING COPYING.LIB README
%{_kde4_applicationsdir}/calligra.desktop
%dir %{_kde4_datadir}/*
%dir %{_kde4_datadir}/*/*
%dir %{_kde4_datadir}/*/*/*
%dir %{_kde4_appsdir}/*
%dir %{_kde4_appsdir}/*/*
%dir %{_kde4_appsdir}/*/*/*
%dir %{_kde4_appsdir}/*/*/*/*
%dir %{_kde4_appsdir}/*/*/*/*/*
%dir %{_kde4_sharedir}/*
%dir %{_kde4_sharedir}/*/.source
%dir %{_kde4_iconsdir}/hicolor/*
%dir %{_kde4_iconsdir}/hicolor/*/*
%dir %{_kde4_servicesdir}/calligra/
%dir %{_kde4_servicesdir}/ServiceMenus
%dir %{_kde4_servicesdir}/ServiceMenus/calligra
%dir %{_libdir}/calligra/imports/org/calligra
%exclude %{_kde4_modulesdir}/kexi*.so
%exclude %{_kde4_servicesdir}/calligra/keximigrate_spreadsheet.desktop
%exclude %{_kde4_servicesdir}/calligra/kexidb_sqlite3driver.desktop
%{_libdir}/calligra/imports/org/calligra/CalligraComponents

%files devel -f filelists/devel
%defattr(-,root,root,-)
%{_kde4_appsdir}/cmake/modules/FindCalligraLibs.cmake
%{_kde4_includedir}/*

%files extras-converter -f filelists/converter
%defattr(-,root,root,-)

%files extras-dolphin -f filelists/dolphin
%defattr(-,root,root,-)

%files extras-okular -f filelists/okular
%defattr(-,root,root,-)
%{_kde4_applicationsdir}/okularApplication_doc_calligra.desktop
%{_kde4_applicationsdir}/okularApplication_docx_calligra.desktop
%{_kde4_applicationsdir}/okularApplication_odt.desktop
%{_libdir}/kde4/okularGenerator_odt.so
%{_kde4_servicesdir}/okularDoc_calligra.desktop
%{_kde4_servicesdir}/okularDocx_calligra.desktop
%{_kde4_servicesdir}/okularOdt.desktop
%{_kde4_servicesdir}/libokularGenerator_doc_calligra.desktop
%{_kde4_servicesdir}/libokularGenerator_docx_calligra.desktop
%{_kde4_servicesdir}/libokularGenerator_odt.desktop
%if 0%{?suse_version} > 1310
# libwpd-0_9 in 13.1 is not supported
%{_kde4_applicationsdir}/okularApplication_wpd_calligra.desktop
%{_kde4_servicesdir}/okularWpd_calligra.desktop
%{_kde4_servicesdir}/libokularGenerator_wpd_calligra.desktop
%endif

%files active -f filelists/active
%defattr(-,root,root,-)

%files author
%defattr(-,root,root,-)
%{_kde4_applicationsdir}/author.desktop
%{_kde4_appsdir}/author/
%{_kde4_bindir}/calligraauthor
%{_kde4_configdir}/authorrc
%{_kde4_iconsdir}/hicolor/*/apps/calligraauthor.*
%{_kde4_libdir}/libkdeinit4_calligraauthor.so

%files braindump -f filelists/braindump
%defattr(-,root,root,-)
%doc braindump/COPYING
%dir %{_kde4_appsdir}/stateshape/
%dir %{_kde4_appsdir}/stateshape/states

%files doc
%defattr(-,root,root,-)
%doc COPYING.DOC
%doc %lang(en) %{_kde4_htmldir}/en/calligra/
%doc %lang(en) %{_kde4_htmldir}/en/kexi/
%doc %lang(en) %{_kde4_htmldir}/en/sheets/
%doc %lang(en) %{_kde4_htmldir}/en/stage/

%files gemini -f filelists/gemini
%defattr(-,root,root,-)
%dir %{_libdir}/calligra/imports/Calligra
%dir %{_libdir}/calligra/imports/Calligra/Gemini
%dir %{_libdir}/calligra/imports/Calligra/Gemini/Dropbox

%files flow -f filelists/flow
%defattr(-,root,root,-)
%doc flow/AUTHORS flow/CHANGELOG flow/CHANGES flow/LICENSE flow/NOTES flow/README

%files karbon -f filelists/karbon
%defattr(-,root,root,-)
%doc karbon/AUTHORS karbon/CHANGES karbon/COPYING.LIB karbon/IDEAS karbon/README karbon/TODO

%files kexi -f filelists/kexi
%defattr(-,root,root,-)
%doc kexi/CHANGES kexi/README
%dir %{_kde4_servicesdir}/calligra/
# Included in kexi-*-driver packages
%exclude %{_kde4_modulesdir}/kexi*_mysql*.so
%exclude %{_kde4_servicesdir}/calligra/kexi*_mysql*.desktop
%exclude %{_kde4_modulesdir}/kexi*_pqxx*.so
%exclude %{_kde4_servicesdir}/calligra/kexi*_pqxx*.desktop
%exclude %{_kde4_modulesdir}/kexi*_sqlite3*.so
%exclude %{_kde4_servicesdir}/calligra/kexi*_sqlite3*.desktop
%exclude %{_kde4_modulesdir}/kexi*_sybase*.so
%exclude %{_kde4_servicesdir}/calligra/kexi*_sybase*.desktop
%exclude %{_kde4_modulesdir}/kexi*_xbase*.so
%exclude %{_kde4_servicesdir}/calligra/kexi*_xbase*.desktop
%exclude %{_kde4_modulesdir}/keximigrate_spreadsheet.so
%exclude %{_kde4_servicesdir}/calligra/keximigrate_spreadsheet.desktop

%files kexi-mssql-driver
%defattr(-,root,root,-)
%{_kde4_modulesdir}/kexidb_sybasedriver.so
%{_kde4_modulesdir}/keximigrate_sybase.so
%{_kde4_servicesdir}/calligra/kexidb_sybasedriver.desktop
%{_kde4_servicesdir}/calligra/keximigrate_sybase.desktop

%files kexi-mysql-driver
%defattr(-,root,root,-)
%{_kde4_modulesdir}/kexidb_mysqldriver.so
%{_kde4_modulesdir}/keximigrate_mysql.so
%{_kde4_servicesdir}/calligra/kexidb_mysqldriver.desktop
%{_kde4_servicesdir}/calligra/keximigrate_mysql.desktop

%files kexi-postgresql-driver
%defattr(-,root,root,-)
%{_kde4_modulesdir}/kexidb_pqxxsqldriver.so
%{_kde4_modulesdir}/keximigrate_pqxx.so
%{_kde4_servicesdir}/calligra/kexidb_pqxxsqldriver.desktop
%{_kde4_servicesdir}/calligra/keximigrate_pqxx.desktop

%files kexi-spreadsheet-import
%defattr(-,root,root,-)
%{_kde4_modulesdir}/keximigrate_spreadsheet.so
%{_kde4_servicesdir}/calligra/keximigrate_spreadsheet.desktop

%files kexi-sqlite3-driver
%defattr(-,root,root,-)
%{_kde4_modulesdir}/kexidb_sqlite3_icu.so
%{_kde4_modulesdir}/kexidb_sqlite3driver.so
%{_kde4_servicesdir}/calligra/kexidb_sqlite3driver.desktop

%files kexi-xbase-driver
%defattr(-,root,root,-)
%{_kde4_modulesdir}/kexidb_xbasedriver.so
%{_kde4_modulesdir}/keximigrate_xbase.so
%{_kde4_servicesdir}/calligra/kexidb_xbasedriver.desktop
%{_kde4_servicesdir}/calligra/keximigrate_xbase.desktop

%files krita -f filelists/krita
%defattr(-,root,root,-)
%doc krita/AUTHORS krita/README
%dir %{_datadir}/color/icc/krita/
%dir %{_kde4_appsdir}/kritaplugins/
%dir %{_kde4_appsdir}/kritaplugins/metadataeditor
%dir %{_libdir}/calligra
%dir %{_libdir}/calligra/imports
%dir %{_libdir}/calligra/imports/org
%dir %{_libdir}/calligra/imports/org/krita
%dir %{_libdir}/calligra/imports/org/krita/draganddrop

%files plan -f filelists/plan
%defattr(-,root,root,-)
%doc plan/CHANGELOG plan/TODO plan/examples/
%dir %{_kde4_modulesdir}/planconvert/
%{_kde4_appsdir}/planwork/

%files stage -f filelists/stage
%defattr(-,root,root,-)
%doc stage/AUTHORS stage/CHANGES stage/TODO

%files sheets -f filelists/sheets
%defattr(-,root,root,-)
%doc sheets/AUTHORS sheets/CHANGES sheets/README sheets/TODO
%{_kde4_appsdir}/sheets/

%files tools -f filelists/tools
%defattr(-,root,root,-)

%files words
%defattr(-,root,root,-)
%{_kde4_applicationsdir}/calligrawords_ascii.desktop
%{_kde4_applicationsdir}/words.desktop
%{_kde4_appsdir}/words/words.rc
%{_kde4_appsdir}/words/words_readonly.rc
%{_kde4_bindir}/calligrawords
%{_kde4_configdir}/wordsrc
%{_kde4_iconsdir}/hicolor/*/apps/calligrawords.*
%{_kde4_libdir}/libkdeinit4_calligrawords.so

%files words-common -f filelists/words
%defattr(-,root,root,-)
%exclude %{_kde4_applicationsdir}/author.desktop
%exclude %{_kde4_applicationsdir}/calligrawords_ascii.desktop
%exclude %{_kde4_applicationsdir}/words.desktop
%exclude %{_kde4_applicationsdir}/okularApplication*.desktop
%exclude %{_kde4_appsdir}/author
%exclude %{_kde4_appsdir}/words/words.rc
%exclude %{_kde4_appsdir}/words/words_readonly.rc
%exclude %{_kde4_bindir}/calligraauthor
%exclude %{_kde4_bindir}/calligrawords
%exclude %{_kde4_configdir}/authorrc
%exclude %{_kde4_configdir}/wordsrc
%exclude %{_kde4_iconsdir}/hicolor/*/apps/calligraauthor.*
%exclude %{_kde4_iconsdir}/hicolor/*/apps/calligrawords.*
%exclude %{_kde4_libdir}/libkdeinit4_calligrawords.so
%exclude %{_kde4_libdir}/libkdeinit4_calligraauthor.so
%exclude %{_kde4_servicesdir}/okular*.desktop
%exclude %{_kde4_servicesdir}/libokularGenerator*.desktop
%dir %{_kde4_appsdir}/words/

%changelog
openSUSE Build Service is sponsored by