Uploaded image for project: 'Qt for Python'
  1. Qt for Python
  2. PYSIDE-1259

Clang not found if the major version is bigger than 9

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P3: Somewhat important
    • None
    • 5.13.2, 5.14.2
    • PySide, Shiboken
    • None
    • Linux/X11
    • 9ae63824a5ec550e82561b9f07fc6307ae1f3cec (pyside/pyside-setup/5.14)

    Description

      Having Clang version 10.0.0 will trigger trigger the following error when compiling pyside from source:

      Unable to locate Clang's built-in include directory (neither by checking the environment variables LLVM_INSTALL_DIR, CLANG_INSTALL_DIR nor running llvm-config). This may lead to parse errors.

      The error appear because in findClangBuiltInIncludesDir method from sources/shiboken2/ApiExtractor/clangparser/compilersupport.cpp file, the major version is considered as 1 digit and the subsequent test fails

      const QVersionNumber versionNumber = QVersionNumber::fromString(fileName.at(0));
       if (!versionNumber.isNull() && versionNumber > lastVersionNumber) {

      Changing

      QVersionNumber lastVersionNumber(1, 0, 0);

      to

      QVersionNumber lastVersionNumber(0, 0, 0);

      will allow compilation to continue.

       

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              kleint Friedemann Kleint
              ciprian.stingu Ciprian Stingu
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes