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

Introduce Qt CMake API policies to control public CMake API behavior similar to CMake's own policies

    XMLWordPrintable

Details

    • Suggestion
    • Resolution: Fixed
    • P3: Somewhat important
    • 6.5.0 Beta3
    • 6.2.0 Beta3
    • Build System: CMake
    • None
    • b9c80ecc08d98052e4757a916a8a55701be63497, 2add36d7a (dev), 770312407 (6.5), 95ba36880 (dev), f013f9a12 (6.5), ec452fc6e (dev), 255ee6c96 (6.5), 04a3e411e (dev), ea2c76147 (6.5), 00e010339 (dev), 1732858ba (6.5), aed498e2f (dev), f75b41906 (6.5)

    Description

      In the future we might need to change the behavior of public CMake API functions.
      To do that in a backward compatible manner, we could implement Qt's own CMake API policies modelled similar to CMake's policies.

      The first case where this would be relevant is to change the behavior of qt_import_qml_plugins as discussed at https://codereview.qt-project.org/c/qt/qtdeclarative/+/369066/1/src/qml/doc/src/cmake/qt_import_qml_plugins.qdoc#48

      A potential new command could be

      qt_set_policy(<policyID> REQUIRES <minPolicyVersion> SAFE_TO <maxPolicyVersion>)
      

      We might also want or not want to provide subdirectory and target specific commands.

      Attachments

        Issue Links

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

          Activity

            People

              mrmsdbdl Amir Masoud Abdol
              alexandru.croitor Alexandru Croitor
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: