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. [SOLVED] I get an IDE warnings such as "cstring: no such file or directory" but the project compiles just fine. Also, complete does not work. Qt Crea
Forum Updated to NodeBB v4.3 + New Features

[SOLVED] I get an IDE warnings such as "cstring: no such file or directory" but the project compiles just fine. Also, complete does not work. Qt Crea

Scheduled Pinned Locked Moved Qt Creator and other tools
10 Posts 3 Posters 9.5k Views 1 Watching
  • 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.
  • V Offline
    V Offline
    vincegata
    wrote on last edited by
    #1

    Hello,

    I use QtCreator 2.4.1 on Ubuntu, C++ projects with my own makefiles.

    I've suddenly started getting the warnings such as "cstring: no such file or directory" on the line #include<cstring>. I get such warnings on every single #include line in every header file. These are IDE warnings as my #include lines are underscored but compiler does not give any warnings. So the projects are compiled and build just fine but the warnings are plain annoying.

    Could someone help me with this? TIA!

    1 Reply Last reply
    0
    • V Offline
      V Offline
      vincegata
      wrote on last edited by
      #2

      There is something wrong: Ctrl-Space Complete does not work. I do not think I've changed the environment.

      1 Reply Last reply
      0
      • S Offline
        S Offline
        shoyeb
        wrote on last edited by
        #3

        if control space is not working then this means that Qt is not able to find it.
        please check ur project settings.
        u might have missed out some includes.

        There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code.

        1 Reply Last reply
        0
        • V Offline
          V Offline
          vincegata
          wrote on last edited by
          #4

          Is it in Projects->Build Settings->Build Environment? I did not delete anything from there, it used to work few days ago.

          The problem is the same for four projects that I have in the session.

          1 Reply Last reply
          0
          • T Offline
            T Offline
            tobias.hunger
            wrote on last edited by
            #5

            You are using your own Makefiles as in a "generic project"? If so then Creator will not pick up include pathes from the project and you need to pass them via one of the files we provide when opening the project for the first time.

            Creator will pick up default pathes from the compiler you selected (Project->Build Settings->Tool chain), so make sure you have the correct one there.

            I hope this help.

            1 Reply Last reply
            0
            • V Offline
              V Offline
              vincegata
              wrote on last edited by
              #6

              Right, I am using my own Makefiles with make not qmake. I created my own *.pro files. Complete works for my own classes but not for the C++ classes.

              There is Options->Build and run->Tool Chain - it correctly auto detected g++ and path to it.

              Where do I set the path to include files?

              1 Reply Last reply
              0
              • T Offline
                T Offline
                tobias.hunger
                wrote on last edited by
                #7

                You can set include pathes in your .pro-file.

                The default compiler include pathes are extracted by Creator from gcc by running "COMPILERPATH -xc++ -E -v -".

                1 Reply Last reply
                0
                • V Offline
                  V Offline
                  vincegata
                  wrote on last edited by
                  #8

                  How do I set include paths in the *.pro file? I cannot find the syntax in the documentation. My *.pro file looks like this:
                  @
                  TEMPLATE = app
                  CONFIG += console
                  CONFIG -= qt

                  SOURCES +=
                  tcpsocket.cpp
                  helper.cpp
                  order.cpp
                  fix44.cpp

                  HEADERS +=
                  tcpsocket.h
                  helper.h
                  order.h
                  fix44.h
                  @

                  [Edit: Wrapped in @ tags to preserve formatting. -mlong]

                  1 Reply Last reply
                  0
                  • T Offline
                    T Offline
                    tobias.hunger
                    wrote on last edited by
                    #9

                    Try
                    @
                    INCLUDEPATH += some/dir some/other/dir
                    @

                    1 Reply Last reply
                    0
                    • V Offline
                      V Offline
                      vincegata
                      wrote on last edited by
                      #10

                      I see thank you!

                      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