欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页  >  网络运营

Ubuntu18.04安装opencv 3.2.0的解决方法

程序员文章站 2023-08-26 22:34:25
下载opencv.zip 要提前安装依赖项。 先更新一下下载源。用17.04 的源可以解决在18.04中找不到libjasper.dev的问题。 ref h...

下载opencv.zip

要提前安装依赖项。

先更新一下下载源。用17.04 的源可以解决在18.04中找不到libjasper.dev的问题。

ref
https://*.com/questions/43484357/opencv-in-ubuntu-17-04
libjasper-dev无法安装
errore: unable to locate libjasper-dev

解决方法

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

报错:

-- checking for module 'gstreamer-base-1.0'
--   no package 'gstreamer-base-1.0' found
-- checking for module 'gstreamer-video-1.0'
--   no package 'gstreamer-video-1.0' found
-- checking for module 'gstreamer-app-1.0'
--   no package 'gstreamer-app-1.0' found
-- checking for module 'gstreamer-riff-1.0'
--   no package 'gstreamer-riff-1.0' found
-- checking for module 'gstreamer-pbutils-1.0'
--   no package 'gstreamer-pbutils-1.0' found
-- checking for module 'gstreamer-base-0.10'
--   no package 'gstreamer-base-0.10' found
-- checking for module 'gstreamer-video-0.10'
--   no package 'gstreamer-video-0.10' found
-- checking for module 'gstreamer-app-0.10'
--   no package 'gstreamer-app-0.10' found
-- checking for module 'gstreamer-riff-0.10'
--   no package 'gstreamer-riff-0.10' found
-- checking for module 'gstreamer-pbutils-0.10'
--   no package 'gstreamer-pbutils-0.10' found

解决方法

ref
https://*.com/questions/37678324/compiling-opencv-with-gstreamer-cmake-not-finding-gstreamer

安装

sudo apt install libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev

报错

-- cuda detected: 9.0
-- cuda nvcc target flags: -gencode;arch=compute_20,code=sm_20;-gencode;arch=compute_30,code=sm_30;-gencode;arch=compute_35,code=sm_35;-gencode;arch=compute_37,code=sm_37;-gencode;arch=compute_50,code=sm_50;-gencode;arch=compute_52,code=sm_52;-gencode;arch=compute_60,code=sm_60;-gencode;arch=compute_61,code=sm_61;-d_force_inlines
-- could not find openblas lib. turning openblas_found off
-- could not find atlas (missing: atlas_clapack_include_dir atlas_cblas_library atlas_blas_library atlas_lapack_library)
-- could not find doxygen (missing: doxygen_executable)
-- could not find jni (missing: java_awt_library java_jvm_library java_include_path java_include_path2 java_awt_include_path)
-- vtk is not found. please set -dvtk_dir in cmake to vtk build directory, or to vtk install subdirectory with vtkconfig.cmake file

总结

以上所述是小编给大家介绍的ubuntu18.04安装opencv 3.2.0的解决方法,希望对大家有所帮助