PyQt5:安装期间编译失败



我在安装PyQt-glp-5.4:时遇到了这个问题

cd QtCore/ && ( test -e Makefile || /usr/lib/x86_64-linux-gnu/qt5/bin/qmake /home/thiago/Downloads/PyQt-gpl-5.4/QtCore/QtCore.pro -o Makefile ) && make -f Makefile 
make[1]: Entering directory `/home/thiago/Downloads/PyQt-gpl-5.4/QtCore'
g++ -c -m64 -pipe -fno-exceptions -O2 -Wall -W -D_REENTRANT -fPIC -DSIP_PROTECTED_IS_PUBLIC -Dprotected=public -DQT_NO_DEBUG -DQT_PLUGIN -DQT_CORE_LIB -I/usr/share/qt5/mkspecs/linux-g++-64 -I. -I. -I/usr/include/python3.2mu -I../qpy/QtCore -I/usr/include/qt5 -I/usr/include/qt5/QtCore -I. -o sipQtCoreQItemSelectionModel.o sipQtCoreQItemSelectionModel.cpp
g++ -c -m64 -pipe -fno-exceptions -O2 -Wall -W -D_REENTRANT -fPIC -DSIP_PROTECTED_IS_PUBLIC -Dprotected=public -DQT_NO_DEBUG -DQT_PLUGIN -DQT_CORE_LIB -I/usr/share/qt5/mkspecs/linux-g++-64 -I. -I. -I/usr/include/python3.2mu -I../qpy/QtCore -I/usr/include/qt5 -I/usr/include/qt5/QtCore -I. -o sipQtCoreQList0100QModelIndex.o sipQtCoreQList0100QModelIndex.cpp
g++ -c -m64 -pipe -fno-exceptions -O2 -Wall -W -D_REENTRANT -fPIC -DSIP_PROTECTED_IS_PUBLIC -Dprotected=public -DQT_NO_DEBUG -DQT_PLUGIN -DQT_CORE_LIB -I/usr/share/qt5/mkspecs/linux-g++-64 -I. -I. -I/usr/include/python3.2mu -I../qpy/QtCore -I/usr/include/qt5 -I/usr/include/qt5/QtCore -I. -o sipQtCoreQRegularExpressionMatch.o sipQtCoreQRegularExpressionMatch.cpp
g++ -c -m64 -pipe -fno-exceptions -O2 -Wall -W -D_REENTRANT -fPIC -DSIP_PROTECTED_IS_PUBLIC -Dprotected=public -DQT_NO_DEBUG -DQT_PLUGIN -DQT_CORE_LIB -I/usr/share/qt5/mkspecs/linux-g++-64 -I. -I. -I/usr/include/python3.2mu -I../qpy/QtCore -I/usr/include/qt5 -I/usr/include/qt5/QtCore -I. -o sipQtCoreQMessageLogger.o sipQtCoreQMessageLogger.cpp
g++ -c -m64 -pipe -fno-exceptions -O2 -Wall -W -D_REENTRANT -fPIC -DSIP_PROTECTED_IS_PUBLIC -Dprotected=public -DQT_NO_DEBUG -DQT_PLUGIN -DQT_CORE_LIB -I/usr/share/qt5/mkspecs/linux-g++-64 -I. -I. -I/usr/include/python3.2mu -I../qpy/QtCore -I/usr/include/qt5 -I/usr/include/qt5/QtCore -I. -o sipQtCoreQDir.o sipQtCoreQDir.cpp
g++ -c -m64 -pipe -fno-exceptions -O2 -Wall -W -D_REENTRANT -fPIC -DSIP_PROTECTED_IS_PUBLIC -Dprotected=public -DQT_NO_DEBUG -DQT_PLUGIN -DQT_CORE_LIB -I/usr/share/qt5/mkspecs/linux-g++-64 -I. -I. -I/usr/include/python3.2mu -I../qpy/QtCore -I/usr/include/qt5 -I/usr/include/qt5/QtCore -I. -o sipQtCoreQEvent.o sipQtCoreQEvent.cpp
g++ -c -m64 -pipe -fno-exceptions -O2 -Wall -W -D_REENTRANT -fPIC -DSIP_PROTECTED_IS_PUBLIC -Dprotected=public -DQT_NO_DEBUG -DQT_PLUGIN -DQT_CORE_LIB -I/usr/share/qt5/mkspecs/linux-g++-64 -I. -I. -I/usr/include/python3.2mu -I../qpy/QtCore -I/usr/include/qt5 -I/usr/include/qt5/QtCore -I. -o sipQtCoreQSettings.o sipQtCoreQSettings.cpp
g++ -c -m64 -pipe -fno-exceptions -O2 -Wall -W -D_REENTRANT -fPIC -DSIP_PROTECTED_IS_PUBLIC -Dprotected=public -DQT_NO_DEBUG -DQT_PLUGIN -DQT_CORE_LIB -I/usr/share/qt5/mkspecs/linux-g++-64 -I. -I. -I/usr/include/python3.2mu -I../qpy/QtCore -I/usr/include/qt5 -I/usr/include/qt5/QtCore -I. -o sipQtCoreQAnimationGroup.o sipQtCoreQAnimationGroup.cpp
g++ -c -m64 -pipe -fno-exceptions -O2 -Wall -W -D_REENTRANT -fPIC -DSIP_PROTECTED_IS_PUBLIC -Dprotected=public -DQT_NO_DEBUG -DQT_PLUGIN -DQT_CORE_LIB -I/usr/share/qt5/mkspecs/linux-g++-64 -I. -I. -I/usr/include/python3.2mu -I../qpy/QtCore -I/usr/include/qt5 -I/usr/include/qt5/QtCore -I. -o sipQtCoreQSortFilterProxyModel.o sipQtCoreQSortFilterProxyModel.cpp
g++ -c -m64 -pipe -fno-exceptions -O2 -Wall -W -D_REENTRANT -fPIC -DSIP_PROTECTED_IS_PUBLIC -Dprotected=public -DQT_NO_DEBUG -DQT_PLUGIN -DQT_CORE_LIB -I/usr/share/qt5/mkspecs/linux-g++-64 -I. -I. -I/usr/include/python3.2mu -I../qpy/QtCore -I/usr/include/qt5 -I/usr/include/qt5/QtCore -I. -o sipQtCoreQAbstractTransition.o sipQtCoreQAbstractTransition.cpp
g++ -c -m64 -pipe -fno-exceptions -O2 -Wall -W -D_REENTRANT -fPIC -DSIP_PROTECTED_IS_PUBLIC -Dprotected=public -DQT_NO_DEBUG -DQT_PLUGIN -DQT_CORE_LIB -I/usr/share/qt5/mkspecs/linux-g++-64 -I. -I. -I/usr/include/python3.2mu -I../qpy/QtCore -I/usr/include/qt5 -I/usr/include/qt5/QtCore -I. -o sipQtCoreQIODevice.o sipQtCoreQIODevice.cpp
g++ -c -m64 -pipe -fno-exceptions -O2 -Wall -W -D_REENTRANT -fPIC -DSIP_PROTECTED_IS_PUBLIC -Dprotected=public -DQT_NO_DEBUG -DQT_PLUGIN -DQT_CORE_LIB -I/usr/share/qt5/mkspecs/linux-g++-64 -I. -I. -I/usr/include/python3.2mu -I../qpy/QtCore -I/usr/include/qt5 -I/usr/include/qt5/QtCore -I. -o sipQtCoreQJsonDocument.o sipQtCoreQJsonDocument.cpp
/home/thiago/Downloads/PyQt-gpl-5.4/QtCore/sipQtCoreQJsonDocument.cpp: In function ‘PyObject* meth_QJsonDocument_toJson(PyObject*, PyObject*)’:
/home/thiago/Downloads/PyQt-gpl-5.4/QtCore/sipQtCoreQJsonDocument.cpp:285:9: error: ‘JsonFormat’ is not a member of ‘QJsonDocument’
/home/thiago/Downloads/PyQt-gpl-5.4/QtCore/sipQtCoreQJsonDocument.cpp:285:35: error: expected ‘;’ before ‘a0’
/home/thiago/Downloads/PyQt-gpl-5.4/QtCore/sipQtCoreQJsonDocument.cpp:288:132: error: ‘a0’ was not declared in this scope
/home/thiago/Downloads/PyQt-gpl-5.4/QtCore/sipQtCoreQJsonDocument.cpp: At global scope:
/home/thiago/Downloads/PyQt-gpl-5.4/QtCore/sipQtCoreQJsonDocument.cpp:723:40: error: ‘Compact’ is not a member of ‘QJsonDocument’
/home/thiago/Downloads/PyQt-gpl-5.4/QtCore/sipQtCoreQJsonDocument.cpp:724:41: error: ‘Indented’ is not a member of ‘QJsonDocument’
make[1]: *** [sipQtCoreQJsonDocument.o] Error 1
make[1]: Leaving directory `/home/thiago/Downloads/PyQt-gpl-5.4/QtCore'
make: *** [sub-QtCore-make_first-ordered] Error 2

我打开了PyQt5http://www.riverbankcomputing.com/software/pyqt/download5

有人知道发生了什么吗?

谢谢!!

QJsonDocument类中的JsonFormat类型是在版本5.1中添加的,所以这可能是因为您有Qt版本5.0:

http://doc.qt.digia.com/qt-5.0/qtcore/qjsondocument.html

http://doc.qt.digia.com/qt-5.1/qtcore/qjsondocument.html

相关内容

  • 没有找到相关文章

最新更新