简体   繁体   中英

CMake build error: Qt5PrintSupportConfig.cmake missing

I am trying to build build a C++ toolkit called MITK with CMake. But I am getting this Qt5 related error. I am using the open source version of Qt 5.7.1. I can't find any file with the name Qt5PrintSupportConfig.cmake inside the Qt5 folder. The closest thing I found was windowsprintersupport.dll inside the folder printsupport . What could be the probem?

CMake Error at C:/Qt5.7.1/5.7/winrt_x64_msvc2015/lib/cmake/Qt5/Qt5Config.cmake:26 (find_package):
Could not find a package configuration file provided by "Qt5PrintSupport" with any of the following names:

    Qt5PrintSupportConfig.cmake
    qt5printsupport-config.cmake

Add the installation prefix of "Qt5PrintSupport" to CMAKE_PREFIX_PATH or
set "Qt5PrintSupport_DIR" to a directory containing one of the above files.

If "Qt5PrintSupport" provides a separate development package or SDK, be sure it has been installed.
Call Stack (most recent call first): CMakeLists.txt:211 (find_package)

You downloaded the wrong Qt online installer.

The one which you installed is from here: https://www.qt.io/download/

The one which you want is here: https://www.qt.io/download-open-source/ for the latest version or here https://download.qt.io/archive/online_installers/2.0/ for older versions.

I am not sure what the difference is but the one you probably installed is the normal version while the one you need is the unified version, whatever that means. Once you installed it, check this directory: C:\\Qt\\5.7\\msvc2015_64\\lib\\cmake\\Qt5PrintSupport since now it should include the Qt5PrintSupportConfig.cmake file.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM