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

Build error: no member named 'AutoDecRef' in namespace 'Shiboken'

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P3: Somewhat important
    • 6.5.5
    • 6.5.4
    • Shiboken
    • None
    • MacOS m1 / Sonoma with Python 3.10.11
      Linux redhat 8 with Python 3.10.11
    • Linux/X11, macOS
    • a9a46a6ec (tqtc/lts-6.5)

    Description

      I downloaded qtforpython 6.5.4 from qt web site.

      I have built qt 6.5.4 on MacOs and Linux and now, I try to build the corresponding version of qtforpython on the same platforms.

      During compilation, I met the following error:

      [59/2205] Building CXX object sources/shiboken6/libshiboken/CMakeFiles/libshiboken.dir/sbkcontainer.cpp.o
      FAILED: sources/shiboken6/libshiboken/CMakeFiles/libshiboken.dir/sbkcontainer.cpp.o 
      /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++ -DBUILD_LIBSHIBOKEN -DNDEBUG -DPy_LIMITED_API=0x03060000 -I/Users/ycollette/tmp/tqtc-pyside-setup-everywhere-src-lts-6.5.4/sources/shiboken6/libshiboken -I/Users/ycollette/tmp/tqtc-pyside-setup-everywhere-src-lts-6.5.4/build/sources/shiboken6/libshiboken -I/opt/alg/python-3.10.11-p3/include/python3.10 -Wall -Wextra -Wno-strict-aliasing -fvisibility=hidden -D QT_NO_CAST_FROM_ASCII -D QT_NO_CAST_TO_ASCII -O3 -DNDEBUG -std=gnu++17 -arch arm64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX14.2.sdk -fPIC -fPIC -MD -MT sources/shiboken6/libshiboken/CMakeFiles/libshiboken.dir/sbkcontainer.cpp.o -MF sources/shiboken6/libshiboken/CMakeFiles/libshiboken.dir/sbkcontainer.cpp.o.d -o sources/shiboken6/libshiboken/CMakeFiles/libshiboken.dir/sbkcontainer.cpp.o -c /Users/ycollette/tmp/tqtc-pyside-setup-everywhere-src-lts-6.5.4/sources/shiboken6/libshiboken/sbkcontainer.cpp
      /Users/ycollette/tmp/tqtc-pyside-setup-everywhere-src-lts-6.5.4/sources/shiboken6/libshiboken/sbkcontainer.cpp:13:25: error: expected ';' after expression
      Shiboken::AutoDecRef tpDict(PepType_GetDict(o->ob_type));
      ^
      ;
      /Users/ycollette/tmp/tqtc-pyside-setup-everywhere-src-lts-6.5.4/sources/shiboken6/libshiboken/sbkcontainer.cpp:13:15: error: no member named 'AutoDecRef' in namespace 'Shiboken'
      Shiboken::AutoDecRef tpDict(PepType_GetDict(o->ob_type));
      ~~~~~~~~~~^
      /Users/ycollette/tmp/tqtc-pyside-setup-everywhere-src-lts-6.5.4/sources/shiboken6/libshiboken/sbkcontainer.cpp:13:26: error: use of undeclared identifier 'tpDict'
      Shiboken::AutoDecRef tpDict(PepType_GetDict(o->ob_type));
      ^
      /Users/ycollette/tmp/tqtc-pyside-setup-everywhere-src-lts-6.5.4/sources/shiboken6/libshiboken/sbkcontainer.cpp:15:28: error: use of undeclared identifier 'tpDict'
      && PyDict_Contains(tpDict.object(), Shiboken::PyMagicName::opaque_container()) == 1;
      ^
      4 errors generated.
      [60/2205] Building CXX object sources/shiboken6/ApiExtractor/CMakeFiles/apiextractor.dir/clangparser/clangbuilder.cpp.o
      /Users/ycollette/tmp/tqtc-pyside-setup-everywhere-src-lts-6.5.4/sources/shiboken6/ApiExtractor/clangparser/clangbuilder.cpp:734:24: warning: unused function 'definitionFromTypeRef' [-Wunused-function]
      static inline CXCursor definitionFromTypeRef(const CXCursor &typeRefCursor)
      ^
      1 warning generated.
      [70/2205] Building CXX object sources/shiboken6/ApiExtractor/CMakeFiles/apiextractor.dir/typesystemparser.cpp.o
      ninja: build stopped: subcommand failed.

      I tested Xcode 13 / 15 on MacOS and gcc 11 on Linux.

      The cmake configure command I use:

      cmake -G Ninja -D-DPYTHON_LIBRARY=/opt/python-3.10.11-p3/lib/libpython3.10.dylib  -DPYTHON_INCLUDE_DIR=/opt/alg/python-3.10.11/include/python3.10 ..

      Attachments

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

        Activity

          People

            kleint Friedemann Kleint
            ycollette Yann Collette
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes