pkgbase=calligra pkgname=('calligra' 'calligra-l10n') pkgver=4.0.1 _commit=b8dafa18b841ac44608f60ad58834e493910f806 pkgrel=1 arch=('x86_64') pkgdesc="Suite is a collection of office applications linked together by a common base." url='https://www.calligra-suite.org' license=('FDL1.2' 'GPL2' 'LGPL') makedepends=('karchive6' 'kcompletion6' 'kconfig6' 'kconfigwidgets6' 'kcoreaddons6' 'kcrash6' 'kdbusaddons6' 'kguiaddons6' 'ki18n6' 'kiconthemes6' 'kitemviews6' 'kjobwidgets6' 'kcmutils6' 'kio6' 'knotifications6' 'knotifyconfig6' 'sonnet6' 'ktextwidgets6' 'kwidgetsaddons6' 'kwindowsystem6' 'kxmlgui6' 'eigen3' 'freetds' 'libvisio' 'libgsf' 'libwpd' 'libwpg' 'libwps' 'pstoedit' 'gsl' 'lcms2' 'libodfgen' 'fftw' 'hicolor-icon-theme' 'libgit2' 'sqlite3' 'libkdcraw6' 'qt6-declarative' 'qt6-svg' 'qtkeychain-qt6' 'kdiagram' 'openexr' 'vc' 'akonadi-contacts' 'poppler' 'okular' 'extra-cmake-modules' 'kdoctools6' 'boost' 'docbook-xsl') # 'clang' vc fails clang 'kreport' 'kcalendarcore6' 'kcontacts6' source=("https://download.kde.org/stable/${pkgbase}/${pkgbase}-${pkgver}.tar.xz" #source=("https://invent.kde.org/office/calligra/-/archive/${_commit}/calligra-${_commit}.tar.bz2" 'cpp17.patch' "https://invent.kde.org/office/calligra/-/commit/eab11436712f92afc6e7b14b25d1f6df217d79d7.diff" "https://invent.kde.org/office/calligra/-/commit/c7636fb343c848000300a9429410b74d17a4d54d.diff") #source=("https://share.kde.org/index.php/s/yanrJWiQFB3rrvc/download?path=%2F&files=${pkgbase}-${pkgver}.tar.xz") sha256sums=('d401f5e73f4f1bdc0b3548ea1a50b0ac1778c1ede30a6a335944ed7fbd88d95f' '732fcc81b8d47b0720d83d514b7fdbbb6a3b6f3c35171066684dfb6e09fc51cd' '3575f42f5d3ec76a020f41d0be6998d4369b31bc279792a7fb13d7becc59fc26' 'aeb7660a07f548fb2c32834ba55740040e6ca579541600ba304ef8a07da6b7f3') prepare() { cd ${pkgbase}-${pkgver} #patch -p1 -i ${srcdir}/cpp17.patch #patch -p1 -i ${srcdir}/eab11436712f92afc6e7b14b25d1f6df217d79d7.diff #patch -p1 -i ${srcdir}/c7636fb343c848000300a9429410b74d17a4d54d.diff #sed -i 's|add_subdirectory( import )|#add_subdirectory( import )|' filters/words/wordperfect/CMakeLists.txt } build() { mkdir -p build cd build #export CC=/usr/bin/clang #export CXX=/usr/bin/clang++ cmake ../${pkgbase}-${pkgver} \ -DCMAKE_BUILD_TYPE=RelWithDebInfo \ -DCMAKE_INSTALL_PREFIX=/usr \ -DCMAKE_INSTALL_LIBDIR=lib \ -DBUILD_TESTING=FALSE \ -DPACKAGERS_BUILD=true \ -DBUILD_UNMAINTAINED=FALSE \ -DQT_MAJOR_VERSION=6 make } package_calligra() { pkgdesc="Suite is a collection of office applications linked together by a common base." depends=('karchive6' 'kcompletion6' 'kconfig6' 'kconfigwidgets6' 'kcoreaddons6' 'kcrash6' 'kdbusaddons6' 'kguiaddons6' 'ki18n6' 'kiconthemes6' 'kitemviews6' 'kjobwidgets6' 'kcmutils6' 'kio6' 'knotifications6' 'knotifyconfig6' 'sonnet6' 'ktextwidgets6' 'kwidgetsaddons6' 'kwindowsystem6' 'kxmlgui6' 'eigen3' 'freetds' 'libvisio' 'libgsf' 'libwpd' 'libwpg' 'libwps' 'pstoedit' 'gsl' 'lcms2' 'libodfgen' 'fftw' 'hicolor-icon-theme' 'sqlite3' 'libkdcraw6' 'exiv2' 'qt6-declarative' 'kdiagram' 'okular' 'poppler' 'openexr' 'vc' 'akonadi-contacts') # 'kcalendarcore6' 'kcontacts6' 'kreport' cd build make DESTDIR=${pkgdir} install #rm ${pkgdir}/usr/share/applications/calligra_filter_odt2docx.desktop #use in calligra-l10n mv ${pkgdir}/usr/share/locale ${srcdir}/ } package_calligra-l10n() { pkgdesc="Localization for Calligra" depends=('ki18n6') groups=('localization') install -d -m755 ${pkgdir}/usr/share/locale mv ${srcdir}/locale ${pkgdir}/usr/share }