转自:http://karytech.blogspot.com/2011/02/opencv-22-on-ubuntu-1010.html
This is how to build and install OpenCV 2.2 on Ubuntu 10.10.
First, install the dependencies from the repositories:
Download the source code:
Extract, create the build directory:
Configure, make and install:
To configure the library, edit the following file (might be empty):
and add the line
Then run:
Finally, edit the file:
and add the following lines at the end:
Most of the above was find here .
Older versions? Take a look at the following links:
OpenCV 2.1 on Ubuntu 10.04 (pretty much the same as above, but with TBB )
OpenCV 2.0 on Ubuntu 9.10