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

Thomas Heller thomas.heller@ion-tof.com
Fri Jul 13 04:28:05 2001

From: "Tim Peters" <tim@digicool.com>
> [Thomas Heller]
> > The bdist_wininst installer simply installs into prefix,
> > this is what the registry has under
> > HKEY_LOCAL_MACHINE\Software\Python\PythonCore\2.1\InstallPath.
> >
> > Now what should it do?
> [Moore, Paul]
> > What does that key *mean*?
> Mark Hammond documented it as being the directory into which Python is
> installed; python.exe lives here.
> > If it is the directory into which packages should get installed,
> No; it's much older than the package mechanism <0.1 wink>.
Per _accident_ it is also the location (pre PEP250 time),
where packages should get installed.

> > In that case, my recommendation would be to have the Python 2.2
> > installer create a new key and wininst use that if it exists,
> > ...
> If you have to use the registry, why not paste Lib/site-packages on to the
> end of InstallPath and use that?
The problem is that the same wininst executable should behave differently
depending on the policy Python has chosen for the installation directory:
Python 2.1 and before: Use prefix, Python 2.2 (and higher) should use
That's why I said a (very hacky) solution would be to simply check 
for the version number at install time.
A better solution would be to somehow query site.py at install time?