★ wanayoo — archive 1999 http://mail.python.org/pipermail/pythonmac-sig/2002-February/005156.htmlNouvelle recherche | Portail wanayoo

[Pythonmac-SIG] Building VPython on MacOSX..

Steve Spicklemire steve@spvi.com
Fri, 15 Feb 2002 06:51:20 -0500


Hi Folks,

I'm trying to build VPython from CVS (www.vpython.org, cvs at sf.net) 
using "machopython". I'm guessing the easiest way to do this is to use 
the fink port and XFree86 etc, gtk+, gtkglarea, and so on. I tried 
this.... and have actually created a 'cvisualmodule.so' on MacOSX 10.1. 
However when I try to "import cvisual", I get:

[vh10-15:~/Development/cvisual] steve% python -c "import cvisual"
Traceback (most recent call last):
   File "<string>", line 1, in ?
ImportError: Failure linking new module


Checking the source in Python/dynload_next.c it looks like the problem 
is happening here:

                if (errString == NULL) {
                         newModule = NSLinkModule(image, pathname,
                                 
NSLINKMODULE_OPTION_BINDNOW|NSLINKMODULE_OPTION_RETURN_ON_ERROR);
                         if (!newModule)
                                 errString = "Failure linking new module";
                 }

so NSLinkModule is returning NULL. Any thoughts on how to debug this? 
Can otool generate any clues about what's wrong with the shared lib? I 
can't run gdb on the module since it never loads! I have also seen 
rumblings about the new dynload_darwin.c. I don't think that my problem 
is related to that... but I would love to hear opinions.

thanks for any help!

take care,
-steve