[Pythonmac-SIG] py2app dynamically loading .so plugins

Bill Hart bill.hart at utas.edu.au
Sun Apr 8 11:40:54 CEST 2007


I'm trying to build a py2app application which uses the C++  
openscenegraph libraries with some swig based wrappers.   
Openscenegraph has a module osgDB, which dynamically loads a bunch of  
plugins (.so) files for reading and writing different types of files.

I have a simple test application which loads a data file cow.osg and  
displays it in a viewer.  I run

py2applet --make-setup osgtest.py cow.osg -frameworks osgdb_osg.so

everything seems to work fine all the appropriate modules seem to be  
loaded and I can definitely see the osgdb_osg.so file in the  
Frameworks folder in the dist file.

When I run the application the viewer starts up, but no cow appears.   
The console shows

Warning: Could not find plugin to read objects from file "cow.osg".

In case I got the wrong plugin, I've manually copied in all of the  
plugin .so files into the Frameworks folder of the app, but still get  
the same message in the console.  It appears that the c++ library  
libosgDB.dylib isn't finding the .so files.

Any ideas appreciated

-Bill Hart

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/pythonmac-sig/attachments/20070408/635bf0ad/attachment.htm 

More information about the Pythonmac-SIG mailing list