25.11.2016, 22:12, "Ernst Maurer" <[email protected]>: > hello > > just faced with a requirement to build qt/cmake based project from command > line or another IDE, and could not. what is a qtcreator magic which helps to > do this successfully? > > tried to build simplest sample project from actual documentation here > (http://doc.qt.io/qt-5/cmake-manual.html) , the same problem. > > it looks like cmake can't find all required .cmake scripts, I don't see the > instructions to set the paths to all .cmake scripts for required modules. > > I suppose qtcreator does some "tuning" the project implicitly?? > > this is the output for sample cmakelists from doc page sample above: > > cmake.exe -DCMAKE_BUILD_TYPE=Debug -G "CodeBlocks - MinGW Makefiles" > C:\dev\workspace\algolist.v2 > CMake Warning at CMakeLists.txt:13 (find_package): > By not providing "FindQt5Widgets.cmake" in CMAKE_MODULE_PATH this project > has asked CMake to find a package configuration file provided by > "Qt5Widgets", but CMake did not find one. > > Could not find a package configuration file provided by "Qt5Widgets" with > any of the following names: > > Qt5WidgetsConfig.cmake > qt5widgets-config.cmake > > Add the installation prefix of "Qt5Widgets" to CMAKE_PREFIX_PATH or set > "Qt5Widgets_DIR" to a directory containing one of the above files. If > "Qt5Widgets" provides a separate development package or SDK, be sure it has > been installed.
Hi, The above message means that you need to add -DCMAKE_PREFIX_PATH=$QTDIR to your cmake arguments, where $QTDIR is a path to your Qt installation > > , > > _______________________________________________ > Development mailing list > [email protected] > http://lists.qt-project.org/mailman/listinfo/development -- Regards, Konstantin _______________________________________________ Development mailing list [email protected] http://lists.qt-project.org/mailman/listinfo/development
