[Interest] QtCreator oddity

Elvis Stansvik elvstone at gmail.com
Fri Apr 20 21:28:30 CEST 2018


2018-04-20 21:17 GMT+02:00 Roland Hughes <roland at logikalsolutions.com>:
>
>
> On 04/20/2018 08:04 AM, Konstantin Tokarev wrote:
>>
>>
>> 20.04.2018, 16:01, "Roland Hughes" <roland at logikalsolutions.com>:
>>>
>>> On 04/20/2018 07:55 AM, Konstantin Tokarev wrote:
>>>>
>>>>   20.04.2018, 15:19, "Roland Hughes" <roland at logikalsolutions.com>:
>>>>>
>>>>>   On 04/20/2018 06:40 AM, Thiago Macieira wrote:
>>>>>>
>>>>>>   On Wednesday, 18 April 2018 10:18:05 PDT Konstantin Tokarev wrote:
>>>>>>>
>>>>>>>   #include <libusb-1.0/libusb.h>
>>>>>>
>>>>>>   DO NOT write that. The correct line for libusb is: #include
>>>>>> <libusb.h> If that file is not in your default search path, then add it to
>>>>>> INCLUDEPATH or via pkg-config. PKGCONFIG += libusb-1.0
>>>>>
>>>>>   The problem isn't the default search path. The problem is QtCreator
>>>>> cannot handle directories with a "." in their name underneath /usr/include.
>>>>> One has to force it in with
>>>>>
>>>>>   INCLUDEPATH +=/usr/include/libusb-1.0
>>>>
>>>>   There is no force here. You cannot #include <libusb.h> unless compiler
>>>> is provided with -I/usr/include/libusb-1.0 option instructing it to look in
>>>> this directory.
>>>>
>>>>>   By default, everything under /usr/include should be found and, if the
>>>>> directory doesn't have a . in the name it is.
>>>>>
>>>>>   -- Roland Hughes, President Logikal Solutions (630)-205-1593
>>>>> http://www.theminimumyouneedtoknow.com http://www.infiniteexposure.net
>>>>> http://www.johnsmith-book.com http://www.logikalblog.com
>>>>> http://www.interestingauthors.com/blog http://lesedi.us/
>>>>> http://onedollarcontentstore.com
>>>>>   ,
>>>
>>> Yes, there is a force here. Having to inform the environment about a
>>> directory underneath /usr/include is a force. By design all directories
>>> in that tree are searched.
>>
>> Your understanding is wrong. Please read documentation of your compiler
>> more carefully.
>>
> My understanding is completely correct and the test posted in this thread
> proved it. Manually creating aa directory under /usr/include had aa show up
> in QtCreator. Manually creating a.a does not appear in QtCreator.
>
> The directory gets walked.
>
> This is ___NOT___ a compiler problem. I'm talking about QtCreator being
> unable to find the include files. I can compile a non-qt program from the
> command line just fine.
>
> Please consider the previous evidence before firing off an unfounded
> response.

Roland, I think when you said in your original mail that the problem
occurred "When typing in the editor and compiling", everyone though
you meant you were getting compilation errors (so not just an
auto-completion issue).

If this is only about auto-completion in Qt Creator, then I think this
whole thread could have been much shorter.

Cheers,
Elvis

>
> --
> Roland Hughes, President
> Logikal Solutions
> (630)-205-1593
>
> http://www.theminimumyouneedtoknow.com
> http://www.infiniteexposure.net
> http://www.johnsmith-book.com
> http://www.logikalblog.com
> http://www.interestingauthors.com/blog
> http://lesedi.us/
> http://onedollarcontentstore.com
>
> _______________________________________________
> Interest mailing list
> Interest at qt-project.org
> http://lists.qt-project.org/mailman/listinfo/interest



More information about the Interest mailing list