[OpenCV] How to build the OpenCV v2.2 ?
OpenCV is an open source project by Intel which is often used to develop the computer vision project. It’s efficiently and easily to use. In this article, I will write down the installation tutorial for you.
1. Because the OpenCV v2.2 had been changed to use the CMake tool for installing, we have to install the CMake tool first. Otherwise, you should prepare the OpenCV source code downloaded from http://sourceforge.net/projects/opencvlibrary/files/ .
2. Enter your path into the OpenCV directory. Execute this command,
#> cmake -D CMAKE_BUILD_TYPE=RELEASE ./
Note: “-D” is used to create environment variable.
3. After the step 2, you can find out a Makefile in the OpenCV directory. Then, execute the “make” command to build the OpenCV.
#> make
When the make procedure had been done, to execute the “make install” command.
#> sudo make install
4. Configure the environment,
#> export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH sudo ldconfig
5. When you want to compile application with OpenCV library, you have to include the OpenCV’s header files path in your Makefile. Enjoy it!
發佈留言
很抱歉,必須登入網站才能發佈留言。