ubuntu配置opencv

1.下载opencv安装包

点击此处下载

2.安装流程

这个博主写的很好,可以看他的
https://blog.csdn.net/baidu_34971492/article/details/81665538

3.排错

1.sudo apt-get install libjasper-dev错误,可以用如下代码解决:

sudo add-apt-repository "deb http://security.ubuntu.com/ubuntu xenial-security main"
sudo apt update
sudo apt install libjasper1 libjasper-dev

如果add出错,就add清华的包。
2.sudo updatedb出错
可以sudo apt-get insatll locate(下载一个类似于locate的东西)
3.make编译报错
https://blog.csdn.net/baidu_34971492/article/details/81665538这个博主的代码里有各种非法字符,必须将所有的空格和回车删掉
4.显示与之前的包冲突
安装libavcodec-dev libavformat-dev的时候,可能报错,显示与之前的包冲突,参考下面这个博客,使用aptititude可解决问题
https://www.cnblogs.com/aaron-agu/p/8862624.html

猜你喜欢

转载自blog.csdn.net/weixin_44612221/article/details/107637467