由于需要2和3两个版本,故安装双版本。v2按照网上指导安装,但是V3的安装有所区别如下。
http://blog.csdn.net/adong76/article/details/40018407
1、unzip 300.zip ; mkdir bulid ; cd build ;
2、不安装到/usr/local下,改为安装到/home/chris/Lib
3、gedit /etc/bash.bashrc,
# OpenCV 2.4.9
#PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig
# OpenCV 3.0.0
PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/home/chris/Lib/lib/pkgconfig
export PKG_CONFIG_PATH
4、reboot
5、在要编译到工程CMakeList.txt中,
FIND_PACKAGE(OpenCV 3.0 REQUIRED PATHS /home/chris/Lib/share/OpenCV/)
否则cmake .会失败
http://blog.csdn.net/adong76/article/details/40018407
1、unzip 300.zip ; mkdir bulid ; cd build ;
2、不安装到/usr/local下,改为安装到/home/chris/Lib
3、gedit /etc/bash.bashrc,
# OpenCV 2.4.9
#PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig
# OpenCV 3.0.0
PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/home/chris/Lib/lib/pkgconfig
export PKG_CONFIG_PATH
4、reboot
5、在要编译到工程CMakeList.txt中,
FIND_PACKAGE(OpenCV 3.0 REQUIRED PATHS /home/chris/Lib/share/OpenCV/)
否则cmake .会失败