Hi,
I tried to build the (opencv _4.6.0 + contrib_4.6.0) with Cuda support (cuda compatibility 3.5) and Cuda SDK Toolkit 10.0. It failed to build.
Here are the steps I have performed,
Used CMAKE GUI + VS 2015.
cmake output
General configuration for OpenCV 4.6.0 =====================================
Version control: unknown
Extra modules:
Location (extra): E:/opencv/opencv_contrib-4.6.0/modules
Version control (extra): unknown
Platform:
Timestamp: 2022-10-13T11:32:29Z
Host: Windows 10.0.19043 AMD64
CMake: 3.24.0-rc5
CMake generator: Visual Studio 14 2015
CMake build tool: C:/Program Files (x86)/MSBuild/14.0/bin/MSBuild.exe
MSVC: 1900
Configuration: Release
CPU/HW features:
Baseline: SSE SSE2 SSE3
requested: SSE3
Dispatched code generation: SSE4_1 SSE4_2 FP16 AVX
requested: SSE4_1 SSE4_2 AVX FP16 AVX2 AVX512_SKX
SSE4_1 (18 files): + SSSE3 SSE4_1
SSE4_2 (2 files): + SSSE3 SSE4_1 POPCNT SSE4_2
FP16 (1 files): + SSSE3 SSE4_1 POPCNT SSE4_2 FP16 AVX
AVX (5 files): + SSSE3 SSE4_1 POPCNT SSE4_2 AVX
C/C++:
Built as dynamic libs?: YES
C++ standard: 11
C++ Compiler: C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/bin/x86_amd64/cl.exe (ver 19.0.23026.0)
C++ flags (Release): /DWIN32 /D_WINDOWS /W4 /GR /D _CRT_SECURE_NO_DEPRECATE /D _CRT_NONSTDC_NO_DEPRECATE /D _SCL_SECURE_NO_WARNINGS /Gy /bigobj /Oi /fp:fast /EHa /wd4127 /wd4251 /wd4324 /wd4275 /wd4512 /wd4589 /MP /MD /O2 /Ob2 /DNDEBUG
C++ flags (Debug): /DWIN32 /D_WINDOWS /W4 /GR /D _CRT_SECURE_NO_DEPRECATE /D _CRT_NONSTDC_NO_DEPRECATE /D _SCL_SECURE_NO_WARNINGS /Gy /bigobj /Oi /fp:fast /EHa /wd4127 /wd4251 /wd4324 /wd4275 /wd4512 /wd4589 /MP /MDd /Zi /Ob0 /Od /RTC1
C Compiler: C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/bin/x86_amd64/cl.exe
C flags (Release): /DWIN32 /D_WINDOWS /W3 /D _CRT_SECURE_NO_DEPRECATE /D _CRT_NONSTDC_NO_DEPRECATE /D _SCL_SECURE_NO_WARNINGS /Gy /bigobj /Oi /fp:fast /MP /MD /O2 /Ob2 /DNDEBUG
C flags (Debug): /DWIN32 /D_WINDOWS /W3 /D _CRT_SECURE_NO_DEPRECATE /D _CRT_NONSTDC_NO_DEPRECATE /D _SCL_SECURE_NO_WARNINGS /Gy /bigobj /Oi /fp:fast /MP /MDd /Zi /Ob0 /Od /RTC1
Linker flags (Release): /machine:x64 /INCREMENTAL:NO
Linker flags (Debug): /machine:x64 /debug /INCREMENTAL
ccache: NO
Precompiled headers: NO
Extra dependencies: cudart_static.lib nppc.lib nppial.lib nppicc.lib nppicom.lib nppidei.lib nppif.lib nppig.lib nppim.lib nppist.lib nppisu.lib nppitc.lib npps.lib cublas.lib cudnn.lib cufft.lib -LIBPATH:C:/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v10.0/lib/x64
3rdparty dependencies:
OpenCV modules:
To be built: aruco barcode bgsegm bioinspired calib3d ccalib core cudaarithm cudabgsegm cudacodec cudafeatures2d cudafilters cudaimgproc cudalegacy cudaobjdetect cudaoptflow cudastereo cudawarping cudev datasets dnn dnn_objdetect dnn_superres dpm face features2d flann fuzzy gapi hfs highgui img_hash imgcodecs imgproc intensity_transform line_descriptor mcc ml objdetect optflow phase_unwrapping photo plot quality rapid reg rgbd saliency shape stereo stitching structured_light superres surface_matching text tracking ts video videoio videostab wechat_qrcode world xfeatures2d ximgproc xobjdetect xphoto
Disabled: -
Disabled by dependency: -
Unavailable: alphamat cvv freetype hdf java julia matlab ovis python2 python3 sfm viz
Applications: tests perf_tests apps
Documentation: NO
Non-free algorithms: NO
Windows RT support: NO
GUI:
Win32 UI: YES
VTK support: NO
Media I/O:
ZLib: build (ver 1.2.12)
JPEG: build-libjpeg-turbo (ver 2.1.2-62)
WEBP: build (ver encoder: 0x020f)
PNG: build (ver 1.6.37)
TIFF: build (ver 42 - 4.2.0)
JPEG 2000: build (ver 2.4.0)
OpenEXR: build (ver 2.3.0)
HDR: YES
SUNRASTER: YES
PXM: YES
PFM: YES
Video I/O:
DC1394: NO
FFMPEG: YES (prebuilt binaries)
avcodec: YES (58.134.100)
avformat: YES (58.76.100)
avutil: YES (56.70.100)
swscale: YES (5.9.100)
avresample: YES (4.0.0)
GStreamer: NO
DirectShow: YES
Media Foundation: YES
DXVA: NO
Parallel framework: Concurrency
Trace: YES (with Intel ITT)
Other third-party libraries:
Intel IPP: 2020.0.0 Gold [2020.0.0]
at: E:/opencv/opencv-4.6.0/build/3rdparty/ippicv/ippicv_win/icv
Intel IPP IW: sources (2020.0.0)
at: E:/opencv/opencv-4.6.0/build/3rdparty/ippicv/ippicv_win/iw
Lapack: NO
Eigen: NO
Custom HAL: NO
Protobuf: build (3.19.1)
NVIDIA CUDA: YES (ver 10.0, CUFFT CUBLAS FAST_MATH)
NVIDIA GPU arch: 35
NVIDIA PTX archs:
cuDNN: YES (ver 7.6.5)
OpenCL: YES (NVD3D11)
Include path: E:/opencv/opencv-4.6.0/3rdparty/include/opencl/1.2
Link libraries: Dynamic load
Python (for build): C:/Development/Python/Python Umgebung für Eta-Test/allinone/WinPython-64bit-3.4.4.2/python-3.4.4.amd64/python.exe
Java:
ant: NO
JNI: NO
Java wrappers: NO
Java tests: NO
Install to: E:/opencv/opencv-4.6.0/build/install
On opening the file OpenCV.sln with VS 2015, I perfomed Build to ALL_BUILD under CMakeTargets.
Before this, I have succesfully build the opencv for GPU with cuda compatibility of 8.5 on VS 2019. But with C.C 3.5 i faced issue using V.S 2019 that it should be compiled with VS (13 - 17). So i have installed 2015 and it still threw a lot of errors.
Also I am not able to attach the build logs as it is much bigger then the allowed size here.
snapshot of build error.
120> test_bgfg_mog2.cpp
120> test_dis.cpp
120> test_optflow_farneback.cpp
120> test_OF_accuracy.cpp
120> test_OF_reproducibility.cpp
120> test_accum.cpp
120> test_camshift.cpp
120> test_ecc.cpp
120> test_estimaterigid.cpp
120> test_kalman.cpp
120> test_main.cpp
120> test_trackers.cpp
121> test_audio.cpp
121> test_camera.cpp
121> test_container_avi.cpp
121> test_dynamic.cpp
121> test_ffmpeg.cpp
121> test_gstreamer.cpp
121> test_main.cpp
121> test_mfx.cpp
121> test_microphone.cpp
121> test_plugins.cpp
121> test_video_io.cpp
111> test_colored_kinfu.cpp
111> test_dynafu.cpp
111> test_kinfu.cpp
111> test_main.cpp
111> test_normal.cpp
111> test_odometry.cpp
111> test_pose_graph.cpp
111> test_registration.cpp
111> test_utils.cpp
117>LINK : fatal error LNK1181: cannot open input file '..\..\lib\Release\opencv_world460.lib'
100> test_color.cpp
120> test_optflowpyrlk.cpp
113>LINK : fatal error LNK1181: cannot open input file '..\..\lib\Release\opencv_world460.lib'
78> test_intrin128.sse3.cpp
111> test_tsdf.cpp
121>LINK : fatal error LNK1181: cannot open input file '..\..\lib\Release\opencv_world460.lib'
120> test_optflowpyrlk.cpp
111>LINK : fatal error LNK1181: cannot open input file '..\..\lib\Release\opencv_world460.lib'
120>LINK : fatal error LNK1181: cannot open input file '..\..\lib\Release\opencv_world460.lib'
100> test_houghlines.cpp
100> test_canny.cpp
100> test_color.cpp
78>LINK : fatal error LNK1181: cannot open input file '..\..\lib\Release\opencv_world460.lib'
100> test_houghlines.cpp
100>LINK : fatal error LNK1181: cannot open input file '..\..\lib\Release\opencv_world460.lib'