[Distutils] RE: [Python-Dev] PEP 250 - site-packages on Windows: (Was: [Distutils] Package DB: strawman PEP)

M.-A. Lemburg mal@lemburg.com
Thu, 12 Jul 2001 18:43:36 +0200

Thomas Heller wrote:
> [I've cut down the To: and CC: headers to olny include python-dev
> and distutils]
> > Well, site.py could be modified to set a symbol in the sys module
> > which could then be queried by distutils, e.g. sys.extinstallprefix.
> >
> > Alternatively, distutils could be made to default to
> > Lib\site-packages and then revert to Lib\ in case this directory
> > is not available.
> >
> > BTW, I don't think that using Windows registry keys for determining the
> > installation path is a good idea -- this information should be kept
> > in the site.py or sitecustomize.py module for easy editing.
> The problem is that the 'installation path' information must be
> loaded at run time by the windows installer, and it may not always
> sucessful to embed python at run time and let python code retrieve it.
> Remember the problems we had with Python2.0 on win95/98, when win32all
> was not installed? The installer was not able to compile the installed
> files to pyc/pyo because of this path bug.

Ok. Point taken (this time ;-).
> Anyway, how does bdist-rpm does it? Should be the same problem
> there...

bdist_rpm runs the Python interpreter to figure out the install
dirs, etc. at rpm build time. The paths are then hard-coded into
the rpm file.

Marc-Andre Lemburg
CEO eGenix.com Software GmbH
Consulting & Company:                           http://www.egenix.com/
Python Software:                        http://www.lemburg.com/python/