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

QbsPM: cpp.distributionIncludePaths has not effect for headers highlighting

XMLWordPrintable

    • Linux/Wayland, Windows
    • 7fad01eb026d92007fc8a813601625a465c1db6a (qt-creator/qt-creator/master)

      When we use QBS project and specify there the cpp.distributionIncludePaths property, then the header files from that paths highlighted as 'undefined'. Also the defines from that files not highlighted too.

      Note: at least this makes sense only with GCC-based toolchains, where '-system' option has effects.

      Please look on an example sources from an attached archive:

      == app.qbs ==

      import qbs
      
      Application {
          condition: {
              console.info("p: " + cpp.distributionIncludePaths)
              return true
          }
      
          Properties {
              condition: qbs.toolchain.contains("gcc")
              cpp.driverFlags: [
                  "-mcpu=cortex-m3",
                  "-specs=nosys.specs"
              ]
          }
      
          consoleApplication: true
          Depends { name: "cpp" }
          cpp.distributionIncludePaths: [ sourceDirectory  + "/dist-includes"]
          files : [ "main.cpp" ]
      }
      

      == main.cpp ==

      #include <foo.h>
      
      int main()
      {
          return FOO;
      }
      

      == foo.h ==

      #pragma once
      
      #define FOO 123
      

        1. qtcbug-24162.zip
          0.7 kB
        2. dist-paths-bug.png
          dist-paths-bug.png
          13 kB
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            kandeler Christian Kandeler
            kuzulis Denis Shienkov
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes