Warning, /utilities/mycroft-plasmoid/CMakeLists.txt is written in an unsupported language. File is not indexed.

0001 # Set minimum CMake version (required for CMake 3.0 or later)
0002 cmake_minimum_required(VERSION 2.8.12)
0003 cmake_policy(SET CMP0048 NEW)
0004 project(plasma-mycroft VERSION "2.0.0")
0005 
0006 option(BUILD_GUI_DEPS "Build Mycroft-GUI Dependencies" OFF)
0007 set(QT_MIN_VERSION "5.9.0")
0008 set(KF5_MIN_VERSION "5.0.0")
0009  
0010 # Use Extra CMake Modules (ECM) for common functionality.
0011 # See http://api.kde.org/ecm/manual/ecm.7.html
0012 # and http://api.kde.org/ecm/manual/ecm-kde-modules.7.html 
0013 find_package(ECM REQUIRED NO_MODULE)
0014 set(CMAKE_MODULE_PATH ${ECM_MODULE_PATH} ${ECM_KDE_MODULE_DIR} ${CMAKE_MODULE_PATH})
0015 set(VERSION 2.1.0)
0016 
0017 include(KDEInstallDirs)
0018 include(KDECMakeSettings)
0019 include(KDECompilerSettings NO_POLICY_SCOPE)
0020 include(ECMInstallIcons)
0021 include(ExternalProject)
0022 
0023 # Locate plasma_install_package macro.
0024 find_package(KF5 ${KF5_MIN_VERSION} REQUIRED COMPONENTS
0025     Plasma
0026     I18n
0027     Notifications
0028 )
0029 
0030 find_package(Qt5 ${QT_MIN_VERSION} CONFIG REQUIRED COMPONENTS
0031     Quick
0032     Core
0033     Qml
0034     DBus
0035     Network
0036     WebSockets
0037 )
0038 
0039 add_subdirectory(icons)
0040 add_subdirectory(plugin)
0041 
0042 find_program(MycroftGUI mycroft-gui-app)
0043 
0044 if(NOT MycroftGUI)
0045     message(STATUS "IMPORTANT: MYCROFT GUI DEPENDENCY NOT FOUND, PLEASE INSTALL MYCROFT-GUI & LOTTIE-QML MANUALLY")
0046 endif()
0047 
0048 if(MycroftGUI)
0049     message(STATUS "IMPORTANT: MYCROFT GUI DEPENDENCY FOUND, SKIPPING BUILDING DEPENDENCIES")
0050 endif()
0051 
0052 if(BUILD_GUI_DEPS)
0053 ExternalProject_Add(mycroft-gui
0054     GIT_REPOSITORY https://github.com/MycroftAI/Mycroft-Gui
0055     CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Release -DKDE_INSTALL_LIBDIR=lib -DKDE_INSTALL_USE_QT_SYS_PATHS=ON -DBUILD_REMOTE_TTS=ON
0056     BUILD_COMMAND make
0057     INSTALL_COMMAND sudo make install
0058 )
0059 
0060 ExternalProject_Add(lottie-qml
0061     GIT_REPOSITORY https://github.com/kbroulik/lottie-qml
0062     CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Release -DKDE_INSTALL_LIBDIR=lib -DKDE_INSTALL_USE_QT_SYS_PATHS=ON
0063     BUILD_COMMAND make
0064     INSTALL_COMMAND sudo make install
0065 )
0066 endif()
0067 
0068 plasma_install_package(plasmoid org.kde.plasma.mycroftplasmoid)
0069 
0070 install( DIRECTORY mycroft DESTINATION ${SYSCONF_INSTALL_DIR})