Phillip J. Eby wrote:
At 05:16 PM 10/4/2005 -0700, Bob Ippolito wrote:
On the other hand, setuptools/eggs solves a lot of these problems (given appropriate metadata), so I'd target integration with that first and then bring in the "legacy" support that py2app does pretty well. Requiring appropriate metadata from the packages themselves has a much brighter future than maintaining an external "quirks" infrastructure in (each) application packager.
I agree with Bob here. I know that in the past I've wanted to add metadata to packages I distribute to make them work better with py2exe (e.g. automatically including DLLs accessed through ctypes), so I think this is the right approach.
Also, setuptools supports adding setup() keywords and commands in a
extensible way than subclassing Distribution, so there's no need to maintain a bunch of code to hook into the distutils if you just plug
with setuptools. See:
At this point, the easy_install command is capable of dumping all the needed eggs and any generated wrapper scripts into a target directory. What it doesn't have is:
- frontend wrappers/packaging to actually build the .exe or app and
- module-finding or stdlib packaging to locate and bundle the needed
portion of the standard library
It would be cool if these things could be integrated in such a way
single setup() could be used to create both an OS X application and a Windows .exe. As it happens, setuptools supports specifying
eggs needed to run a particular setup command, so we can actually
the requirement of the egg containing py2exe or py2app until somebody
requests the command.
That would be awesome. There might be a few platform specific bits that need to be specified, but it would be nice to let the executable packagers focus on the job of creating a platform specific executable.
On the other hand, it's also possible that the metadata could be
into the egg metadata directory, which would then make it possible to
external bundling tools that just use the eggs to build the
without needing to run the setup script at all.
One of my thoughts for py2exe has been a small GUI tool that helps people new to distutils/py2exe to create (and maybe maintain) a setup script graphically. A lot of people who just want to bundle one small utility seem to get confused about options on the command line vs. in parameters and that type of thing. With what you are describing, this could degenerate into just a builder tool, and any GUI could be applied further upstream where more of the metadata lives. If enough of the metadata lives in the individual packages, then the options needed for the executable builder part might be simple enough that the confusion goes away.
Alas I won't have time for much of this for a while. I expect I'll have my hands full getting up to speed on py2exe's internals and providing support until I get a break from my current deadlines at work (which is looking like December). When I get to that point, I'll try to reopen the discussion.