2006-06-12 18:25:18 +00:00
|
|
|
project(okular)
|
2011-05-29 09:27:07 +00:00
|
|
|
|
2014-08-10 18:35:46 +00:00
|
|
|
cmake_minimum_required(VERSION 2.8.12)
|
2014-08-06 20:51:03 +00:00
|
|
|
|
|
|
|
set(QT_MIN_VERSION "5.2.0")
|
|
|
|
|
2014-08-10 18:35:46 +00:00
|
|
|
find_package(ECM 0.0.14 CONFIG REQUIRED)
|
2014-08-06 20:51:03 +00:00
|
|
|
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${ECM_MODULE_PATH})
|
|
|
|
|
|
|
|
include(ECMInstallIcons)
|
|
|
|
include(ECMSetupVersion)
|
|
|
|
include(ECMOptionalAddSubdirectory)
|
2014-08-10 18:35:46 +00:00
|
|
|
include(GenerateExportHeader)
|
|
|
|
include(FeatureSummary)
|
|
|
|
include(KDEFrameworkCompilerSettings)
|
|
|
|
include(KDEInstallDirs)
|
|
|
|
include(KDECMakeSettings)
|
2014-08-12 21:36:11 +00:00
|
|
|
include(ECMAddTests)
|
2014-08-10 18:35:46 +00:00
|
|
|
|
2014-08-06 20:51:03 +00:00
|
|
|
|
2014-08-09 18:37:49 +00:00
|
|
|
find_package(Qt5 CONFIG REQUIRED COMPONENTS Core DBus Test Widgets PrintSupport Svg)
|
2014-08-10 15:40:24 +00:00
|
|
|
find_package(KF5 REQUIRED COMPONENTS
|
2014-08-09 14:05:30 +00:00
|
|
|
Activities
|
|
|
|
Archive
|
|
|
|
Bookmarks
|
|
|
|
Config
|
|
|
|
ConfigWidgets
|
|
|
|
CoreAddons
|
|
|
|
DBusAddons
|
|
|
|
JS
|
|
|
|
KDELibs4Support
|
|
|
|
KIO
|
|
|
|
Parts
|
|
|
|
ThreadWeaver
|
|
|
|
Wallet
|
2014-08-13 09:24:15 +00:00
|
|
|
KHtml
|
2014-08-09 14:05:30 +00:00
|
|
|
)
|
|
|
|
find_package(Phonon4Qt5 CONFIG REQUIRED)
|
2011-05-29 09:27:07 +00:00
|
|
|
|
|
|
|
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_SOURCE_DIR}/cmake/modules)
|
|
|
|
|
2014-08-08 21:46:43 +00:00
|
|
|
# There was no Qt 5 version at the time of porting
|
|
|
|
#find_package(QImageBlitz)
|
|
|
|
#set_package_properties("QImageBlitz" PROPERTIES
|
|
|
|
# DESCRIPTION "An image effects library"
|
|
|
|
# URL "http://sourceforge.net/projects/qimageblitz"
|
|
|
|
# TYPE RECOMMENDED
|
|
|
|
# PURPOSE "Required to build Okular.")
|
2011-05-29 09:27:07 +00:00
|
|
|
|
2014-08-10 15:40:24 +00:00
|
|
|
find_package(KF5Screen)
|
2014-08-06 20:51:03 +00:00
|
|
|
set_package_properties("LibKScreen" PROPERTIES
|
|
|
|
DESCRIPTION "KDE screen management library"
|
|
|
|
URL "https://projects.kde.org/projects/kdereview/libkscreen"
|
|
|
|
TYPE RECOMMENDED
|
|
|
|
PURPOSE "DPI detection support")
|
2014-01-13 00:15:55 +00:00
|
|
|
|
2011-06-05 11:19:15 +00:00
|
|
|
add_definitions(-DQT_USE_FAST_CONCATENATION -DQT_USE_FAST_OPERATOR_PLUS)
|
2014-08-09 14:05:30 +00:00
|
|
|
|
2014-08-09 17:57:41 +00:00
|
|
|
include_directories(${CMAKE_CURRENT_SOURCE_DIR} ${PHONON_INCLUDES})
|
2011-05-29 09:27:07 +00:00
|
|
|
|
2014-08-07 23:35:42 +00:00
|
|
|
message("TODO: when core compiles add subdirs")
|
|
|
|
#add_subdirectory( active )
|
2014-08-09 10:47:33 +00:00
|
|
|
add_subdirectory( ui )
|
|
|
|
add_subdirectory( shell )
|
|
|
|
add_subdirectory( generators )
|
|
|
|
add_subdirectory( tests )
|
2014-08-06 20:51:03 +00:00
|
|
|
|
2014-08-16 14:43:46 +00:00
|
|
|
add_subdirectory(doc)
|
2006-03-26 12:19:40 +00:00
|
|
|
|
2007-03-10 13:15:49 +00:00
|
|
|
include(OkularConfigureChecks.cmake)
|
|
|
|
|
2007-03-18 17:14:36 +00:00
|
|
|
if(NOT WIN32)
|
|
|
|
set(MATH_LIB m)
|
|
|
|
else(NOT WIN32)
|
|
|
|
set(MATH_LIB)
|
|
|
|
endif(NOT WIN32)
|
2006-03-26 12:19:40 +00:00
|
|
|
|
2006-06-12 21:58:24 +00:00
|
|
|
# okularcore
|
2006-03-26 12:19:40 +00:00
|
|
|
|
2006-06-12 21:58:24 +00:00
|
|
|
set(okularcore_SRCS
|
2007-04-20 11:26:05 +00:00
|
|
|
core/action.cpp
|
2006-06-03 09:22:26 +00:00
|
|
|
core/annotations.cpp
|
|
|
|
core/area.cpp
|
2007-02-05 00:49:40 +00:00
|
|
|
core/audioplayer.cpp
|
2006-12-27 16:04:49 +00:00
|
|
|
core/bookmarkmanager.cpp
|
2006-06-03 09:22:26 +00:00
|
|
|
core/chooseenginedialog.cpp
|
|
|
|
core/document.cpp
|
2013-04-05 22:39:35 +00:00
|
|
|
core/documentcommands.cpp
|
2007-07-07 20:35:01 +00:00
|
|
|
core/fontinfo.cpp
|
2007-02-25 00:07:59 +00:00
|
|
|
core/form.cpp
|
2006-06-03 09:22:26 +00:00
|
|
|
core/generator.cpp
|
2007-04-20 17:17:44 +00:00
|
|
|
core/generator_p.cpp
|
2007-01-03 14:30:48 +00:00
|
|
|
core/misc.cpp
|
2008-08-23 00:07:59 +00:00
|
|
|
core/movie.cpp
|
2006-12-05 08:53:26 +00:00
|
|
|
core/observer.cpp
|
2006-06-03 09:22:26 +00:00
|
|
|
core/page.cpp
|
2007-03-24 10:47:22 +00:00
|
|
|
core/pagecontroller.cpp
|
2007-01-05 23:12:06 +00:00
|
|
|
core/pagesize.cpp
|
2006-06-03 09:22:26 +00:00
|
|
|
core/pagetransition.cpp
|
2006-11-03 17:57:32 +00:00
|
|
|
core/rotationjob.cpp
|
2008-04-13 22:31:59 +00:00
|
|
|
core/scripter.cpp
|
2006-10-09 18:02:59 +00:00
|
|
|
core/sound.cpp
|
2007-01-02 17:45:32 +00:00
|
|
|
core/sourcereference.cpp
|
2007-01-13 23:15:28 +00:00
|
|
|
core/textdocumentgenerator.cpp
|
2013-05-18 11:57:46 +00:00
|
|
|
core/textdocumentsettings.cpp
|
2006-06-03 09:22:26 +00:00
|
|
|
core/textpage.cpp
|
2012-07-07 17:40:52 +00:00
|
|
|
core/tilesmanager.cpp
|
2006-06-30 21:42:41 +00:00
|
|
|
core/utils.cpp
|
2008-04-27 11:05:59 +00:00
|
|
|
core/view.cpp
|
2007-11-26 21:43:54 +00:00
|
|
|
core/fileprinter.cpp
|
Start implementing the JavaScript scripting API for PDF documents,
thanks to Harri and Maksim and the brand-new public KJS API.
This starts the implementation of some of the API objects needed,
like App, Console, Data, Document, Field, FullScreen, Spell, Util.
Also, workaround the fact that we cannot change the read-only status for form fields.
svn path=/trunk/KDE/kdegraphics/okular/; revision=809259
2008-05-18 16:37:07 +00:00
|
|
|
core/script/executor_kjs.cpp
|
2008-05-18 19:33:46 +00:00
|
|
|
core/script/kjs_app.cpp
|
Start implementing the JavaScript scripting API for PDF documents,
thanks to Harri and Maksim and the brand-new public KJS API.
This starts the implementation of some of the API objects needed,
like App, Console, Data, Document, Field, FullScreen, Spell, Util.
Also, workaround the fact that we cannot change the read-only status for form fields.
svn path=/trunk/KDE/kdegraphics/okular/; revision=809259
2008-05-18 16:37:07 +00:00
|
|
|
core/script/kjs_console.cpp
|
|
|
|
core/script/kjs_data.cpp
|
|
|
|
core/script/kjs_document.cpp
|
|
|
|
core/script/kjs_fullscreen.cpp
|
|
|
|
core/script/kjs_field.cpp
|
|
|
|
core/script/kjs_spell.cpp
|
|
|
|
core/script/kjs_util.cpp
|
2006-03-26 15:22:05 +00:00
|
|
|
)
|
|
|
|
|
2014-08-13 09:26:37 +00:00
|
|
|
ki18n_wrap_ui(okularcore_SRCS
|
2013-05-18 11:57:46 +00:00
|
|
|
conf/textdocumentsettings.ui
|
|
|
|
)
|
|
|
|
|
2007-01-03 14:30:48 +00:00
|
|
|
install( FILES
|
2007-04-20 11:26:05 +00:00
|
|
|
core/action.h
|
2007-01-03 14:30:48 +00:00
|
|
|
core/annotations.h
|
|
|
|
core/area.h
|
|
|
|
core/document.h
|
2007-07-08 16:21:53 +00:00
|
|
|
core/fontinfo.h
|
2007-03-18 19:25:04 +00:00
|
|
|
core/form.h
|
2007-01-03 14:30:48 +00:00
|
|
|
core/generator.h
|
2007-04-22 10:23:59 +00:00
|
|
|
core/global.h
|
2007-03-18 19:25:04 +00:00
|
|
|
core/okular_export.h
|
2007-01-03 14:30:48 +00:00
|
|
|
core/page.h
|
2007-01-05 23:12:06 +00:00
|
|
|
core/pagesize.h
|
2007-01-03 14:30:48 +00:00
|
|
|
core/pagetransition.h
|
|
|
|
core/sound.h
|
|
|
|
core/sourcereference.h
|
2007-01-13 23:15:28 +00:00
|
|
|
core/textdocumentgenerator.h
|
2013-05-18 11:57:46 +00:00
|
|
|
core/textdocumentsettings.h
|
2007-01-03 14:30:48 +00:00
|
|
|
core/textpage.h
|
2012-11-08 20:29:09 +00:00
|
|
|
core/tile.h
|
2007-01-03 14:30:48 +00:00
|
|
|
core/utils.h
|
2008-01-27 16:31:02 +00:00
|
|
|
core/version.h
|
2007-11-26 21:43:54 +00:00
|
|
|
core/fileprinter.h
|
2013-02-24 21:58:53 +00:00
|
|
|
core/observer.h
|
2012-10-15 22:27:42 +00:00
|
|
|
${CMAKE_CURRENT_BINARY_DIR}/settings_core.h
|
2008-06-27 07:04:23 +00:00
|
|
|
DESTINATION ${INCLUDE_INSTALL_DIR}/okular/core COMPONENT Devel)
|
2007-01-03 14:30:48 +00:00
|
|
|
|
|
|
|
install( FILES
|
|
|
|
interfaces/configinterface.h
|
|
|
|
interfaces/guiinterface.h
|
|
|
|
interfaces/printinterface.h
|
2012-05-21 21:54:48 +00:00
|
|
|
interfaces/saveinterface.h
|
2011-09-10 17:15:52 +00:00
|
|
|
interfaces/viewerinterface.h
|
2008-06-27 07:04:23 +00:00
|
|
|
DESTINATION ${INCLUDE_INSTALL_DIR}/okular/interfaces COMPONENT Devel)
|
2007-01-03 14:30:48 +00:00
|
|
|
|
2014-08-13 09:26:37 +00:00
|
|
|
ki18n_wrap_ui(okularcore_SRCS
|
2006-06-03 09:22:26 +00:00
|
|
|
core/chooseenginewidget.ui
|
2006-03-26 15:22:05 +00:00
|
|
|
)
|
|
|
|
|
2014-08-08 22:07:35 +00:00
|
|
|
kconfig_add_kcfg_files(okularcore_SRCS conf/settings_core.kcfgc )
|
2006-06-12 21:58:24 +00:00
|
|
|
|
|
|
|
kde4_add_library(okularcore SHARED ${okularcore_SRCS})
|
|
|
|
|
2006-10-29 15:08:18 +00:00
|
|
|
# Special handling for linking okularcore on OSX/Apple
|
|
|
|
IF(APPLE)
|
|
|
|
SET(OKULAR_IOKIT "-framework IOKit" CACHE STRING "Apple IOKit framework")
|
|
|
|
ENDIF(APPLE)
|
|
|
|
|
2014-08-09 14:05:30 +00:00
|
|
|
target_link_libraries(okularcore
|
|
|
|
${OKULAR_IOKIT}
|
|
|
|
KF5::Archive
|
|
|
|
KF5::JS
|
|
|
|
KF5::JSApi
|
|
|
|
KF5::KDELibs4Support
|
|
|
|
KF5::KIOCore
|
|
|
|
KF5::ThreadWeaver
|
|
|
|
KF5::Wallet
|
|
|
|
Phonon::phonon4qt5
|
|
|
|
${MATH_LIB}
|
|
|
|
)
|
2006-06-12 21:58:24 +00:00
|
|
|
|
2014-01-13 00:15:55 +00:00
|
|
|
if(LibKScreen_FOUND)
|
2014-08-09 14:05:30 +00:00
|
|
|
# target_link_libraries(okularcore KF5::LibKScreen)
|
2014-01-13 00:15:55 +00:00
|
|
|
endif(LibKScreen_FOUND)
|
|
|
|
|
2014-08-09 14:05:30 +00:00
|
|
|
set_target_properties(okularcore PROPERTIES VERSION 5.0.0 SOVERSION 5 )
|
2007-04-20 16:12:05 +00:00
|
|
|
|
2008-02-26 12:56:08 +00:00
|
|
|
install(TARGETS okularcore ${INSTALL_TARGETS_DEFAULT_ARGS} )
|
2006-06-12 21:58:24 +00:00
|
|
|
|
2007-01-25 18:06:53 +00:00
|
|
|
install(FILES conf/okular.kcfg DESTINATION ${KCFG_INSTALL_DIR})
|
2012-10-15 22:27:42 +00:00
|
|
|
install(FILES conf/okular_core.kcfg DESTINATION ${KCFG_INSTALL_DIR})
|
2007-01-25 18:06:53 +00:00
|
|
|
install(FILES core/okularGenerator.desktop DESTINATION ${SERVICETYPES_INSTALL_DIR})
|
|
|
|
|
2006-06-12 21:58:24 +00:00
|
|
|
# okularpart
|
|
|
|
|
|
|
|
set(okularpart_SRCS
|
|
|
|
part.cpp
|
2008-04-01 09:10:46 +00:00
|
|
|
extensions.cpp
|
2006-11-10 20:29:12 +00:00
|
|
|
conf/preferencesdialog.cpp
|
|
|
|
conf/dlgaccessibility.cpp
|
2006-12-22 15:04:01 +00:00
|
|
|
conf/dlgdebug.cpp
|
2008-10-19 18:01:16 +00:00
|
|
|
conf/dlgeditor.cpp
|
2006-11-10 20:29:12 +00:00
|
|
|
conf/dlggeneral.cpp
|
2012-06-09 20:59:40 +00:00
|
|
|
conf/dlgannotations.cpp
|
2006-11-10 20:29:12 +00:00
|
|
|
conf/dlgperformance.cpp
|
|
|
|
conf/dlgpresentation.cpp
|
2012-06-10 18:15:38 +00:00
|
|
|
conf/widgetannottools.cpp
|
2006-06-03 09:22:26 +00:00
|
|
|
ui/embeddedfilesdialog.cpp
|
2006-08-11 23:53:48 +00:00
|
|
|
ui/annotwindow.cpp
|
2007-09-08 17:10:35 +00:00
|
|
|
ui/annotationmodel.cpp
|
2006-12-30 12:40:54 +00:00
|
|
|
ui/annotationpopup.cpp
|
2006-08-08 15:31:13 +00:00
|
|
|
ui/annotationpropertiesdialog.cpp
|
2007-09-09 16:51:55 +00:00
|
|
|
ui/annotationproxymodels.cpp
|
2006-11-01 15:23:11 +00:00
|
|
|
ui/annotationtools.cpp
|
2006-09-12 20:21:34 +00:00
|
|
|
ui/annotationwidgets.cpp
|
2006-12-27 16:04:49 +00:00
|
|
|
ui/bookmarklist.cpp
|
2007-12-03 00:17:12 +00:00
|
|
|
ui/fileprinterpreview.cpp
|
2007-03-17 22:58:41 +00:00
|
|
|
ui/findbar.cpp
|
2007-02-25 00:07:59 +00:00
|
|
|
ui/formwidgets.cpp
|
2007-12-24 00:54:21 +00:00
|
|
|
ui/guiutils.cpp
|
2007-09-09 15:50:00 +00:00
|
|
|
ui/ktreeviewsearchline.cpp
|
2011-09-22 17:09:26 +00:00
|
|
|
ui/latexrenderer.cpp
|
2006-06-03 09:22:26 +00:00
|
|
|
ui/minibar.cpp
|
2006-12-26 12:01:30 +00:00
|
|
|
ui/pageitemdelegate.cpp
|
2006-06-03 09:22:26 +00:00
|
|
|
ui/pagepainter.cpp
|
2006-10-15 19:37:14 +00:00
|
|
|
ui/pagesizelabel.cpp
|
2006-06-03 09:22:26 +00:00
|
|
|
ui/pageviewannotator.cpp
|
|
|
|
ui/pageview.cpp
|
2014-02-24 22:42:10 +00:00
|
|
|
ui/magnifierview.cpp
|
2006-06-03 09:22:26 +00:00
|
|
|
ui/pageviewutils.cpp
|
2007-03-17 22:58:41 +00:00
|
|
|
ui/presentationsearchbar.cpp
|
2006-06-03 09:22:26 +00:00
|
|
|
ui/presentationwidget.cpp
|
|
|
|
ui/propertiesdialog.cpp
|
2007-03-17 16:58:01 +00:00
|
|
|
ui/searchlineedit.cpp
|
2006-06-03 09:22:26 +00:00
|
|
|
ui/searchwidget.cpp
|
2007-08-06 17:24:10 +00:00
|
|
|
ui/sidebar.cpp
|
2006-06-03 09:22:26 +00:00
|
|
|
ui/side_reviews.cpp
|
2012-06-29 09:16:28 +00:00
|
|
|
ui/snapshottaker.cpp
|
2006-06-03 09:22:26 +00:00
|
|
|
ui/thumbnaillist.cpp
|
|
|
|
ui/toc.cpp
|
2007-09-09 16:15:33 +00:00
|
|
|
ui/tocmodel.cpp
|
2007-09-14 10:02:33 +00:00
|
|
|
ui/toolaction.cpp
|
2014-08-09 18:38:09 +00:00
|
|
|
# ui/tts.cpp
|
2008-08-25 01:26:47 +00:00
|
|
|
ui/videowidget.cpp
|
2006-03-26 15:52:06 +00:00
|
|
|
)
|
2006-03-26 12:19:40 +00:00
|
|
|
|
2014-08-13 09:26:37 +00:00
|
|
|
ki18n_wrap_ui(okularpart_SRCS
|
2006-11-10 20:29:12 +00:00
|
|
|
conf/dlgaccessibilitybase.ui
|
2008-10-19 18:01:16 +00:00
|
|
|
conf/dlgeditorbase.ui
|
2006-11-10 20:29:12 +00:00
|
|
|
conf/dlggeneralbase.ui
|
2012-06-09 20:59:40 +00:00
|
|
|
conf/dlgannotationsbase.ui
|
2006-11-10 20:29:12 +00:00
|
|
|
conf/dlgperformancebase.ui
|
|
|
|
conf/dlgpresentationbase.ui
|
|
|
|
)
|
|
|
|
|
2014-08-08 22:07:35 +00:00
|
|
|
kconfig_add_kcfg_files(okularpart_SRCS conf/settings.kcfgc )
|
2012-10-15 22:27:42 +00:00
|
|
|
|
2014-08-09 18:38:09 +00:00
|
|
|
message("KF5: Enable ui/tts.cpp again")
|
|
|
|
#qt4_add_dbus_interfaces(okularpart_SRCS ${KDE4_DBUS_INTERFACES_DIR}/org.kde.KSpeech.xml)
|
2006-03-26 12:19:40 +00:00
|
|
|
|
2014-08-10 18:35:46 +00:00
|
|
|
add_library(okularpart MODULE ${okularpart_SRCS})
|
2006-03-26 12:19:40 +00:00
|
|
|
|
2014-08-10 12:42:51 +00:00
|
|
|
target_link_libraries(okularpart okularcore Qt5::Svg KF5::Parts ${MATH_LIB} Phonon::phonon4qt5 KF5::Solid)
|
2006-03-26 12:19:40 +00:00
|
|
|
|
2006-07-04 15:24:52 +00:00
|
|
|
install(TARGETS okularpart DESTINATION ${PLUGIN_INSTALL_DIR})
|
2006-03-26 12:19:40 +00:00
|
|
|
|
|
|
|
|
|
|
|
########### install files ###############
|
|
|
|
|
2012-10-15 22:27:42 +00:00
|
|
|
install(FILES okular.upd DESTINATION ${DATA_INSTALL_DIR}/kconf_update)
|
|
|
|
|
2006-07-04 15:24:52 +00:00
|
|
|
install( FILES okular_part.desktop DESTINATION ${SERVICES_INSTALL_DIR} )
|
2011-10-12 19:36:01 +00:00
|
|
|
install( FILES part.rc part-viewermode.rc DESTINATION ${DATA_INSTALL_DIR}/okular )
|
2006-03-26 12:19:40 +00:00
|
|
|
|
2010-09-26 17:31:31 +00:00
|
|
|
########### cmake files #################
|
|
|
|
|
2014-08-06 20:51:03 +00:00
|
|
|
include(WriteBasicConfigVersionFile)
|
2014-08-09 14:05:30 +00:00
|
|
|
write_basic_config_version_file(${CMAKE_CURRENT_BINARY_DIR}/OkularConfigVersion.cmake VERSION 1.0.0 COMPATIBILITY AnyNewerVersion)
|
2010-09-26 17:31:31 +00:00
|
|
|
|
|
|
|
install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/OkularConfig.cmake
|
|
|
|
${CMAKE_CURRENT_BINARY_DIR}/OkularConfigVersion.cmake
|
2011-01-05 23:36:40 +00:00
|
|
|
DESTINATION ${LIB_INSTALL_DIR}/cmake/Okular )
|
2011-05-29 09:27:07 +00:00
|
|
|
|
2014-08-06 20:51:03 +00:00
|
|
|
feature_summary(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES)
|
2011-05-29 09:27:07 +00:00
|
|
|
|