首页 > 解决方案 > 在 Ubuntu 20.04 上安装 PySide/ShiBoken

问题描述

我一直在尝试shiboken在 Ubuntu 20.04(Focal)上的 venv 中安装 PySide(更具体地说,是 PySide 的依赖项)。但是,CMake 似乎很难找到 Qt。

...
-- Found unsuitable Qt version "5.12.8" from /usr/bin/qmake
    -- Found PythonLibs: /usr/lib/x86_64-linux-gnu/libpython2.7.so (found suitable version "2.7.18", minimum required is "2.6")
    -- Found LibXml2: /usr/lib/x86_64-linux-gnu/libxml2.so (found suitable version "2.9.10", minimum required is "2.6.32")
    -- Found LibXslt: /usr/lib/x86_64-linux-gnu/libxslt.so (found suitable version "1.1.34", minimum required is "1.1.19")
    Qt QTGUI library not found.
    Qt QTXML library not found.
    Qt QTCORE library not found.
    CMake Error at ApiExtractor/CMakeLists.txt:82 (qt4_add_resources):
      Unknown CMake command "qt4_add_resources".
    
    
    -- Configuring incomplete, errors occurred!
    See also "/tmp/pip-install-stnnA9/shiboken/shiboken_build/py2.7-qt5.12.8-64bit-release/shiboken/CMakeFiles/CMakeOutput.log".
    error: Error configuring shiboken

我安装了Qt5,看来shiboken想要Qt4?有没有办法让它与 Qt5 配合得很好?如果那不可能,我该如何降级到 Qt4?

标签: pythonqtpysideshiboken2

解决方案


推荐阅读