2013-09-11 11:13:27 +02:00
|
|
|
project(PlasmaQuick)
|
2013-08-27 20:12:05 +02:00
|
|
|
|
2014-03-19 12:47:09 +01:00
|
|
|
if(HAVE_X11 AND XCB_XCB_FOUND AND XCB_COMPOSITE_FOUND AND XCB_DAMAGE_FOUND)
|
|
|
|
add_definitions(-DHAVE_XCB_COMPOSITE=1)
|
|
|
|
include_directories(
|
|
|
|
${XCB_XCB_INCLUDE_DIR}
|
|
|
|
${XCB_DAMAGE_INCLUDE_DIR}
|
|
|
|
${XCB_COMPOSITE_INCLUDE_DIR}
|
|
|
|
)
|
|
|
|
else()
|
|
|
|
add_definitions(-DHAVE_XCB_COMPOSITE=0)
|
|
|
|
endif()
|
|
|
|
if(HAVE_X11 AND XCB_XCB_FOUND AND XCB_SHAPE_FOUND)
|
|
|
|
add_definitions(-DHAVE_XCB_SHAPE=1)
|
|
|
|
include_directories(${XCB_SHAPE_INCLUDE_DIR})
|
|
|
|
else()
|
|
|
|
add_definitions(-DHAVE_XCB_SHAPE=0)
|
|
|
|
endif()
|
|
|
|
|
2013-09-11 11:13:27 +02:00
|
|
|
set(plasmaquick_LIB_SRC
|
2014-02-05 17:23:52 +01:00
|
|
|
appletquickitem.cpp
|
2014-03-19 12:47:09 +01:00
|
|
|
dialog.cpp
|
|
|
|
dialogshadows.cpp
|
2014-02-19 19:40:40 +01:00
|
|
|
view.cpp
|
2013-09-11 14:40:11 +02:00
|
|
|
configmodel.cpp
|
2014-03-15 17:24:50 +01:00
|
|
|
shellpluginloader.cpp
|
2013-08-27 20:12:05 +02:00
|
|
|
configview.cpp
|
2013-10-15 01:08:47 +02:00
|
|
|
packageurlinterceptor.cpp
|
2013-10-15 02:15:54 +02:00
|
|
|
private/configcategory_p.cpp
|
2014-03-15 17:24:50 +01:00
|
|
|
private/packages.cpp
|
2014-03-19 12:47:09 +01:00
|
|
|
../declarativeimports/core/framesvgitem.cpp
|
|
|
|
../declarativeimports/core/units.cpp
|
2013-08-27 20:12:05 +02:00
|
|
|
)
|
|
|
|
|
2013-12-11 12:39:48 +01:00
|
|
|
add_library(KF5PlasmaQuick SHARED ${plasmaquick_LIB_SRC})
|
2013-12-11 14:22:39 +01:00
|
|
|
add_library(KF5::PlasmaQuick ALIAS KF5PlasmaQuick)
|
2014-03-17 16:28:24 +01:00
|
|
|
target_include_directories(KF5PlasmaQuick PUBLIC "$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}>")
|
2013-08-27 20:12:05 +02:00
|
|
|
|
2013-12-11 12:39:48 +01:00
|
|
|
target_link_libraries(KF5PlasmaQuick
|
2014-03-25 17:05:10 +01:00
|
|
|
PUBLIC
|
|
|
|
Qt5::Quick
|
|
|
|
Qt5::Qml
|
|
|
|
KF5::Plasma
|
|
|
|
PRIVATE
|
|
|
|
KF5::WindowSystem
|
|
|
|
KF5::KIOWidgets
|
|
|
|
KF5::I18n
|
|
|
|
KF5::IconThemes
|
|
|
|
KF5::Service
|
|
|
|
KF5::CoreAddons
|
|
|
|
KF5::XmlGui
|
|
|
|
KF5::Declarative
|
2013-08-27 20:12:05 +02:00
|
|
|
)
|
|
|
|
|
2014-03-19 12:47:09 +01:00
|
|
|
if(HAVE_X11)
|
|
|
|
target_link_libraries(KF5PlasmaQuick
|
2014-03-25 17:05:10 +01:00
|
|
|
PRIVATE
|
|
|
|
Qt5::X11Extras
|
|
|
|
${X11_LIBRARIES}
|
|
|
|
${XCB_XCB_LIBRARY}
|
|
|
|
)
|
|
|
|
|
|
|
|
if(XCB_COMPOSITE_FOUND AND XCB_DAMAGE_FOUND)
|
|
|
|
target_link_libraries(KF5PlasmaQuick
|
|
|
|
PRIVATE
|
|
|
|
${XCB_DAMAGE_LIBRARY}
|
|
|
|
${XCB_COMPOSITE_LIBRARY}
|
2014-03-19 12:47:09 +01:00
|
|
|
)
|
2014-03-25 17:05:10 +01:00
|
|
|
endif()
|
|
|
|
|
|
|
|
if(XCB_SHAPE_FOUND)
|
|
|
|
target_link_libraries(KF5PlasmaQuick PRIVATE ${XCB_SHAPE_LIBRARY})
|
|
|
|
endif()
|
2014-03-19 12:47:09 +01:00
|
|
|
|
2014-03-25 17:05:10 +01:00
|
|
|
if(HAVE_GLX)
|
|
|
|
target_link_libraries(KF5PlasmaQuick PRIVATE ${OPENGL_gl_LIBRARY})
|
|
|
|
endif()
|
2014-03-19 12:47:09 +01:00
|
|
|
endif()
|
|
|
|
|
2013-12-11 12:39:48 +01:00
|
|
|
set_target_properties(KF5PlasmaQuick PROPERTIES
|
2014-02-11 16:23:16 +01:00
|
|
|
VERSION ${PLASMA_VERSION_STRING}
|
|
|
|
SOVERSION ${PLASMA_SOVERSION}
|
2013-12-11 12:39:48 +01:00
|
|
|
EXPORT_NAME PlasmaQuick
|
2013-08-27 20:12:05 +02:00
|
|
|
)
|
|
|
|
|
2013-12-11 12:39:48 +01:00
|
|
|
install(TARGETS KF5PlasmaQuick EXPORT KF5PlasmaQuickTargets ${INSTALL_TARGETS_DEFAULT_ARGS})
|
2013-08-27 20:12:05 +02:00
|
|
|
|
2013-12-11 12:39:48 +01:00
|
|
|
generate_export_header(KF5PlasmaQuick BASE_NAME PlasmaQuick)
|
2013-08-27 20:12:05 +02:00
|
|
|
|
2013-09-11 11:13:27 +02:00
|
|
|
set(plasmaquick_LIB_INCLUDES
|
|
|
|
${CMAKE_CURRENT_BINARY_DIR}/plasmaquick_export.h
|
2014-02-05 17:23:52 +01:00
|
|
|
appletquickitem.h
|
2014-02-19 20:00:29 +01:00
|
|
|
view.h
|
2013-08-27 20:12:05 +02:00
|
|
|
configview.h
|
2013-09-11 14:40:11 +02:00
|
|
|
configmodel.h
|
2013-10-15 01:08:47 +02:00
|
|
|
packageurlinterceptor.h
|
2013-08-27 20:12:05 +02:00
|
|
|
)
|
|
|
|
|
2014-02-20 11:16:46 +01:00
|
|
|
#install(FILES ${plasmaquick_LIB_INCLUDES}
|
|
|
|
# DESTINATION ${INCLUDE_INSTALL_DIR}/plasmaquick COMPONENT Devel)
|
2013-08-27 20:12:05 +02:00
|
|
|
|
2014-02-20 11:16:46 +01:00
|
|
|
#install(DIRECTORY
|
|
|
|
# includes/PlasmaQuick
|
|
|
|
# DESTINATION ${INCLUDE_INSTALL_DIR}/KDE COMPONENT Devel)
|
2013-08-27 20:12:05 +02:00
|
|
|
|
2013-12-11 12:39:48 +01:00
|
|
|
set(CMAKECONFIG_INSTALL_DIR "${CMAKECONFIG_INSTALL_PREFIX}/KF5PlasmaQuick")
|
2013-08-27 20:12:05 +02:00
|
|
|
|
2014-02-18 17:14:37 +01:00
|
|
|
ecm_configure_package_config_file(
|
2013-12-11 12:39:48 +01:00
|
|
|
"${CMAKE_CURRENT_SOURCE_DIR}/KF5PlasmaQuickConfig.cmake.in"
|
|
|
|
"${CMAKE_CURRENT_BINARY_DIR}/KF5PlasmaQuickConfig.cmake"
|
2013-08-27 20:12:05 +02:00
|
|
|
INSTALL_DESTINATION ${CMAKECONFIG_INSTALL_DIR}
|
|
|
|
PATH_VARS INCLUDE_INSTALL_DIR CMAKE_INSTALL_PREFIX
|
|
|
|
)
|
|
|
|
|
|
|
|
install(FILES
|
2013-12-11 12:39:48 +01:00
|
|
|
"${CMAKE_CURRENT_BINARY_DIR}/KF5PlasmaQuickConfig.cmake"
|
2013-08-27 20:12:05 +02:00
|
|
|
DESTINATION "${CMAKECONFIG_INSTALL_DIR}" COMPONENT Devel
|
|
|
|
)
|
|
|
|
|
2013-12-11 12:39:48 +01:00
|
|
|
install(EXPORT KF5PlasmaQuickTargets DESTINATION "${CMAKECONFIG_INSTALL_DIR}" FILE KF5PlasmaQuickTargets.cmake NAMESPACE KF5:: )
|