python 2.7, import wx says "wrong architecture"
Dave Curtis
dave at dave-curtis.com
Wed Mar 21 23:58:59 PDT 2012
At this point I'm pretty sure everything is built correctly, but suspect that there is a configuration problem some where.
When I try 'import wx' in Idle, I get a "wrong architecture' complaint loading wx-2.8-mac-unicode/wx/_core_.so. The so is built only for i386 -- I thought that was the point of all this ordeal of building universal binaries, that wx is 32 bit only. So it looks like a 32 bit lib.so, but now Python is unhappy with it.
So... is there still a build issue? A config issue? Do I need to start Python some special way? other?
-dave
Python's complaint:
Python 2.7.2 (default, Mar 21 2012, 22:10:23)
[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin
Type "copyright", "credits" or "license()" for more information.
>>> import wx
Traceback (most recent call last):
File "<pyshell#0>", line 1, in <module>
import wx
File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/wx-2.8-mac-unicode/wx/__init__.py", line 45, in <module>
from wx._core import *
File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/wx-2.8-mac-unicode/wx/_core.py", line 4, in <module>
import _core_
ImportError: dlopen(/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/wx-2.8-mac-unicode/wx/_core_.so, 2): no suitable image found. Did find:
/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/wx-2.8-mac-unicode/wx/_core_.so: mach-o, but wrong architecture
>>>
And some file information:
david-curtiss-macbook:wxtab dave$ port provides /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/wx-2.8-mac-unicode/wx/_core_.so
/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/wx-2.8-mac-unicode/wx/_core_.so is provided by: py27-wxpython
david-curtiss-macbook:wxtab dave$ file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/wx-2.8-mac-unicode/wx/_core_.so
/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/wx-2.8-mac-unicode/wx/_core_.so: Mach-O bundle i386
More information about the macports-users
mailing list