Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-27060

CMake project configuration fails by default

    XMLWordPrintable

    Details

    • Platform/s:
      Linux/X11
    • Commits:
      2f77dc3415 (qt-creator/qt-creator/7.0) 2f77dc3415 (qt-creator/qt-creator/master) 2f77dc3415 (qt-creator/tqtc-qt-creator/7.0) 2f77dc3415 (qt-creator/tqtc-qt-creator/master) 2f77dc3415 (qt-creator/qt-creator/qds-3.3)

      Description

      Consider this test scenario:

      1. Unpack the attached project in the filesystem.
      2. Open the project in QtCreator.
      3. Press Configure Project in the initial screen.

      Configuring fails with the following output:

      Running /usr/bin/cmake -S /home/lastique/src/tmp/cmake_test_project -B /home/lastique/src/tmp/cmake_test_project/build-cmake_test_project-Desktop-Debug '-DCMAKE_GENERATOR:STRING=CodeBlocks - Unix Makefiles' -DCMAKE_BUILD_TYPE:STRING=Debug -DCMAKE_PROJECT_INCLUDE_BEFORE:FILEPATH=/home/lastique/qtcreator-7.0.0-beta1/share/qtcreator/package-manager/auto-setup.cmake -DQT_QMAKE_EXECUTABLE:STRING=/usr/lib/x86_64-linux-gnu/qt4/bin/qmake -DCMAKE_CXX_COMPILER:STRING=/usr/bin/g++ in /home/lastique/src/tmp/cmake_test_project/build-cmake_test_project-Desktop-Debug.
      CMake Error: Error: generator : Unix Makefiles
      Does not match the generator used previously: CodeBlocks - Unix Makefiles
      Either remove the CMakeCache.txt file and CMakeFiles directory or choose a different binary directory.
      CMake process exited with exit code 1.
      
      Elapsed time: 00:00.
      

      Note that:

      • There is no CMakeCache.txt
      • In the Options -> Kits tab, the default kit is Manual -> Desktop, which has "CMake generator: CodeBlocks - Unix Makefiles" set. Changing "Extra generator" to "<none>" (which results in "CMake generator: Unix Makefiles") has no effect - configuring still fails with the same output.
      • The workaround is to remove CMAKE_GENERATOR variable completely in the project settings.

      I have not seen such problem with QtCreator 6.0.2.

        Attachments

        For Gerrit Dashboard: QTCREATORBUG-27060
        # Subject Branch Project Status CR V

          Activity

            People

            Assignee:
            cadam Cristian Adam
            Reporter:
            lastique Andrey Semashev
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes