Add support for generating qmltypes file

This commit is contained in:
Nicolas Fella 2021-05-09 19:33:52 +02:00
parent 3b7d51dc80
commit dcda6b3cea
3 changed files with 1093 additions and 0 deletions

View file

@ -34,6 +34,7 @@ include(ECMInstallIcons)
include(ECMQtDeclareLoggingCategory) include(ECMQtDeclareLoggingCategory)
include(FeatureSummary) include(FeatureSummary)
include(GenerateExportHeader) include(GenerateExportHeader)
include(ECMGenerateQmlTypes)
if (NOT SAILFISHOS) if (NOT SAILFISHOS)
include(ECMQMLModules) include(ECMQMLModules)
endif() endif()

View file

@ -13,6 +13,8 @@ target_link_libraries(kdeconnectdeclarativeplugin
install(TARGETS kdeconnectdeclarativeplugin DESTINATION ${QML_INSTALL_DIR}/org/kde/kdeconnect) install(TARGETS kdeconnectdeclarativeplugin DESTINATION ${QML_INSTALL_DIR}/org/kde/kdeconnect)
install(FILES qmldir DESTINATION ${QML_INSTALL_DIR}/org/kde/kdeconnect) install(FILES qmldir DESTINATION ${QML_INSTALL_DIR}/org/kde/kdeconnect)
ecm_generate_qmltypes(org.kde.kdeconnect 1.0 DESTINATION ${KDE_INSTALL_QMLDIR}/org/kde/kdeconnect)
# So qml apps using this plugin can be run from build/bin directory # So qml apps using this plugin can be run from build/bin directory
add_custom_target(copy_to_build_dir_bin) add_custom_target(copy_to_build_dir_bin)
file(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/bin/org/kde/kdeconnect) file(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/bin/org/kde/kdeconnect)

File diff suppressed because it is too large Load diff