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

Can not build Qt 6 with cmake when preferring package configuration

    XMLWordPrintable

Details

    • Windows
    • 34a4fe0166 (qt/qtbase/dev) 4f4b45d854 (qt/qtbase/6.2) 4f4b45d854 (qt/tqtc-qtbase/6.2) 34a4fe0166 (qt/tqtc-qtbase/dev) ffb076783a (qt/qtbase/6.3) ffb076783a (qt/tqtc-qtbase/6.3) ffb076783a (qt/tqtc-qtbase/6.3.0)

    Description

      I'd like to build Qt with cmake option -DCMAKE_FIND_PACKAGE_PREFER_CONFIG=ON to make sure that upstream packages are found from their cmake builds, not some pkg-config or autotools variants that may not transfer all build flags correctly. This seems to work with Qt except for an error when linking ZSTD::ZSTD on MSVC.

      Qt configure works fine without issues and finds zstd. And I can see in FindZSTD.cmake that there is specific code that uses cmake's CONFIG mode like I would hope for.

      But then when configure is successfully completed and I want to start the build, I get an error that ZSTD::ZSTD can not be found and therefore certain projects can not be built (one of them is rcc and another is QtNetwork.

      Tested with latest zstd version 1.5.3, built with cmake 3.22.2.

      Attachments

        Issue Links

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

          Activity

            People

              qtbuildsystem Qt Build System Team
              emmenlau Mario Emmenlauer
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes