Skip to the text
KDOS
Menu
kdos.dev KDOS from Scratch KDOS 0.2 · 4dd4a10 · 2026-11-30 Contents Index

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

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.