[Python-Dev] Re: [Distutils] Questions about distutils strategy
James C. Ahlstrom
jim@interet.com
Mon, 13 Dec 1999 09:50:11 -0500
> Jean-Claude Wippler wrote:
>
> > Ouch - what's wrong with zip archives?
>
> > With all due respect - I sincerely hope you will reconsider and alter
> > your code to work with zip files. It's probably a small adjustment?
OK, I now have a new module "zipfile" which reads and
writes ZIP files. It is written in Python and has been tested
on Windows and Linux. I tested it with WinZip and found that
the files it creates are read OK with WinZip, and WinZip
files are read OK with zipfile. So I am withdrawing my
Python archive file format, and re-writing all my stuff
using zipfile. It should all be done in a week.
Basically everything works fine. But there are some problems.
Python seems to lack a CRC-32 function, so I wrote one
in Python. It is slow. We need to add a CRC-32 function
to some Python built-in module that it always present, like
md5 or binascci. The zlib module is not necessarily present.
I can't seem to get WinZip to record a partial path. That is,
I want the ./Lib/test package to have these ZIP paths:
test/__init__.pyc
test/testall.pyc
...
but WinZip creates files with either no path at all or the
fully specified path. Am I missing something? Do all
other ZIP tools do this too?
JimA
Return-Path: <owner-python-dev@python.org>
Delivered-To: python-dev@dinsdale.python.org
Received: from python.org (parrot.python.org [132.151.1.90])
by dinsdale.python.org (Postfix) with ESMTP id EFDA11CDB9
for <python-dev@dinsdale.python.org>; Mon, 13 Dec 1999 10:21:56 -0500 (EST)
Received: from cnri.reston.va.us (ns.CNRI.Reston.VA.US [132.151.1.1] (may be forged))
by python.org (8.9.1a/8.9.1) with ESMTP id KAA06423
for <python-dev@python.org>; Mon, 13 Dec 1999 10:21:55 -0500 (EST)
Received: from kaluha.cnri.reston.va.us (kaluha.cnri.reston.va.us [132.151.7.31])
by cnri.reston.va.us (8.9.1a/8.9.1) with ESMTP id KAA04774
for <python-dev@python.org>; Mon, 13 Dec 1999 10:21:56 -0500 (EST)
Received: from eric.cnri.reston.va.us (eric.cnri.reston.va.us [10.27.10.23])
by kaluha.cnri.reston.va.us (8.9.1b+Sun/8.9.1) with ESMTP id KAA04556
for <python-dev@python.org>; Mon, 13 Dec 1999 10:22:34 -0500 (EST)
Received: from CNRI.Reston.VA.US (localhost [127.0.0.1])
by eric.cnri.reston.va.us (8.9.3+Sun/8.9.1) with ESMTP id KAA18858
for <python-dev@python.org>; Mon, 13 Dec 1999 10:22:34 -0500 (EST)
Resent-Message-Id: <199912131522.KAA18858@eric.cnri.reston.va.us>
Message-Id: <199912131522.KAA18858@eric.cnri.reston.va.us>
To: "James C. Ahlstrom" <jim@interet.com>
Subject: Re: [Python-Dev] Re: [Distutils] Questions about distutils strategy
In-reply-to: Your message of "Mon, 13 Dec 1999 09:50:11 EST."
<385507A3.9F6AAF0F@interet.com>
References: <000301bf4206$b39e5b80$36a2143f@tim> <384FC47A.BB4DA517@interet.com> <384FDAF5.C25C447C@equi4.com> <38510254.ED15D32B@interet.com>
<385507A3.9F6AAF0F@interet.com>
Date: Mon, 13 Dec 1999 10:22:12 -0500
From: Guido van Rossum <guido@CNRI.Reston.VA.US>
Resent-Cc: python-dev@python.org
Resent-Date: Mon, 13 Dec 1999 10:22:34 -0500
Resent-From: Guido van Rossum <guido@CNRI.Reston.VA.US>
Sender: python-dev-admin@python.org
Errors-To: python-dev-admin@python.org
X-BeenThere: python-dev@python.org
X-Mailman-Version: 1.2 (experimental)
Precedence: bulk
List-Id: Python core developers <python-dev.python.org>
> OK, I now have a new module "zipfile" which reads and
> writes ZIP files. It is written in Python and has been tested
> on Windows and Linux. I tested it with WinZip and found that
> the files it creates are read OK with WinZip, and WinZip
> files are read OK with zipfile. So I am withdrawing my
> Python archive file format, and re-writing all my stuff
> using zipfile. It should all be done in a week.
Ah, good! (This saves me the trouble of cleaning up our own zip code :-)
> Basically everything works fine. But there are some problems.
>
> Python seems to lack a CRC-32 function, so I wrote one
> in Python. It is slow. We need to add a CRC-32 function
> to some Python built-in module that it always present, like
> md5 or binascci. The zlib module is not necessarily present.
>
> I can't seem to get WinZip to record a partial path. That is,
> I want the ./Lib/test package to have these ZIP paths:
> test/__init__.pyc
> test/testall.pyc
> ...
> but WinZip creates files with either no path at all or the
> fully specified path. Am I missing something? Do all
> other ZIP tools do this too?
Unclick the "Save Extra Folder Info" and then drag the *parent* folder
into the archive.
--Guido van Rossum (home page: http://www.python.org/~guido/)