Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. yet another CMake project configuration failed
Forum Updated to NodeBB v4.3 + New Features

yet another CMake project configuration failed

Scheduled Pinned Locked Moved Solved QML and Qt Quick
11 Posts 3 Posters 4.2k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    cibo005
    wrote on last edited by cibo005
    #1

    I'm using Win 10 and have recently installed QtCreator and QtDesign. When I try to create a Qt console project using the wizard it gives me some error messages. Please have a look at the screenshots to figure out what may be the root cause.
    error 3.jpg error 2.jpg error 1.jpg

    The configuration text file is taken from the Qt > Build with CMake > Getting started with CMake

    The original configuration text from the Qt wizard was:

    cmake_minimum_required(VERSION 3.14)
    
    project(ConsoleCMake LANGUAGES CXX)
    
    set(CMAKE_AUTOUIC ON)
    set(CMAKE_AUTOMOC ON)
    set(CMAKE_AUTORCC ON)
    
    set(CMAKE_CXX_STANDARD 17)
    set(CMAKE_CXX_STANDARD_REQUIRED ON)
    
    find_package(QT NAMES Qt6 Qt5 REQUIRED COMPONENTS Core)
    find_package(Qt${QT_VERSION_MAJOR} REQUIRED COMPONENTS Core)
    
    add_executable(ConsoleCMake
      main.cpp
    )
    target_link_libraries(ConsoleCMake Qt${QT_VERSION_MAJOR}::Core)
    
    install(TARGETS ConsoleCMake
        LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR})
    

    but the errors were the same.

    I've also included in my PATH system variable the link to the cmake directory: Qt\Tools\QtDesignStudio\qt6_design_studio_reduced_version\lib\cmake

    Creating a Non-QtProject works fine, also viewing a QML project and run it.

    Any ideas ?

    C 1 Reply Last reply
    0
    • C cibo005

      I'm using Win 10 and have recently installed QtCreator and QtDesign. When I try to create a Qt console project using the wizard it gives me some error messages. Please have a look at the screenshots to figure out what may be the root cause.
      error 3.jpg error 2.jpg error 1.jpg

      The configuration text file is taken from the Qt > Build with CMake > Getting started with CMake

      The original configuration text from the Qt wizard was:

      cmake_minimum_required(VERSION 3.14)
      
      project(ConsoleCMake LANGUAGES CXX)
      
      set(CMAKE_AUTOUIC ON)
      set(CMAKE_AUTOMOC ON)
      set(CMAKE_AUTORCC ON)
      
      set(CMAKE_CXX_STANDARD 17)
      set(CMAKE_CXX_STANDARD_REQUIRED ON)
      
      find_package(QT NAMES Qt6 Qt5 REQUIRED COMPONENTS Core)
      find_package(Qt${QT_VERSION_MAJOR} REQUIRED COMPONENTS Core)
      
      add_executable(ConsoleCMake
        main.cpp
      )
      target_link_libraries(ConsoleCMake Qt${QT_VERSION_MAJOR}::Core)
      
      install(TARGETS ConsoleCMake
          LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR})
      

      but the errors were the same.

      I've also included in my PATH system variable the link to the cmake directory: Qt\Tools\QtDesignStudio\qt6_design_studio_reduced_version\lib\cmake

      Creating a Non-QtProject works fine, also viewing a QML project and run it.

      Any ideas ?

      C Offline
      C Offline
      cibo005
      wrote on last edited by
      #2

      Really no one know what might be the cause of the issue ?

      JoeCFDJ 1 Reply Last reply
      0
      • C cibo005

        Really no one know what might be the cause of the issue ?

        JoeCFDJ Offline
        JoeCFDJ Offline
        JoeCFD
        wrote on last edited by JoeCFD
        #3

        @cibo005 Did you install Qt? Can you click ManageKits to Qt Version tab?

        C 1 Reply Last reply
        0
        • JoeCFDJ JoeCFD

          @cibo005 Did you install Qt? Can you click ManageKits to Qt Version tab?

          C Offline
          C Offline
          cibo005
          wrote on last edited by
          #4

          @JoeCFD
          of course I've installed, as I mention before, the non-qt projects I can run it using qmake, also viewing and running a QML example.

          error 4.jpg

          C 1 Reply Last reply
          0
          • C cibo005

            @JoeCFD
            of course I've installed, as I mention before, the non-qt projects I can run it using qmake, also viewing and running a QML example.

            error 4.jpg

            C Offline
            C Offline
            cibo005
            wrote on last edited by
            #5

            I've also tried to contact Qt support, but here is the message I've received:
            "Hi
            Thank you for contacting Qt Account Support.
            Unfortunately you need to have an active commercial Qt license to get technical support."
            so, is there no way someone could help somebody in this QT world ?
            It's been more than one week since I post my issue.

            kkoehneK 1 Reply Last reply
            0
            • C cibo005

              I've also tried to contact Qt support, but here is the message I've received:
              "Hi
              Thank you for contacting Qt Account Support.
              Unfortunately you need to have an active commercial Qt license to get technical support."
              so, is there no way someone could help somebody in this QT world ?
              It's been more than one week since I post my issue.

              kkoehneK Offline
              kkoehneK Offline
              kkoehne
              Moderators
              wrote on last edited by
              #6

              It looks like Qt Creator picks up some Qt from Qt Design Studio (the Qt 6.4.1 (qt6_design_stdudio_reduced_version). Don't use this for your project. Instead, activate an auto-detected kit, e.g. the "Qt 6.5.0 MinGW 64-bit" kit one.

              See also https://doc.qt.io/qtcreator/creator-configuring-projects.html on how to activate different kits.

              Director R&D, The Qt Company

              C 1 Reply Last reply
              2
              • kkoehneK kkoehne

                It looks like Qt Creator picks up some Qt from Qt Design Studio (the Qt 6.4.1 (qt6_design_stdudio_reduced_version). Don't use this for your project. Instead, activate an auto-detected kit, e.g. the "Qt 6.5.0 MinGW 64-bit" kit one.

                See also https://doc.qt.io/qtcreator/creator-configuring-projects.html on how to activate different kits.

                C Offline
                C Offline
                cibo005
                wrote on last edited by
                #7

                @kkoehne Thank you for your replay. Please have a look at what I've installed. Even though I have installed MinGW I cannot see it under the kits. I've tried to enable the project for MSVC but I've got other errors.

                error 5.jpg

                error 6.jpg

                1 Reply Last reply
                0
                • kkoehneK Offline
                  kkoehneK Offline
                  kkoehne
                  Moderators
                  wrote on last edited by
                  #8

                  @cibo005 said in yet another CMake project configuration failed:

                  @kkoehne Thank you for your replay. Please have a look at what I've installed. Even though I have installed MinGW I cannot see it under the kits.

                  That's indeed a bit weird.

                  Do you use the Qt Creator that's shipped with the Qt SDK (e.g. in D:\Qt\Tools\QtCreator? If that's the case, maybe try to launch with clean settings:

                  "D:\Qt\Tools\QtCreator\bin\qtcreator.exe" -tcs
                  

                  Does it show the MinGW kit then?

                  You can of course configure a MinGW kit manually, too. Just make sure that the Qt version matches the configured toolchain.

                  Director R&D, The Qt Company

                  C 1 Reply Last reply
                  0
                  • kkoehneK kkoehne

                    @cibo005 said in yet another CMake project configuration failed:

                    @kkoehne Thank you for your replay. Please have a look at what I've installed. Even though I have installed MinGW I cannot see it under the kits.

                    That's indeed a bit weird.

                    Do you use the Qt Creator that's shipped with the Qt SDK (e.g. in D:\Qt\Tools\QtCreator? If that's the case, maybe try to launch with clean settings:

                    "D:\Qt\Tools\QtCreator\bin\qtcreator.exe" -tcs
                    

                    Does it show the MinGW kit then?

                    You can of course configure a MinGW kit manually, too. Just make sure that the Qt version matches the configured toolchain.

                    C Offline
                    C Offline
                    cibo005
                    wrote on last edited by
                    #9

                    @kkoehne Yes, I've just fallowed the "click path", download from website and play a little bit with it. I feel it might be from DevOps side, not sure, since, some packages are missing, as I've got another error message at installation on another thread just to signal that.
                    After your suggestion, something change, but still I cannot see it.

                    error 7.jpg

                    kkoehneK 1 Reply Last reply
                    0
                    • C cibo005

                      @kkoehne Yes, I've just fallowed the "click path", download from website and play a little bit with it. I feel it might be from DevOps side, not sure, since, some packages are missing, as I've got another error message at installation on another thread just to signal that.
                      After your suggestion, something change, but still I cannot see it.

                      error 7.jpg

                      kkoehneK Offline
                      kkoehneK Offline
                      kkoehne
                      Moderators
                      wrote on last edited by
                      #10

                      @cibo005 said in yet another CMake project configuration failed:

                      I've got another error message at installation on another thread just to signal that.

                      Alright, this explains why the installation is somewhat borked :/ If you want, you should be able to debug it a bit by looking into InstallationLog.txt . Look in particular for calls to 'sdktool' - this is the command line tool that the installer uses to tell Qt Creator about installed Qt versions, configures Kits ...

                      Anyhow, if you just want to get going (and not reinstall anew), I suggest you to just reinstall from scratch.

                      Director R&D, The Qt Company

                      C 1 Reply Last reply
                      0
                      • kkoehneK kkoehne

                        @cibo005 said in yet another CMake project configuration failed:

                        I've got another error message at installation on another thread just to signal that.

                        Alright, this explains why the installation is somewhat borked :/ If you want, you should be able to debug it a bit by looking into InstallationLog.txt . Look in particular for calls to 'sdktool' - this is the command line tool that the installer uses to tell Qt Creator about installed Qt versions, configures Kits ...

                        Anyhow, if you just want to get going (and not reinstall anew), I suggest you to just reinstall from scratch.

                        C Offline
                        C Offline
                        cibo005
                        wrote on last edited by
                        #11

                        @kkoehne When I've uninstalled the software it gave me an error message
                        error uninstall.jpg
                        now it works ok after reinstalling.

                        1 Reply Last reply
                        0
                        • C cibo005 has marked this topic as solved on

                        • Login

                        • Login or register to search.
                        • First post
                          Last post
                        0
                        • Categories
                        • Recent
                        • Tags
                        • Popular
                        • Users
                        • Groups
                        • Search
                        • Get Qt Extensions
                        • Unsolved