Hi !
I've a "20 minutes wiki" and a few other turbogear apps running from an py2exe
(exe+library.zip) executable
What I did:
*) Added all eggs manually into the library.zip file (as subdirectories) and
remove the files which are located within the eggs and py2exe added by itself
*) modified the start-....py script something like:
#!/usr/bin/env python
import pkg_resources
import os
import sys
print os.path.abspath(sys.argv[0])
sys.path.insert(0,os.path.join(os.path.dirname(os.path.abspath(sys.argv[0])),"library.zip\PyProtocols-1.0a0dev_r2082-py2.4-win32.egg"))
... more egg directories ...
#pkg_resources.require("TurboGears") works without the require line
... the usual start-... code
*) Apply the attached patch to pkg_resources
If you would like to put static data and kid templates into the library.zip
file, you have patch kid and cherrypy a littlebit (at least I had to do it).
If you are interested in those I could post patches (against 0.9a4, but from
what I see they are still needed).
Kind regards
Joseph Wenninger
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/turbogears
-~----------~----~----~----~------~----~------~--~---
--- /home/jowenn/vpython/lib/python2.4/site-packages/setuptools-0.6a11-py2.4.egg/pkg_resources.py 2006-05-16 13:01:47.000000000 +0200
+++ pkg_resources.py 2006-05-25 10:36:56.000000000 +0200
@@ -1249,7 +1249,8 @@
real_path = manager.get_cache_path(
self.egg_name, self._parts(zip_path)
)
-
+ if os.path.isdir(real_path):
+ return real_path;
if os.path.isfile(real_path):
stat = os.stat(real_path)
if stat.st_size==size and stat.st_mtime==timestamp: