D7094: Include a module for finding qml imports as runtime dependencies

Harald Sitter noreply at phabricator.kde.org
Wed Aug 9 08:50:42 UTC 2017


sitter added inline comments.

INLINE COMMENTS

> apol wrote in ECMFindQMLModule.cmake.in:30
> Doing find_program for now. The right fix would be to change Qt to export the `qmlplugindump` target.

You still need to do "something" if qmlplugindump isn't found. Print a `message(WARNING` and/or `add_feature_info` or something similar.
Right now the code would mark the plugin not found but not tell the user that the reason it was not found is that the helper is missing.

e.g. here kirigami is actually installed but qmlplugindump is not:

   10:45:09  /tmp/t/b 
  $ cmake ..
  -- The C compiler identification is GNU 5.4.0
  -- The CXX compiler identification is GNU 5.4.0
  -- Check for working C compiler: /usr/lib/icecc/bin/gcc
  -- Check for working C compiler: /usr/lib/icecc/bin/gcc -- works
  -- Detecting C compiler ABI info
  -- Detecting C compiler ABI info - done
  -- Detecting C compile features
  -- Detecting C compile features - done
  -- Check for working CXX compiler: /usr/lib/icecc/bin/g++
  -- Check for working CXX compiler: /usr/lib/icecc/bin/g++ -- works
  -- Detecting CXX compiler ABI info
  -- Detecting CXX compiler ABI info - done
  -- Detecting CXX compile features
  -- Detecting CXX compile features - done
  -- qmlplugindump failed for org.kde.kirigami.
  -- Could NOT find org.kde.kirigami-QMLModule (missing:  org.kde.kirigami-QMLModule_FOUND) 
  -- Configuring done
  -- Generating done
  -- Build files have been written to: /tmp/t/b
  
   10:45:12  /tmp/t/b 
  $ cat ../CMakeLists.txt 
  project(test)
  cmake_minimum_required(VERSION 3.5)
  
  find_package(ECM 1.3.0 REQUIRED NO_MODULE)
  set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${ECM_MODULE_PATH})
  
  include(ECMQMLModules)
  ecm_find_qmlmodule(org.kde.kirigami 2.1)

REPOSITORY
  R240 Extra CMake Modules

REVISION DETAIL
  https://phabricator.kde.org/D7094

To: apol, #build_system, #frameworks, sitter
Cc: dfaure, aacid
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-buildsystem/attachments/20170809/3dc2a0b6/attachment-0001.html>


More information about the Kde-buildsystem mailing list