[wxPython-dev] Eggs for Christmas

Robin Dunn robin at alldunn.com
Mon Jan 21 11:00:59 PST 2008


Hi all,

Has anybody experimented much with these eggs yet?  Any comments, 
problems or questions?  Better ideas?

I submitted a patch to PJE that fixes the problem with the stub loader 
exe on Windows, and he has checked it in to SVN so that will be in the 
next version of setuptools.  We also discussed how to safely allow a 
post-install script of some sort, but he hasn't made a decision on that yet.

Robin


Robin Dunn wrote:
> Hi all,
> 
> A while back 
> (http://lists.wxwidgets.org/cgi-bin/ezmlm-cgi?12:mss:3637:200711:dambhhlnhfalnegfpkdm) 
> we discussed reorganizing the wxPython packages for Mac and Windows such 
> that there is a runtime-only package, and a package with the runtime and 
> everything else that a developer would want to have (the docs, demos and 
> such.)  While I was letting that idea stew a bit I realized that Python 
> Eggs would be an ideal way to provide the runtime portion of this idea, 
> and over the last couple weeks I have been learning about eggs and 
> playing with tweaks to setup.py to make a wxPython egg.  You can see the 
> results at http://alldunn.com/wxPython/stuff/.  To use it just download 
> the egg and then install it with easy_install.
> 
> There are still a few known problems which I'll describe below, but 
> first, a few choices I made going into the task:
> 
> * Only the wx package will be included, not the wxPython package.
> 
> * The wxversion module will not work with the egg, but you can use the 
> pkg_resources module to do the same thing if you have more than one 
> version of the wxPython egg installed.
> 
> * One of the main ideas behind using an egg is that it is self 
> contained.  To me that means the the wxWidgets shared libraries should 
> be included too.  On Windows that is easy and I include the DLLs the 
> same way that they are now, in the same dir as the wxPython .pyd files. 
>  On Mac I've copied the wx .dylibs into the egg in a Library dir, and 
> I've modified the extension modules to be able to find those libraries 
> using a @loader_path/../Library path name.  This lets the egg be located 
> anywhere and still be able to find its own wx shared libs.  For Mac this 
> is especially helpful because it allows the egg to be used with either 
> the system python or a user installed MacPython.  You can also install 
> the egg into your $HOME/Library/Python/2.5/site-packages directory and 
> use the one egg from both Pythons.
> 
> 
> 
> Known Problems:
> 
> * The message catalog files are not included yet.  Not a big deal, I 
> just haven't done it yet.
> 
> * On Windows being self-contained means that a few things we usually 
> install outside of the package dir are missing, mainly the .manifest 
> files for python.exe and pythonw.exe.  If easy_install supported some 
> sort of post-install script then I could easily take care of it there, 
> but it doesn't look like it does. :-(  Does anybody have any ideas about 
> how to work around this?
> 
> * On Windows easy_install creates a stub .exe loader for the "entry 
> points" it installs to the Scripts dir.  Those that I've marked as gui 
> scripts (pycrust, xrced, etc.) are not working for some reason.  They 
> just exit without launching the application.  I think it's a bug in the 
> launcher exe provided by setuptools, but I haven't dug into it yet. 
> Since these launchers are created during the install phase it will 
> likely take a new version of setuptools to be able to fix it.
> 
> Anyway, please give these eggs a try and let me know how it goes.  If 
> you have ideas to help with the above problems, or if you have any other 
> suggestions please speak up.
> 
> Merry Christmas!
> 


-- 
Robin Dunn
Software Craftsman
http://wxPython.org  Java give you jitters?  Relax with wxPython!




More information about the wxpython-dev mailing list