Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #4810
| References | <mailman.1202.1304627647.9059.python-list@python.org> <4bccd7ab-4bff-4b7c-a289-5c25ff259257@glegroupsg2000goo.googlegroups.com> |
|---|---|
| Date | 2011-05-06 12:10 +0200 |
| Subject | Re: Embedding Python's library as zip file |
| From | Wojtek Mamrak <tacyt1007@gmail.com> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.1233.1304676643.9059.python-list@python.org> (permalink) |
> Are you calling Py_SetProgramName? That may help to set sys.prefix > and sys.exec_prefix. However, looking at site.py, it appears that > it's only looking for proper directories. I don't think it will be > able to add a site-packages inside a zip archive at all; you will just > have to add that yourself. Yes, I have tried Py_SetProgramName, but I am even not sure what argument (name, path?) should be passed to it and how it will affect the application. Some good news. After simplifying my application I realized, that importing of modules from the zip archive works well, I only have to add site-packages to sys.path (it looks like "python27.zip/site-packages"). Unfortunately even though I can import Image package, something still causes applications' sudden death. I will try to figure out what is the reason of that. As I said, the only non-standard package I am using is PIL.
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar
Re: Embedding Python's library as zip file Miki Tebeka <miki.tebeka@gmail.com> - 2011-05-05 20:20 -0700 Re: Embedding Python's library as zip file Wojtek Mamrak <tacyt1007@gmail.com> - 2011-05-06 12:10 +0200 Re: Embedding Python's library as zip file Wojtek Mamrak <tacyt1007@gmail.com> - 2011-05-06 15:23 +0200
csiph-web