268.2. okular-26.08.2
Universal document viewer — PDF, PostScript, DjVu, EPUB, XPS, comics, Markdown
26.08.2-1 · GPL-2.0-or-later · 14.6 SBU · 9.4 MiB, 192 files · 43_toolkits, 103 of 344 · ports/core/documents/okular
Homepage: https://okular.kde.org/
Okular is KDE’s document viewer: PDF through poppler, PostScript through libspectre, DjVu through djvulibre, EPUB through ebook-tools, XPS, comic book archives, Mobipocket through kdegraphics-mobipocket, Markdown through discount, plain text and images, with annotations, forms, text-to-speech and presentation mode. Its KPart, the component other KDE programs load to show a document inside their own window, is the document view they embed.
Depends on: cmake, ninja, extra-cmake-modules, qt6-qtbase, qt6-qtdeclarative, qt6-qtsvg, qt6-qtspeech, karchive, kbookmarks, kcolorscheme, kcompletion, kconfig, kconfigwidgets, kcoreaddons, kcrash, kdoctools, ki18n, kiconthemes, kio, kparts, kservice, ktextwidgets, kwallet, kwidgetsaddons, kwindowsystem, kxmlgui, purpose, threadweaver, phonon, zlib, freetype2, libtiff, poppler, libspectre, libkexiv2, djvulibre, ebook-tools, discount, kdegraphics-mobipocket.
Required by (2): calligra, kde-gear-core.
Sources: okular-26.08.2.tar.xz (7.9 MiB). Every step kpkg takes applies to this port.
Install: script/chroot/exec.sh bash -c 'source script/phases/43_toolkits/phase.env && kpkg install okular'
build.sh:
export CFLAGS="$CFLAGS -D_GNU_SOURCE"
cmake -S . -B build -G Ninja \
-D CMAKE_INSTALL_PREFIX=/usr \
-D KDE_INSTALL_LIBDIR=lib \
-D CMAKE_BUILD_TYPE=Release \
-D KDE_INSTALL_USE_QT_SYS_PATHS=ON \
-D BUILD_TESTING=OFF \
-D KF_SKIP_PO_PROCESSING=ON \
-D OKULAR_UI=desktop \
-D USE_DBUS=ON \
-Wno-dev
cmake --build build
DESTDIR=$PKG cmake --install build
if [ -d "$PKG/usr/share/man" ]; then
find "$PKG/usr/share/man" -mindepth 1 -maxdepth 1 ! -name 'man*' -exec rm -rf {} +
fi
-D_GNU_SOURCE— added toCFLAGS. The SyncTeX parser, the one C source in the tree, callsasprintfandvasprintf, which musl declares only under_GNU_SOURCE.-D KF_SKIP_PO_PROCESSING=ON— Builds none of the interface translations inpo/; the image is English only (see Size and language policy).-D OKULAR_UI=desktop— Builds the desktop interface only, not the Kirigami mobile one. Upstream’s default off Android, named.-D USE_DBUS=ON— Builds the D-Bus parts: opening a document in the instance already running, and the presentation-mode screen saver inhibition. Upstream’s default on Linux, named.
Programs: okular.
Libraries: libOkular6Core.so.
Directories: /usr/include/okular, /usr/lib/cmake/Okular6, /usr/share/doc/HTML/en/okular, /usr/share/licenses/okular, /usr/share/okular.
The loop at the end of build.sh removes every directory under /usr/share/man that is not a man<section> one, where kdoctools_install() puts the translated manual pages; kpkg’s language rule removes the translated handbooks.