Re: [pyxpcom] pyxpcom on mac, anyone?
by Brendan O'Connor other posts by this author
Aug 17 2005 6:05PM messages near this date
view in the new Beta List Site
Re: [pyxpcom] pyxpcom on mac, anyone?
|
Re: [pyxpcom] pyxpcom on mac, anyone?
Shane, the patch works great -- I can build pyxpcom under seamonkey
against OS X 10.4's builtin python installation, and everything seems
to work.
I'm trying to build it against my own custom python, but I at runtime
I get the error
The Python XPCOM loader is adding
'/Users/osaf/mozilla/od-ch3/dist/SeaMonkeyDebug.app/Contents/MacOS/python'
to sys.path
Could not import the Python XPCOM extension
exceptions.ImportError: Inappropriate file type for dynamic loading
Specifically, it looks like pyxpcom can't open _xpcom.so, which is a
symlink to lib_xpcom.dylib :
> >> from xpcom import components
Traceback (most recent call last):
File "<stdin> ", line 1, in ?
File "/Users/osaf/mozilla/od-ch3/dist/SeaMonkeyDebug.app/Contents/MacOS/python/xpcom/compo
nents.py",
line 39, in ?
import xpt
File "/Users/osaf/mozilla/od-ch3/dist/SeaMonkeyDebug.app/Contents/MacOS/python/xpcom/xpt.p
y",
line 72, in ?
import xpcom._xpcom
ImportError: Inappropriate file type for dynamic loading
[25868 refs]
I think it found the python shared libraries alright. For the OS X
native python build, which works fine, I had to edit autoconf.mk to
use
PYTHON_LIBS = -L/usr/lib -lpython2.3
for my local python, configure didn't quite find all the library paths, so I did
PYTHON_INCLUDES =
-I/Users/osaf/chandler-trunk/chandler/debug/Library/Frameworks/Python.framework/Versions/2.4
/include/python2.4
PYTHON_LIBS = -F/Users/osaf/chandler-trunk/chandler/debug/Library/Frameworks
-framework Python
and, .../Frameworks/Python.framework/Python is the python shared
library, which, if I understand the OS X ld correctly, gets linked in
via -F and -framework instead of -L and -l.
If anyone has any ideas, I'm all ears. Thanks!
Brendan
On 8/17/05, Shane Caraveo <shanec@[...].com> wrote:
> yes, we're using it in Komodo, which we just released the alpha. We're
> building on firefox/toolkit at this time, but started out against the
> 1.7.x xpfe code. It works fine. You can find our build patches at
> https://bugzilla.mozilla.org/show_bug.cgi?id=129216
>
> Shane
>
> Brendan O'Connor wrote:
> > After much too long playing with linux builds (it works with fc4
> > python, doesn't work with my custom python), I'm trying to run pyxpcom
> > on mac. Has anyone had success? And with what products? (seamonkey
> > vs firefox vs xulrunner all seem to have subtle variations...)
> >
> > _______________________________________________
> > pyxpcom mailing list
> > pyxpcom@[...].com
> > To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
>
_______________________________________________
pyxpcom mailing list
pyxpcom@[...].com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Thread:
Brendan O'Connor
Shane Caraveo
Brendan O'Connor
Shane Caraveo
Trent Mick
Brendan O'Connor
Trent Mick
Brendan O'Connor
Brendan O'Connor
|