Re: [Pyobjc-dev] Using py2app and distributing a self-contained plug-in which depends on other pytho
Brought to you by:
ronaldoussoren
From: Bob I. <bo...@re...> - 2005-04-24 05:14:48
|
On Apr 23, 2005, at 11:49 PM, Eric Hochmeister wrote: > I've written a python pyObjC based plug-in which I would like to > include in a Cocoa application. This plugin depends on another python > based library which I would like to include in the final deliverable > application (in the app wrapper). I currently was working using the > 'python setup.py py2app -A' as seen in the tutorial on the web. This > was great for development and everything was fine. The issue now is > that I want to create a finished product and I haven't figured out how > to do this. Just remove the -A, and it will include everything it needs. > My objective is to not require the user to install the library the > plugin depends on themselves. I would like to include this library in > the app wrapper. I have read some material (tried reading everything > I could on using py2app) but I have no found a concrete example and > was hoping someone could help me out. Well, maybe you're looking too hard. Every example is a concrete example of this. > Do I just have to do a 'python setup.py py2app' and remove the -A > parameter and that's it? From what I've read, py2app will discover > the dependencies and include them within the plug-in component. It > stores the dependencies in a site-packages.zip file?? Will it unzip > this package at run-time and use the dependency??? Python has a native zipimporter that allows it to load Python source or bytecode directly from zip files. > How does this work? Read the source? > Can anyone give me an explanation or direct me to materials which will > help me achieve this goal? I just want the library to exist within > the app wrapper so that the application can be moved anywhere on the > Mac system and be usable. Some further explanation is in the documentation here: http://undefined.org/python/py2app.html -bob |