This is a partial revert of 6afc718307
to restore the ability to overwrite distutils installed packages.
It is not elegant, but some projects (such as OpenStack's devstack)
rely on overwriting packages installed via the system package manager.
These packages can't be removed because they are dependencies for
parts of the base system, but many of the things devstack needs to run
requires later dependencies. For historical reasons it's not easy to
fix this into a virtualenv, etc, all at once.
If distributions move to setuptools based packages, this problem might
fix itself.
In the case of develop install where we have an egg-info directory and
an egg-link, make sure we uninstall it in the develop_egg_link if case.
Fix#2456
* Move virtualenv creation out of TestPipEnvironment
* Remove global state and force explicit use of TestPipEnvironment
instances
* Remove "backup" virtualenv copying and instead create new
virtual environments each time.
* Remove the monkeypatched "PyPICache" functionality
* Remove things that were not being used anymore and were dead
weight
* Remove sitecustomize support which was primarily used to
monkeypatch the "PyPICache" but was used in one or two other
tests.