ourvilla.blogg.se

Opencv build cmake linux
Opencv build cmake linux











So in most cases, include opencv.hpp may be enough if you do not care about compilation time (see also here and here for more discussions on this).

Opencv build cmake linux install#

I think you want INTERFACE_LINK_LIBRARIES instead here. Install minimal prerequisites (Ubuntu 18.04 as reference) sudo apt update & sudo apt install -y cmake g++ wget unzip. If you look at the header file opencv.hpp, you will find that it actually includes other OpenCV header files, if they are not included in your code already.

opencv build cmake linux

IMPORTED_LOCATION is the full path to the library that is being represented. INTERFACE_INCLUDE_DIRECTORIES /usr/include/opencv4) IMPORTED_LOCATION opencv_calib3d opencv_core opencv_dnn opencv_features2d opencv_flann opencv_gapi opencv_highgui opencv_imgcodecs opencv_imgproc opencv_ml opencv_objdetect opencv_photo opencv_stitching opencv_video opencv_videoio opencv_alphamat opencv_aruco opencv_bgsegm opencv_bioinspired opencv_ccalib opencv_cvv opencv_datasets opencv_dnn_objdetect opencv_dnn_superres opencv_dpm opencv_face opencv_freetype opencv_fuzzy opencv_hdf opencv_hfs opencv_img_hash opencv_intensity_transform opencv_line_descriptor opencv_mcc opencv_optflow opencv_phase_unwrapping opencv_plot opencv_quality opencv_rapid opencv_reg opencv_rgbd opencv_saliency opencv_shape opencv_stereo opencv_structured_light opencv_superres opencv_surface_matching opencv_text opencv_tracking opencv_videostab opencv_viz opencv_wechat_qrcode opencv_ximgproc opencv_xobjdetect opencv_xphoto It seems that the issue is (word wrapped for ease of reading): /builds/opencv/CMakeDemo/MyPackages/FindOpenCV.cmake(21): mkdir release cd release cmake -D CMAKETOOLCHAINFILEtoolchain. Which puzzles me is that in both cases (with or without OpenCV::OpenCV wrapping) all environment and cmake variables are the same… With CMake 3.19 works so it seems to be really an issue with the way I create OpenCV::OpenCV Set_target_properties(OpenCV::OpenCV PROPERTIES I require all my dependencies to use namespace for homogeneity but OpenCV does not provide OpenCV::OpenCV.Īdd_library(OpenCV::OpenCV UNKNOWN IMPORTED)

opencv build cmake linux

I’ve got an application A that depends privately on L and OpenCVįind_package(OpenCV REQUIRED) finds the 3.3 version, which is what I expect. I’ve got a static library L that depends publicly on OpenCV I fail to properly add a dependency to opencv3 in my devs.Ģ.4 which is the default one for ubuntu 16.04











Opencv build cmake linux