Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. Qt Creator failing to find Qt headers in working cmake+Qt project

Qt Creator failing to find Qt headers in working cmake+Qt project

Scheduled Pinned Locked Moved Unsolved Qt Creator and other tools
5 Posts 2 Posters 908 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.
  • R Offline
    R Offline
    rmam
    wrote on last edited by
    #1

    I've installed Qt from Qt's online installer in Ubuntu 16.04, and I am using Qt Creator to work on a cmake+Qt project. The Qt project links to the Qt versions installed by Qt's online installer by setting the path to the Qt library through the CMAKE_PREFIX_PATH variable.

    Although the Qt Creator manages to build the project without any problem, Qt Creator is unable to find any Qt headers, listing every #include statement as "No such file or directory" and failing to run any autocompletion on Qt code.

    Does anyone know how to get Qt Creator to find Qt headers in a cmake+Qt project?

    1 Reply Last reply
    0
    • R Offline
      R Offline
      rmam
      wrote on last edited by
      #2

      Does anyone know how Qt Creator determines where are Qt's source code in a cmake project?

      1 Reply Last reply
      0
      • SGaistS Offline
        SGaistS Offline
        SGaist
        Lifetime Qt Champion
        wrote on last edited by
        #3

        Hi,

        It's determined by the Kit used.

        What version of Qt Creator are you using ?

        Interested in AI ? www.idiap.ch
        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

        1 Reply Last reply
        1
        • R Offline
          R Offline
          rmam
          wrote on last edited by
          #4

          @SGaist I'm using Qt Creator 4.6.2.

          1 Reply Last reply
          0
          • SGaistS Offline
            SGaistS Offline
            SGaist
            Lifetime Qt Champion
            wrote on last edited by
            #5

            Did you check your kit for any errors ?

            Interested in AI ? www.idiap.ch
            Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

            1 Reply Last reply
            0

            • Login

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