Re: [PyQt] PyQt4 issue
On Wed, 6 Mar 2013 12:42:12 +, Chris Roebuck wrote: > This works, however when I run the script: > > from PyQt4.QtWebKit import * > > I get: > > ImportError: /usr/lib/python2.7/dist-packages/PyQt4/QtWebKit.so: undefined > symbol: _ZTI8QWebView Should be fixed with tonight's SIP snapshot (or current hg). You shouldn't need to make the change to PyQt's configure.py with the SIP fix. Thanks, Phil ___ PyQt mailing listPyQt@riverbankcomputing.com http://www.riverbankcomputing.com/mailman/listinfo/pyqt
Re: [PyQt] PyQt4 issue
This works, however when I run the script: from PyQt4.QtWebKit import * I get: ImportError: /usr/lib/python2.7/dist-packages/PyQt4/QtWebKit.so: undefined symbol: _ZTI8QWebView On 6 March 2013 09:55, Phil Thompson wrote: > On Wed, 6 Mar 2013 09:32:31 +, Chris Roebuck > wrote: > > Thanks Phil, > > > > I get the following error when changing configure.py as you suggested: > > > > cfgtest_QtWebKit.cpp: In function ‘int main(int, char**)’: > > cfgtest_QtWebKit.cpp:5:30: error: cannot allocate an object of abstract > > type ‘QWebHistoryInterface’ > > qwebhistoryinterface.h:29:22: note: because the following virtual > > functions are pure within ‘QWebHistoryInterface’: > > qwebhistoryinterface.h:38:18: note: virtual bool > > QWebHistoryInterface::historyContains(const QString&) const > > qwebhistoryinterface.h:39:18: note: virtual void > > QWebHistoryInterface::addHistoryEntry(const QString&) > > > > But I did manage to get the check to pass when > > using check_module("QtWebKit", "qwebelement.h", "new QWebElement()") > > The problem with that is QWebElement wasn't in the first release of > QtWebKit. How about... > > check_module("QtWebKit", "qwebsettings.h", > "QWebSettings::globalSettings()") > > Phil > ___ PyQt mailing listPyQt@riverbankcomputing.com http://www.riverbankcomputing.com/mailman/listinfo/pyqt
Re: [PyQt] PyQt4 issue
On Wed, 6 Mar 2013 09:32:31 +, Chris Roebuck wrote: > Thanks Phil, > > I get the following error when changing configure.py as you suggested: > > cfgtest_QtWebKit.cpp: In function ‘int main(int, char**)’: > cfgtest_QtWebKit.cpp:5:30: error: cannot allocate an object of abstract > type ‘QWebHistoryInterface’ > qwebhistoryinterface.h:29:22: note: because the following virtual > functions are pure within ‘QWebHistoryInterface’: > qwebhistoryinterface.h:38:18: note: virtual bool > QWebHistoryInterface::historyContains(const QString&) const > qwebhistoryinterface.h:39:18: note: virtual void > QWebHistoryInterface::addHistoryEntry(const QString&) > > But I did manage to get the check to pass when > using check_module("QtWebKit", "qwebelement.h", "new QWebElement()") The problem with that is QWebElement wasn't in the first release of QtWebKit. How about... check_module("QtWebKit", "qwebsettings.h", "QWebSettings::globalSettings()") Phil ___ PyQt mailing listPyQt@riverbankcomputing.com http://www.riverbankcomputing.com/mailman/listinfo/pyqt
Re: [PyQt] PyQt4 issue
Thanks Phil, I get the following error when changing configure.py as you suggested: cfgtest_QtWebKit.cpp: In function ‘int main(int, char**)’: cfgtest_QtWebKit.cpp:5:30: error: cannot allocate an object of abstract type ‘QWebHistoryInterface’ qwebhistoryinterface.h:29:22: note: because the following virtual functions are pure within ‘QWebHistoryInterface’: qwebhistoryinterface.h:38:18: note: virtual bool QWebHistoryInterface::historyContains(const QString&) const qwebhistoryinterface.h:39:18: note: virtual void QWebHistoryInterface::addHistoryEntry(const QString&) But I did manage to get the check to pass when using check_module("QtWebKit", "qwebelement.h", "new QWebElement()") On 6 March 2013 08:40, Phil Thompson wrote: > On Wed, 6 Mar 2013 01:25:18 +, Chris Roebuck > wrote: > > Here's my result: > > > > objdump -T libQt5WebKit.so | grep QWebPage | grep QObject > > > > 004a2530 gDF .text 0935 Base > > > > _ZN15QWebPageAdapter26dynamicPropertyChangeEventEP7QObjectP27QDynamicPropertyChangeEvent > > 004a3770 gDF .text 002a Base > > _ZN15QWebPageAdapter17setSystemTrayIconEP7QObject > > > > Interestingly, if I do the same for libQt5WebKitWidgets.so I get what > you > > reported: > > > > objdump -T libQt5WebKitWidgets.so | grep QWebPage | grep QObject > > > > DF *UND* > > _ZN15QWebPageAdapter17setSystemTrayIconEP7QObject > > DF *UND* > > > > _ZN15QWebPageAdapter26dynamicPropertyChangeEventEP7QObjectP27QDynamicPropertyChangeEvent > > 00027570 gDF .text 00a4 Base > > _ZN8QWebPageC1EP7QObject > > 00027570 gDF .text 00a4 Base > > _ZN8QWebPageC2EP7QObject > > Try changing the line in configure.py from... > > check_module("QtWebKit", "qwebpage.h", "new QWebPage()") > > ...to... > > check_module("QtWebKit", "qwebhistoryinterface.h", "new > QWebHistoryInterface()") > > Phil > ___ PyQt mailing listPyQt@riverbankcomputing.com http://www.riverbankcomputing.com/mailman/listinfo/pyqt
Re: [PyQt] PyQt4 issue
On Wed, 6 Mar 2013 01:25:18 +, Chris Roebuck wrote: > Here's my result: > > objdump -T libQt5WebKit.so | grep QWebPage | grep QObject > > 004a2530 gDF .text 0935 Base > _ZN15QWebPageAdapter26dynamicPropertyChangeEventEP7QObjectP27QDynamicPropertyChangeEvent > 004a3770 gDF .text 002a Base > _ZN15QWebPageAdapter17setSystemTrayIconEP7QObject > > Interestingly, if I do the same for libQt5WebKitWidgets.so I get what you > reported: > > objdump -T libQt5WebKitWidgets.so | grep QWebPage | grep QObject > > DF *UND* > _ZN15QWebPageAdapter17setSystemTrayIconEP7QObject > DF *UND* > _ZN15QWebPageAdapter26dynamicPropertyChangeEventEP7QObjectP27QDynamicPropertyChangeEvent > 00027570 gDF .text 00a4 Base > _ZN8QWebPageC1EP7QObject > 00027570 gDF .text 00a4 Base > _ZN8QWebPageC2EP7QObject Try changing the line in configure.py from... check_module("QtWebKit", "qwebpage.h", "new QWebPage()") ...to... check_module("QtWebKit", "qwebhistoryinterface.h", "new QWebHistoryInterface()") Phil ___ PyQt mailing listPyQt@riverbankcomputing.com http://www.riverbankcomputing.com/mailman/listinfo/pyqt
Re: [PyQt] PyQt4 issue
Here's my result: objdump -T libQt5WebKit.so | grep QWebPage | grep QObject 004a2530 gDF .text 0935 Base _ZN15QWebPageAdapter26dynamicPropertyChangeEventEP7QObjectP27QDynamicPropertyChangeEvent 004a3770 gDF .text 002a Base _ZN15QWebPageAdapter17setSystemTrayIconEP7QObject Interestingly, if I do the same for libQt5WebKitWidgets.so I get what you reported: objdump -T libQt5WebKitWidgets.so | grep QWebPage | grep QObject DF *UND* _ZN15QWebPageAdapter17setSystemTrayIconEP7QObject DF *UND* _ZN15QWebPageAdapter26dynamicPropertyChangeEventEP7QObjectP27QDynamicPropertyChangeEvent 00027570 gDF .text 00a4 Base _ZN8QWebPageC1EP7QObject 00027570 gDF .text 00a4 Base _ZN8QWebPageC2EP7QObject On 6 March 2013 00:22, Hans-Peter Jansen wrote: > Am Dienstag, 5. März 2013, 18:44:24 schrieb Detlev Offenbach: > > Hello, > > > > here is the extract. > > > > Checking to see if the QtTest module should be built... > > g++ -DQT_NO_DEBUG -DQT_TEST_LIB -DQT_GUI_LIB -DQT_WIDGETS_LIB -I. - > > I/usr/local/Qt-5.0.1/mkspecs/linux-g++ > -I/usr/local/Qt-5.0.1/include/QtTest > > - I/usr/local/Qt-5.0.1/include -m64 -pipe -O2 -w -D_REENTRANT -fPIE > > cfgtest_QtTest.cpp -o cfgtest_QtTest -L/usr/local/Qt-5.0.1/lib -Wl,-O1 > > -Wl,-rpath,/usr/local/Qt-5.0.1/lib -lQt5Test - L/usr/local/Qt-5.0.1/lib > > -lQt5Core -lpthread -lpthread > > Checking to see if the QtWebKit module should be built... > > g++ -DQT_NO_DEBUG -DQT_WEBKIT_LIB -DQT_CORE_LIB -I. - > > I/usr/local/Qt-5.0.1/mkspecs/linux-g++ > > -I/usr/local/Qt-5.0.1/include/QtWebKit - > > I/usr/local/Qt-5.0.1/include/QtWebKitWidgets > > -I/usr/local/Qt-5.0.1/include/QtCore - I/usr/local/Qt-5.0.1/include -m64 > > -pipe -O2 -w -D_REENTRANT -fPIE cfgtest_QtWebKit.cpp - o cfgtest_QtWebKit > > -L/usr/local/Qt-5.0.1/lib -Wl,-O1 -Wl,-rpath,/usr/local/Qt-5.0.1/lib - > > lQt5WebKit -L/usr/X11R6/lib64 -L/usr/local/Qt-5.0.1/lib -lQt5Network > > -L/usr/local/Qt-5.0.1/lib - lQt5Core -lpthread -lpthread -lQt5Gui > > -L/usr/X11R6/lib64 -L/usr/local/Qt-5.0.1/lib -lQt5Core - lpthread > -lpthread > > -lQt5Core -lpthread -lpthread -lQt5Core -lpthread -lpthread > > /tmp/ccmtGOAm.o: In function `main': > > cfgtest_QtWebKit.cpp:(.text.startup+0x19): undefined reference to > > `QWebPage::QWebPage(QObject*)' > > collect2: error: ld returned 1 exit status > > Hmm, have you checked the symbols in your libQt5WebKit.so? > > objdump -T libQt5WebKit.so | grep QWebPage | grep QObject > > It should show: _ZN8QWebPageC2EP7QObject > > Feeding to c++filt results in: QWebPage::QWebPage(QObject*) > > Any other result is an issue down under.. > > Cheers, > Pete > ___ > PyQt mailing listPyQt@riverbankcomputing.com > http://www.riverbankcomputing.com/mailman/listinfo/pyqt > ___ PyQt mailing listPyQt@riverbankcomputing.com http://www.riverbankcomputing.com/mailman/listinfo/pyqt
Re: [PyQt] PyQt4 issue
Am Dienstag, 5. März 2013, 18:44:24 schrieb Detlev Offenbach: > Hello, > > here is the extract. > > Checking to see if the QtTest module should be built... > g++ -DQT_NO_DEBUG -DQT_TEST_LIB -DQT_GUI_LIB -DQT_WIDGETS_LIB -I. - > I/usr/local/Qt-5.0.1/mkspecs/linux-g++ -I/usr/local/Qt-5.0.1/include/QtTest > - I/usr/local/Qt-5.0.1/include -m64 -pipe -O2 -w -D_REENTRANT -fPIE > cfgtest_QtTest.cpp -o cfgtest_QtTest -L/usr/local/Qt-5.0.1/lib -Wl,-O1 > -Wl,-rpath,/usr/local/Qt-5.0.1/lib -lQt5Test - L/usr/local/Qt-5.0.1/lib > -lQt5Core -lpthread -lpthread > Checking to see if the QtWebKit module should be built... > g++ -DQT_NO_DEBUG -DQT_WEBKIT_LIB -DQT_CORE_LIB -I. - > I/usr/local/Qt-5.0.1/mkspecs/linux-g++ > -I/usr/local/Qt-5.0.1/include/QtWebKit - > I/usr/local/Qt-5.0.1/include/QtWebKitWidgets > -I/usr/local/Qt-5.0.1/include/QtCore - I/usr/local/Qt-5.0.1/include -m64 > -pipe -O2 -w -D_REENTRANT -fPIE cfgtest_QtWebKit.cpp - o cfgtest_QtWebKit > -L/usr/local/Qt-5.0.1/lib -Wl,-O1 -Wl,-rpath,/usr/local/Qt-5.0.1/lib - > lQt5WebKit -L/usr/X11R6/lib64 -L/usr/local/Qt-5.0.1/lib -lQt5Network > -L/usr/local/Qt-5.0.1/lib - lQt5Core -lpthread -lpthread -lQt5Gui > -L/usr/X11R6/lib64 -L/usr/local/Qt-5.0.1/lib -lQt5Core - lpthread -lpthread > -lQt5Core -lpthread -lpthread -lQt5Core -lpthread -lpthread > /tmp/ccmtGOAm.o: In function `main': > cfgtest_QtWebKit.cpp:(.text.startup+0x19): undefined reference to > `QWebPage::QWebPage(QObject*)' > collect2: error: ld returned 1 exit status Hmm, have you checked the symbols in your libQt5WebKit.so? objdump -T libQt5WebKit.so | grep QWebPage | grep QObject It should show: _ZN8QWebPageC2EP7QObject Feeding to c++filt results in: QWebPage::QWebPage(QObject*) Any other result is an issue down under.. Cheers, Pete ___ PyQt mailing listPyQt@riverbankcomputing.com http://www.riverbankcomputing.com/mailman/listinfo/pyqt
Re: [PyQt] PyQt4 issue
I am also having this issue on ubuntu 12.10 and Max OSX 10.8.2 I tried configuring against a compiled Qt5 and the downloaded Qt5 binary. In both cases I get the same output from python configure.py -w -e QtWebKit Checking to see if the QtWebKit module should be built... g++ -DQT_NO_DEBUG -DQT_WEBKIT_LIB -DQT_CORE_LIB -I. -I/opt/Qt5.0.1/5.0.1/gcc_64/mkspecs/linux-g++ -I/opt/Qt5.0.1/5.0.1/gcc_64/include/QtWebKit -I/opt/Qt5.0.1/5.0.1/gcc_64/include/QtWebKitWidgets -I/opt/Qt5.0.1/5.0.1/gcc_64/include/QtCore -I/opt/Qt5.0.1/5.0.1/gcc_64/include -m64 -pipe -O2 -w -D_REENTRANT -fPIE cfgtest_QtWebKit.cpp -o cfgtest_QtWebKit -L/opt/Qt5.0.1/5.0.1/gcc_64/lib -Wl,-O1 -Wl,-rpath,/opt/Qt5.0.1/5.0.1/gcc_64/lib -lQt5WebKit -L/usr/X11R6/lib64 -lQt5Core -lpthread /tmp/cc8ToxK3.o: In function `main': cfgtest_QtWebKit.cpp:(.text.startup+0x19): undefined reference to `QWebPage::QWebPage(QObject*)' collect2: error: ld returned 1 exit status ___ PyQt mailing listPyQt@riverbankcomputing.com http://www.riverbankcomputing.com/mailman/listinfo/pyqt
Re: [PyQt] PyQt4 issue
Hello, here is the extract. Checking to see if the QtTest module should be built... g++ -DQT_NO_DEBUG -DQT_TEST_LIB -DQT_GUI_LIB -DQT_WIDGETS_LIB -I. - I/usr/local/Qt-5.0.1/mkspecs/linux-g++ -I/usr/local/Qt-5.0.1/include/QtTest - I/usr/local/Qt-5.0.1/include -m64 -pipe -O2 -w -D_REENTRANT -fPIE cfgtest_QtTest.cpp -o cfgtest_QtTest -L/usr/local/Qt-5.0.1/lib -Wl,-O1 -Wl,-rpath,/usr/local/Qt-5.0.1/lib -lQt5Test - L/usr/local/Qt-5.0.1/lib -lQt5Core -lpthread -lpthread Checking to see if the QtWebKit module should be built... g++ -DQT_NO_DEBUG -DQT_WEBKIT_LIB -DQT_CORE_LIB -I. - I/usr/local/Qt-5.0.1/mkspecs/linux-g++ -I/usr/local/Qt-5.0.1/include/QtWebKit - I/usr/local/Qt-5.0.1/include/QtWebKitWidgets -I/usr/local/Qt-5.0.1/include/QtCore - I/usr/local/Qt-5.0.1/include -m64 -pipe -O2 -w -D_REENTRANT -fPIE cfgtest_QtWebKit.cpp - o cfgtest_QtWebKit -L/usr/local/Qt-5.0.1/lib -Wl,-O1 -Wl,-rpath,/usr/local/Qt-5.0.1/lib - lQt5WebKit -L/usr/X11R6/lib64 -L/usr/local/Qt-5.0.1/lib -lQt5Network -L/usr/local/Qt-5.0.1/lib - lQt5Core -lpthread -lpthread -lQt5Gui -L/usr/X11R6/lib64 -L/usr/local/Qt-5.0.1/lib -lQt5Core - lpthread -lpthread -lQt5Core -lpthread -lpthread -lQt5Core -lpthread -lpthread /tmp/ccmtGOAm.o: In function `main': cfgtest_QtWebKit.cpp:(.text.startup+0x19): undefined reference to `QWebPage::QWebPage(QObject*)' collect2: error: ld returned 1 exit status Regards, Detlev On Monday 04 March 2013, 18:52:45 Phil Thompson wrote: > On Mon, 4 Mar 2013 19:50:41 +0100, Detlev Offenbach > > wrote: > > Hi Phil, > > > > I found the cause of my issue. Actually there are two. > > > > 1. configure.py doesn't detect, that the wrapper for QtWebkit should be > > built. > > 2. That left an old wrapper for QtWebkit in my installation directory, > > which caused the issue (a mix of compilations doesn't work). > > > > So I think, fixing 1. will get rid of 2 automatically. > > > > All this was done with Qt 5.0.1 on Linux (openSUSE 12.2) and Mac OS X > > Mountain Lion. > > Can you run configure.py with --verbose so that you can see why it doesn't > think QtWebKit is available? > > Phil-- *Detlev Offenbach* det...@die-offenbachs.de ___ PyQt mailing listPyQt@riverbankcomputing.com http://www.riverbankcomputing.com/mailman/listinfo/pyqt
Re: [PyQt] PyQt4 issue
On Sun, 03 Mar 2013 19:15:40 +0100, Detlev Offenbach wrote: > Hello, > > I am observing a strange issue with latest PyQt4 and Qt 5.0.1. The later > was compiled by > myself. Setting the URL of a QWebView with QWebView.setUrl() results in a > seg fault or > other errors. Executing these steps in a Python3 shell result in a strange > error. > from PyQt4.QtCore import QUrl from PyQt4.QtGui import QApplication from PyQt4.QtWebKit import QWebView import sys app=QApplication(sys.argv) > Qt at-spi: error getting the accessibility dbus address: "The name > org.a11y.Bus was not > provided by any .service files" > Accessibility DBus not found. Falling back to session bus. v=QWebView() v.setUrl(QUrl("about:blank")) > Traceback (most recent call last): > File "", line 1, in > TypeError: QWebView.setUrl(QUrl): argument 1 has unexpected type 'QUrl' > > However, according to the Qt5 docs, this method has QUrl as the first > parameter. It worked > before upgrading PyQt4 and it works with Qt4. Works fine for me. Phil ___ PyQt mailing listPyQt@riverbankcomputing.com http://www.riverbankcomputing.com/mailman/listinfo/pyqt
[PyQt] PyQt4 issue
Hello, I am observing a strange issue with latest PyQt4 and Qt 5.0.1. The later was compiled by myself. Setting the URL of a QWebView with QWebView.setUrl() results in a seg fault or other errors. Executing these steps in a Python3 shell result in a strange error. >>> from PyQt4.QtCore import QUrl >>> from PyQt4.QtGui import QApplication >>> from PyQt4.QtWebKit import QWebView >>> import sys >>> app=QApplication(sys.argv) Qt at-spi: error getting the accessibility dbus address: "The name org.a11y.Bus was not provided by any .service files" Accessibility DBus not found. Falling back to session bus. >>> v=QWebView() >>> v.setUrl(QUrl("about:blank")) Traceback (most recent call last): File "", line 1, in TypeError: QWebView.setUrl(QUrl): argument 1 has unexpected type 'QUrl' However, according to the Qt5 docs, this method has QUrl as the first parameter. It worked before upgrading PyQt4 and it works with Qt4. Regards, Detlev-- *Detlev Offenbach* det...@die-offenbachs.de ___ PyQt mailing listPyQt@riverbankcomputing.com http://www.riverbankcomputing.com/mailman/listinfo/pyqt