Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

QtCreator taking a long time to run CMake



  • I have begun noticing QtCreator taking much longer to run CMake in the last week or two. The only significant project change is that more of the QML is being compiled via the :

    qtquick_compiler_add_resources
    

    mechanism. I don't understand why this would make a difference in the cmake times, however, since the actual qtquick compilation happens at compile time, not CMake generation.

    What I am hoping someone can help me with is how can I figure out what QtCreator is doing in the 30-90 seconds that it goes out to lunch when I right-click the project and choose 'run CMake'. I'm not aware of any logging that is available within the IDE. The equivalent action in the build folder on the command line takes 6 seconds consistently.

    Also, just a comment - has anyone discussed not running CMake in the UI thread of QtCreator? When the CMake takes as long as it does it causes the entire IDE to grey out because it's busy running something to do with CMake.

    I have had the same behavior in QtCreator 4.11.1 and 4.11.2. My CMake version is

    cmake version 3.16.20191210-g1318a01
    

    EDIT: for kicks I upgraded to the latest CMake 3.17.1 and still have the same results.
    EDIT: I'm using the Ninja generator



  • In the category of "unexplained phenomena", after removing the majority of my build folder things are back to normal. QtCreator is now taking the same amount of time as CMake on the command line.

    EDIT: After rebuilding everything, it's a problem again.



  • I noticed 4.12 came out. Tried it and it seems to have addressed this issue. I'll mark this closed/solved.



  • I've been using Qtcreator for a long time with rosbuild packages, where it puts the executables in the package/bin/ directory just like rosmake. Using Qtcreator with catkin packages, I can edit and compile the code just fine, but since the binaries aren't put in the catkin_workspace/devel/ path, I still have to run catkin_make by hand for the binaries to be usable. Is there a solution to this that lets Qtcreator put the libraries and executables in the correct location?


  • Lifetime Qt Champion

    @wokerjrvm How is your question related to the original question in this thread?
    Please open your own thread and ask there.


Log in to reply