[PyQt] Failed to build PyQt5 under CentOS6, qwebengineview.sip error

Phil Thompson phil at riverbankcomputing.com
Mon Aug 24 11:26:32 BST 2015


On 22 Aug 2015, at 7:45 pm, li zJay <zjay1987 at gmail.com> wrote:
> 
> Hello:
> 
> PyQt version: PyQt-gpl-5.5.1-snapshot-698e32887e28
> SIP version: 4.16.9
> Qt version: 5.5.0
> Python version: 2.7.8
> Linux kernel: 2.6.32-504.3.3.el6.x86_64
> Linux release: CentOS 6.6
> 
> Error message:
> ...
> make[1]: Entering directory `/tmp/PyQt-gpl-5.5.1-snapshot-698e32887e28/QtWebEngineWidgets'
> g++ -c -pipe -fno-exceptions -O2 -std=c++0x -Wall -W -D_REENTRANT -fPIC -DSIP_PROTECTED_IS_PUBLIC -Dprotected=public -DQT_NO_DEBUG -DQT_PLUGIN -DQT_WEBENGINEWIDGETS_LIB -DQT_WEBENGINE_LIB -DQT_QUICK_LIB -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_QML_LIB -DQT_NETWORK_LIB -DQT_WEBCHANNEL_LIB -DQT_CORE_LIB -I. -I. -I/usr/local/python-2.7.8/include/python2.7 -I/home/zjay/bin/Qt5.5.0/5.5/gcc_64/include -I/home/zjay/bin/Qt5.5.0/5.5/gcc_64/include/QtWebEngineWidgets -I/home/zjay/bin/Qt5.5.0/5.5/gcc_64/include/QtWebEngine -I/home/zjay/bin/Qt5.5.0/5.5/gcc_64/include/QtQuick -I/home/zjay/bin/Qt5.5.0/5.5/gcc_64/include/QtWidgets -I/home/zjay/bin/Qt5.5.0/5.5/gcc_64/include/QtGui -I/home/zjay/bin/Qt5.5.0/5.5/gcc_64/include/QtQml -I/home/zjay/bin/Qt5.5.0/5.5/gcc_64/include/QtNetwork -I/home/zjay/bin/Qt5.5.0/5.5/gcc_64/include/QtWebChannel -I/home/zjay/bin/Qt5.5.0/5.5/gcc_64/include/QtCore -I. -I/home/zjay/bin/Qt5.5.0/5.5/gcc_64/mkspecs/linux-g++ -o sipQtWebEngineWidgetsQWebEngineView.o sipQtWebEngineWidgetsQWebEngineView.cpp
> /tmp/PyQt-gpl-5.5.1-snapshot-698e32887e28/sip/QtWebEngineWidgets/qwebengineview.sip: In function ‘PyObject* meth_QWebEngineView_findText(PyObject*, PyObject*, PyObject*)’:
> /tmp/PyQt-gpl-5.5.1-snapshot-698e32887e28/sip/QtWebEngineWidgets/qwebengineview.sip:93: error: expected primary-expression before ‘[’ token
> /tmp/PyQt-gpl-5.5.1-snapshot-698e32887e28/sip/QtWebEngineWidgets/qwebengineview.sip:93: error: expected primary-expression before ‘bool’
> make[1]: *** [sipQtWebEngineWidgetsQWebEngineView.o] Error 1
> make[1]: Leaving directory `/tmp/PyQt-gpl-5.5.1-snapshot-698e32887e28/QtWebEngineWidgets'
> make: *** [sub-QtWebEngineWidgets-make_first-ordered] Error 2
> 
> 
> Can somebody help? Thanks!

As David suggested you probably need a more modern C++ compiler. The code it is failing on is a lambda function. PyQt asks for a C++11 capable compiler but maybe qmake doesn't complain if it can't supply one.

Phil


More information about the PyQt mailing list