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

Warning: The code model could not parse an included file, which might lead...

    XMLWordPrintable

Details

    • Bug
    • Resolution: Out of scope
    • Not Evaluated
    • None
    • Qt Creator 4.13.0
    • None
    • Linux/X11

    Description

      I have a custom toolkit in a separate folder.

      I have added the toolkit manually.

      QT Creator claims it cannot find the file stddef.h. But even while displaying the red circle in the left margin, I am able to <CTRL>-click the file and the editor is able to find it.

      If I do:

      $ /usr/local/toolchains/arm-buildroot-linux-gnueabi_sdk-buildroot-kh_4.9-gcc_9-arm/bin/arm-buildroot-linux-gnueabi-cpp -v
      Using built-in specs.
      COLLECT_GCC=/usr/local/toolchains/arm-buildroot-linux-gnueabi_sdk-buildroot-kh_4.9-gcc_9-arm/bin/arm-buildroot-linux-gnueabi-cpp.br_real
      Target: arm-buildroot-linux-gnueabi
      Configured with: ./configure -prefix=/home/mroberto/cpti/hg/pig/buildroot/output/host --sysconfdir=/home/mroberto/cpti/hg/pig/buildroot/output/host/etc --enable-static --target=arm-buildroot-linux-gnueabi --with-sysroot=/home/mroberto/cpti/hg/pig/buildroot/output/host/arm-buildroot-linux-gnueabi/sysroot --enable__cxa_atexit --with-gnu-ld --disable-libssp --disable-multilib --disable-decimal-float --with-gmp=/home/mroberto/cpti/hg/pig/buildroot/output/host --with-mpc=/home/mroberto/cpti/hg/pig/buildroot/output/host --with-mpfr=/home/mroberto/cpti/hg/pig/buildroot/output/host --with-pkgversion='Buildroot 2019.11-00018-g90fba2ca74-dirty' --with-bugurl=http://bugs.buildroot.net/ --disable-libquadmath --enable-tls --enable-threads --without-isl --without-cloog --with-float=soft --with-abi=aapcs-linux --with-cpu=arm926ej-s --with-float=soft --with-mode=arm --enable-languages=c,c++ --with-build-time-tools=/home/mroberto/cpti/hg/pig/buildroot/output/host/arm-buildroot-linux-gnueabi/bin --enable-shared --disable-libgomp
      Thread model: posix
      gcc version 9.2.0 (Buildroot 2019.11-00018-g90fba2ca74-dirty)
      COLLECT_GCC_OPTIONS='-E' '-v' '-mcpu=arm926ej-s' '-mfloat-abi=soft' '-mabi=aapcs-linux' '-marm' '-mtls-dialect=gnu' '-march=armv5tej'
      /usr/local/toolchains/arm-buildroot-linux-gnueabi_sdk-buildroot-kh_4.9-gcc_9-arm/bin/../libexec/gcc/arm-buildroot-linux-gnueabi/9.2.0/cc1 -E -quiet -v -iprefix /usr/local/toolchains/arm-buildroot-linux-gnueabi_sdk-buildroot-kh_4.9-gcc_9-arm/bin/../lib/gcc/arm-buildroot-linux-gnueabi/9.2.0/ -isysroot /usr/local/toolchains/arm-buildroot-linux-gnueabi_sdk-buildroot-kh_4.9-gcc_9-arm/arm-buildroot-linux-gnueabi/sysroot - -mcpu=arm926ej-s -mfloat-abi=soft -mabi=aapcs-linux -marm -mtls-dialect=gnu -march=armv5tej
      ignoring duplicate directory "/usr/local/toolchains/arm-buildroot-linux-gnueabi_sdk-buildroot-kh_4.9-gcc_9-arm/bin/../lib/gcc/../../lib/gcc/arm-buildroot-linux-gnueabi/9.2.0/include"
      ignoring nonexistent directory "/usr/local/toolchains/arm-buildroot-linux-gnueabi_sdk-buildroot-kh_4.9-gcc_9-arm/arm-buildroot-linux-gnueabi/sysroot/usr/local/include"
      ignoring duplicate directory "/usr/local/toolchains/arm-buildroot-linux-gnueabi_sdk-buildroot-kh_4.9-gcc_9-arm/bin/../lib/gcc/../../lib/gcc/arm-buildroot-linux-gnueabi/9.2.0/include-fixed"
      ignoring duplicate directory "/usr/local/toolchains/arm-buildroot-linux-gnueabi_sdk-buildroot-kh_4.9-gcc_9-arm/bin/../lib/gcc/../../lib/gcc/arm-buildroot-linux-gnueabi/9.2.0/../../../../arm-buildroot-linux-gnueabi/include"
      #include "..." search starts here:
      #include <...> search starts here:
      /usr/local/toolchains/arm-buildroot-linux-gnueabi_sdk-buildroot-kh_4.9-gcc_9-arm/bin/../lib/gcc/arm-buildroot-linux-gnueabi/9.2.0/include
      /usr/local/toolchains/arm-buildroot-linux-gnueabi_sdk-buildroot-kh_4.9-gcc_9-arm/bin/../lib/gcc/arm-buildroot-linux-gnueabi/9.2.0/include-fixed
      /usr/local/toolchains/arm-buildroot-linux-gnueabi_sdk-buildroot-kh_4.9-gcc_9-arm/bin/../lib/gcc/arm-buildroot-linux-gnueabi/9.2.0/../../../../arm-buildroot-linux-gnueabi/include
      /usr/local/toolchains/arm-buildroot-linux-gnueabi_sdk-buildroot-kh_4.9-gcc_9-arm/arm-buildroot-linux-gnueabi/sysroot/usr/include
      End of search list.

      From this list, I got the four paths that could be giving me trouble. If I add them to the .includes file the code model works perfectly without warnings.

      Not being able to find stddef.h causes lots of error and warning messages on the code model, rendering it useless. Also, my workaround of including the paths in a .include file should not be necessary.

      Attachments

        Issue Links

          Activity

            People

              kandeler Christian Kandeler
              marcelo.jimenez Marcelo Jimenez
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: