KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I have two different versions of python installed on my machine: 2.4 and 2.7. I'm trying to install OpenCV(2.4.5) for the 2.7 version. cmake -D CMAKE_BUILD_TYPE=RELEASE -D CMAKE_INSTALL_PREFIX=/usr/local -D BUILD_NEW_PYTHON_SUPPORT=ON -D BUILD_EXAMPLES=ON .. It detects the python 2.4 as the current installation: -- Python: -- Interpreter: /usr/bin/python2.4 (ver 2.4) -- Libraries: /usr/lib64/python2.4/config/libpython2.4.a -- numpy: /usr/lib64/python2.4/site-packages/numpy/core/include (ver 1.2.1) -- packages path: lib/python2.4/site-packages and later in building opencv gives me this error: [ 75%] Generating pyopencv_generated_funcs.h, pyopencv_generated_func_tab.h, pyopencv_generated_types.h, pyopencv_generated_type_reg.h, pyopencv_generated_const_reg.h File "/home/mmoghimi/opencv-2.4.5/modules/python/src2/gen2.py", line 815 cname1=("cv::Algorithm" if classinfo.isalgorithm else classinfo.cname))) ^ SyntaxError: invalid syntax make[2]: *** [modules/python/pyopencv_generated_funcs.h] Error 1 make[1]: *** [modules/python/CMakeFiles/opencv_python.dir/all] Error 2 make: *** [all] Error 2 apparently it uses a new format that python2.4 does not support. So, my question is that is there any way to explicitly specify the version of python?
Tags (comma-separated)
Save Edits
Cancel