The recommended way for end-user installations of Okular is using binary packages:
- For GNU/Linux and the BSDs use the package manager to find the Okular package (might be part of the broader kdegraphics package) and install it.
- For Windows have a look at the KDE on Windows Initiative webpage for information on how to install KDE on Windows.
- For Mac Os X have a look at the KDE on Mac OS X webpage for information on how to install KDE on Mac OS X.
KDE 4 environment
If you want to try Okular, you need to have an already set up KDE 4 environment.
Distributions should provide development packages usable for compiling KDE 4 applications.
In case you want to compile the development version of KDE and Okular, please refer to http://techbase.kde.org/Getting_Started/Build/KDE4.
You can find general information about compiling KDE at http://techbase.kde.org/Getting_Started.
If you are interested in stable tarballs of Okular visit the KDE download page and download the okular tarball.
There are some optional package you could install in order to have some more functionalities in Okular.
Some are already packaged for your distro, but other maybe not. So, if possible, use the packages your distro ships.
Poppler (PDF backend)
To compile the PDF backend, you need the Poppler library (http://poppler.freedesktop.org).
The minimum version required is:
- Okular 0.6/KDE 4.0: >= 0.5.4
- Okular 0.7/KDE 4.1, Okular 0.8/KDE 4.2: >= 0.6
- Okular >= 0.9/KDE >= 4.3: >= 0.8
- Okular >= 0.15/KDE >= 4.9: >= 0.12.1
Remember to adjust the environment variables PKG_CONFIG_PATH and LD_LIBRARY_PATH to make poppler reachable:
export PKG_CONFIG_PATH=/where/install/poppler/lib/pkgconfig:$PKG_CONFIG_PATH export LD_LIBRARY_PATH=/where/install/poppler/lib:$LD_LIBRARY_PATH
Libspectre (PostScript backend for Okular >= 0.7/KDE >= 4.1)
In order to compile and use the PostScipt (PS) backend, you need libspectre >= 0.2.
If your distro does not package libspectre, or the packaged version is not enough, you can download it from http://libspectre.freedesktop.org.
DjVuLibre (DjVu backend)
To compile the DjVu backend, you need DjVuLibre >= 3.5.17.
If your distro does not package DjVuLibre, or the packaged version is not enough, you can download it from http://djvulibre.djvuzone.org.
libTIFF (TIFF/fax backend)
libTIFF is needed to compile the TIFF/fax backend. Currently there is no minimum required version, so any quite recent version of the library available from your distro should work. In case of troubles with that, do not hesitate to contact the Okular developers.
libCHM (CHM backend)
libCHM is needed to compile the CHM backend. Currently there is no minimum required version, so any quite recent version of the library available from your distro should work. In case of troubles with that, do not hesitate to contact the Okular developers.
Libepub (EPub backend for Okular >= 0.7/KDE >= 4.1)
In order to compile and use the EPub backend, you need the epub library.
If your distro does not package libepub, or the packaged version is not enough, you can download it from http://sourceforge.net/projects/ebook-tools.
Once you have setup the proper KDE 4 environment - and installed some of the suggested external libraries - you can download and compile Okular this way:
git clone git://anongit.kde.org/okular cd okular mkdir build cd build cmake -DCMAKE_INSTALL_PREFIX=/path/to/your/kde4/install/dir .. make make install
If you install Okular in a different path than your system kde4 install directory it is possible that you need to run
export KDEDIRS=/path/to/your/kde4/install/dir:$(kde4-config --prefix); kbuildsycoca4
so that the correct Okular instance and libraries are picked up
[ Edit ]