kdeconnect-kde/declarativeplugin/CMakeLists.txt

32 lines
1.2 KiB
CMake
Raw Normal View History

include_directories(${CMAKE_CURRENT_BINARY_DIR}
${CMAKE_CURRENT_SOURCE_DIR}
${CMAKE_SOURCE_DIR}
${CMAKE_BINARY_DIR})
2014-01-28 22:22:59 +00:00
set(kdeconnectdeclarativeplugin_SRC
kdeconnectdeclarativeplugin.cpp
2014-01-28 22:22:59 +00:00
responsewaiter.cpp
objectfactory.cpp
2014-01-28 22:22:59 +00:00
)
qt5_add_resources(kdeconnectdeclarativeplugin_SRC resources.qrc)
add_library(kdeconnectdeclarativeplugin SHARED ${kdeconnectdeclarativeplugin_SRC})
target_link_libraries(kdeconnectdeclarativeplugin
Qt5::Qml
2014-06-14 15:50:54 +01:00
kdeconnectinterfaces
)
2019-07-22 23:41:12 +01:00
2014-06-18 01:35:48 +01:00
install(TARGETS kdeconnectdeclarativeplugin DESTINATION ${QML_INSTALL_DIR}/org/kde/kdeconnect)
install(FILES qmldir DESTINATION ${QML_INSTALL_DIR}/org/kde/kdeconnect)
2019-07-22 23:41:12 +01:00
# So qml apps using this plugin can be run from build/bin directory
add_custom_target(copy_to_build_dir_bin)
2019-07-23 00:03:20 +01:00
add_custom_command(TARGET copy_to_build_dir_bin POST_BUILD
2019-07-22 23:41:12 +01:00
COMMAND ${CMAKE_COMMAND} -E
copy ${CMAKE_CURRENT_SOURCE_DIR}/qmldir ${CMAKE_BINARY_DIR}/bin/org/kde/kdeconnect/)
add_dependencies(kdeconnectdeclarativeplugin copy_to_build_dir_bin)
set_target_properties(kdeconnectdeclarativeplugin
PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin/org/kde/kdeconnect/
)