I am currently working on a project that add a new module to OpenCV 3.0 beta so I am trying to use my own compiled version with Python (just as a remark, the C++ version works).
Since I don't want to mess up with versions of OpenCV and Python already installed, I did not add to ldconfig my specific build/installation of OpenCV 3.0 beta and I would like to use it in a python virtualenv if possible.
So far I have setup the venv and since cv2 is not accessible in it, I update the PYTHONPATH to add the folder containing the cv2.so file (created with sudo apt-get install python-opencv). However, it is not the right version of opencv binding that are loaded :
$ python -c "import cv2; print cv2.__version__"
2.4.8
Have any idea on what I could do ?
EDIT (thanks @otibom):
My build seems to be the reason why I don't have the right cv2.so file. The results of cmake are :
-- Python 2:
-- Interpreter: /usr/bin/python2.7 (ver 2.7.6)
-- Libraries: NO
-- numpy: /usr/lib/python2.7/dist-packages/numpy/core/include (ver 1.8.2)
-- packages path: lib/python2.7/dist-packages
Is there a way to correct that ?