In a perfect world, I'd like to use pip inside a --no-site-packages
virtualenv.
However: OpenCV. From what I've read so far it sounds tricky to reliably install OpenCV in a virtualenv, so I've accepted having to install that as a system package for now (target platform is Ubuntu, so I'm installing python-opencv
with apt). I'd like to install everything else with pip into my virtualenv, though.
To make OpenCV available to my application, I've initialized the virtualenv with --system-site-packages
.
When installing other dependencies with env/bin/pip install -U -r requirements.txt
now, some of the requirements (which happen to be dependencies of OpenCV) are seen as satisfied. Not surprising, but also not what I want.
Is there a sane way to make only OpenCV available from site-packages, and have everything thing else loaded from, and installed to, the virtualenv?