Differences between revisions 1 and 10 (spanning 9 versions)
Revision 1 as of 2004-12-16 09:44:48
Size: 1118
Editor: www
Comment:
Revision 10 as of 2015-03-30 15:56:32
Size: 353
Editor: Laurence67
Comment:
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
= Overview =

'''zipextimporter.py''' contains the ZipExtImporter class which allows to
load Python binary extension modules contained in a zip.archive,
without unpacking them to the file system.

Call the '''zipextimporter.install()''' function to install the import hook,
add a zip-file containing .pyd or .dll extension modules to sys.path,
and import them.

It contains a '''_memimporter.pyd''' extension which uses code from Joachim
Bauch's [http://www.joachim-bauch.de/tutorials/load_dll_memory.html MemoryModule] library. This library emulates the win32 api
function LoadLibrary.

= License =
LGPL (because that's what MemoryModule uses).

= Sample usage =

{{{
>>> import zipextimporter
>>> zipextimporter.install()
>>> import sys
>>> sys.path.append("lib.zip")
>>> import _socket
>>> _socket.__file__
'c:\\sf\\py2exe\\hacks\\memimp\\lib.zip\\_socket.pyd'
>>> _socket.__loader__
<ZipExtensionImporter at a74480>
>>>
}}}

= Bugs =

'''reload()''' on already imported extension modules does not work
correctly: It happily loads the extension a second time.

= Download =
My name is Laurence from Merty Merty doing my final year engineering in Anthropology and Sociology. I did my schooling, secured 94% and hope to find someone with same interests in Shooting sport.<<BR>><<BR>>
<<BR>><<BR>>
My weblog ... internet speed test telia, [[http://mobiltower.com/?option=com_k2&view=itemlist&task=user&id=1876|relevant site]],

My name is Laurence from Merty Merty doing my final year engineering in Anthropology and Sociology. I did my schooling, secured 94% and hope to find someone with same interests in Shooting sport.



My weblog ... internet speed test telia, relevant site,

Hacks/ZipExtImporter (last edited 2015-03-30 19:50:22 by JimmyRetzlaff)