Opened 15 years ago

Closed 15 years ago

Last modified 15 years ago

#18452 closed defect (worksforme)

PyQt4 makes Python 2.5 crash with "Bus Error" when importing QtWebKit module

Reported by: henrique@… Owned by: saispo@…
Priority: Normal Milestone:
Component: ports Version: 1.7.0
Keywords: qt4 Cc: mf2k (Frank Schima)
Port: py25-pyqt4

Description

This error happens only with the QtWebKit module.

To reproduce, install the ports py25-sip @4.7.6 and py25-pyqt4 @4.4.3 Then run python interpreter and:

from PyQt4 import QtWebKit

It should crash with a "Bus Error" message.

Change History (6)

comment:1 Changed 15 years ago by henrique@…

This error stops after update py25-sip to 4.7.9 and py25-pyqt4 to 4.4.4

The patches were already submitted for py25-sip @4.7.9 (#18424) and for py25-pyqt4 @4.4.4 (#18423)

Download the patches and apply then to your ports:

patch /opt/local/var/macports/sources/rsync.macports.org/release/ports/python/py25-sip/Portfile Port-py25-sip.diff

patch /opt/local/var/macports/sources/rsync.macports.org/release/ports/python/py25-pyqt4/Portfile Port-py25-pyqt4.diff

comment:2 Changed 15 years ago by mf2k (Frank Schima)

Keywords: qt4 added
Owner: changed from macports-tickets@… to saispo@…
Port: py25-pyqt4 added

comment:3 Changed 15 years ago by mf2k (Frank Schima)

Cc: macsforever2000@… added

Cc Me!

comment:4 Changed 15 years ago by jonas@…

I experienced the same crash with every PyQt4 module, no matter if QtWebKit, QtGui, ... This is caused if you forget to switch to python2.5 before building sip and pyqt4. They build against mac os x' native python.

So the solution:

sudo port install python_select
sudo python_select python25

and then rebuild (watch out that you don't simply reinstall the old version) py25-sip and py25-pyqt4. This time python is /opt/local/bin/python, which points to python2.5.

The py25-pyqt4 port should test "from PyQt4 import QtGui" and not just "import PyQt4" as this file is just empty.

(I also updated openssl and py25-hashlib in the mean time, as suggested by this blog but in my eyes the problem is that some thing in the chain compiled against /usr/bin/python)

comment:5 Changed 15 years ago by mf2k (Frank Schima)

Resolution: worksforme
Status: newclosed

comment:6 Changed 15 years ago by (none)

Milestone: Port Bugs

Milestone Port Bugs deleted

Note: See TracTickets for help on using tickets.