Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-133648

Allow `qt_add_qml_module` target import/dependencies to work on imported targets

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: P2: Important P2: Important
    • None
    • 6.8.6
    • Build System: CMake
    • None

      Right now there is a hard exclusion in `qt6_query_qml_module` against imported targets

          get_target_property(is_imported ${target} IMPORTED)
          if(is_imported)
              message(FATAL_ERROR
                  "Only targets built by the project can be used with this command, "
                  "but target \"${target}\" is imported."
              )
          endif()
      

      This is unfortunate because using targets directly would make configure time checks much easier. Probably nowadays the import target restriction can be dropped if the appropriate properties are exported. But there might need some design question around the dependency URI passed by the user vs the one exported by the target.

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            qtbuildsystem Qt Build System Team
            lecris Cristian Le
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:

                There are no open Gerrit changes