Skip to content
Advertisement

OpenCV with Python and Java support using cmake command line

I am trying to install latest OpenCV from here: https://github.com/opencv/opencv on my Ubuntu 20.04.

I need python and java support. I have installed a lot of per-requisites and used this cmake command to configure the build using the command line:

$ cmake -DBUILD_SHARED_LIBS=OFF -DOPENCV_EXTRA_MODULES_PATH=/home/plamen/Install/OpenCV_install_info/OpenCV/opencv/build/opencv_contrib/modules 
        -DUSE_AVX_INSTRUCTIONS=ON -DUSE_SSE4_INSTRUCTIONS=ON 
        -DWITH_QT=ON -DWITH_OPENGL=ON  -DOpenGL_GL_PREFERENCE=GLVND 
        -DWITH_CUDA=ON -DBUILD_opencv_world=ON -DWITH_TESSERACT=ON 
        -DWITH_LAPACK=ON -DLAPACKE_INCLUDE_DIR=/home/plamen/Install/OpenCV_install_info/lapack-3.9.0/LAPACKE/include 
        -DLAPACK_CBLAS_H=/home/plamen/Install/OpenCV_install_info/lapack-3.9.0/CBLAS/include/cblas.h 
        -DLAPACK_LAPACKE_H=/home/plamen/Install/OpenCV_install_info/lapack-3.9.0/LAPACKE/include/lapacke.h 
        -DWITH_GSTREAMER=ON -DWITH_EIGEN=ON -DWITH_GTK=ON -DWITH_JASPER=ON -DWITH_FFMPEG=ON 
        -DBUILD_EXAMPLES=ON -DINSTALL_C_EXAMPLES=ON -DNSTALL_PYTHON_EXAMPLES=ON 
        -DOPENCV_ENABLE_NONFREE=ON -DINSTALL_TESTS=ON -DINSTALL_PYTHON_SAMPLES=ON -DINSTALL_C_SAMPLES=ON -DOPENCV_FORCE_3RDPARTY_BUILD=ON 
        -DPYTHON2_EXECUTABLE=/usr/bin/python2.7 -DPYTHON2_LIBRARY=/usr/lib/x86_64-linux-gnu/libpython2.7.so 
        -DPYTHON2_INCLUDE_DIR=/usr/include/python2.7 -DPYTHON2_NUMPY_INCLUDE_DIR=/usr/include/python2.7/numpy 
        -DPYTHON2_PACKAGES_PATH=/usr/lib/python2.7/dist-packages 
        -DPYTHON3_EXECUTABLE=/usr/bin/python3 -DPYTHON3_LIBRARY=/usr/lib/x86_64-linux-gnu/libpython3.8.so 
        -DPYTHON3_INCLUDE_DIR=/usr/include/python3.8 -DPYTHON3_NUMPY_INCLUDE_DIR=/usr/include/python3.8/numpy 
        -DPYTHON3_PACKAGES_PATH=/usr/lib/python3/dist-packages -DOPENCV_FORCE_PYTHON_LIBS=ON 
        -DPYTHON_DEFAULT_EXECUTABLE=$(which python3) -DBUILD_NEW_PYTHON_SUPPORT=ON -DBUILD_opencv_python3=ON -DHAVE_opencv_python3=ON 
        -DBUILD_JAVA=ON -DBUILD_opencv_java=ON -DBUILD_opencv_java_bindings_generator=ON -DBUILD_opencv_java_bindings_gen=ON 
        -DJAVA_AWT_INCLUDE_PATH=/usr/lib/jvm/jdk-14.0.1/include -DJAVA_AWT_LIBRARY=/usr/lib/jvm/jdk-14.0.1/lib/libjawt.so 
        -DJAVA_INCLUDE_PATH=/usr/lib/jvm/jdk-14.0.1/include -DJAVA_INCLUDE_PATH2=/usr/lib/jvm/jdk-14.0.1/include/linux 
        -DJAVA_JVM_LIBRARY=/usr/lib/jvm/jdk-14.0.1/lib/server/libjvm.so 
        -DBUILD_TESTS=ON -DBUILD_opencv_imgproc=ON -DBUILD_opencv_imgcodecs=ON -DBUILD_opencv_core=ON 
        -DOPENCV_GENERATE_PKGCONFIG=ON ..

The output was this:

-- 
-- General configuration for OpenCV 4.4.0-pre =====================================
--   Version control:               4.3.0-529-ga5fdcf9881
-- 
--   Extra modules:
--     Location (extra):            /home/plamen/Install/OpenCV_install_info/OpenCV/opencv/build/opencv_contrib/modules
--     Version control (extra):     4.3.0-77-g52200a82
-- 
--   Platform:
--     Timestamp:                   2020-07-05T17:57:08Z
--     Host:                        Linux 5.4.0-40-generic x86_64
--     CMake:                       3.16.3
--     CMake generator:             Unix Makefiles
--     CMake build tool:            /usr/bin/make
--     Configuration:               Release
-- 
--   CPU/HW features:
--     Baseline:                    SSE SSE2 SSE3
--       requested:                 SSE3
--     Dispatched code generation:  SSE4_1 SSE4_2 FP16 AVX AVX2 AVX512_SKX
--       requested:                 SSE4_1 SSE4_2 AVX FP16 AVX2 AVX512_SKX
--       SSE4_1 (17 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
--       AVX2 (31 files):           + SSSE3 SSE4_1 POPCNT SSE4_2 FP16 FMA3 AVX AVX2
--       AVX512_SKX (7 files):      + SSSE3 SSE4_1 POPCNT SSE4_2 FP16 FMA3 AVX AVX2 AVX_512F AVX512_COMMON AVX512_SKX
-- 
--   C/C++:
--     Built as dynamic libs?:      NO
--     C++ standard:                11
--     C++ Compiler:                /usr/bin/c++  (ver 9.3.0)
--     C++ flags (Release):         -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wundef -Winit-self -Wpointer-arith -Wshadow -Wsign-promo -Wuninitialized -Winit-self -Wsuggest-override -Wno-delete-non-virtual-dtor -Wno-comment -Wimplicit-fallthrough=3 -Wno-strict-overflow -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections  -msse -msse2 -msse3 -fvisibility=hidden -fvisibility-inlines-hidden -O3 -DNDEBUG  -DNDEBUG
--     C++ flags (Debug):           -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wundef -Winit-self -Wpointer-arith -Wshadow -Wsign-promo -Wuninitialized -Winit-self -Wsuggest-override -Wno-delete-non-virtual-dtor -Wno-comment -Wimplicit-fallthrough=3 -Wno-strict-overflow -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections  -msse -msse2 -msse3 -fvisibility=hidden -fvisibility-inlines-hidden -g  -O0 -DDEBUG -D_DEBUG
--     C Compiler:                  /usr/bin/cc
--     C flags (Release):           -fsigned-char -W -Wall -Werror=return-type -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wundef -Winit-self -Wpointer-arith -Wshadow -Wuninitialized -Winit-self -Wno-comment -Wimplicit-fallthrough=3 -Wno-strict-overflow -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections  -msse -msse2 -msse3 -fvisibility=hidden -O3 -DNDEBUG  -DNDEBUG
--     C flags (Debug):             -fsigned-char -W -Wall -Werror=return-type -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wundef -Winit-self -Wpointer-arith -Wshadow -Wuninitialized -Winit-self -Wno-comment -Wimplicit-fallthrough=3 -Wno-strict-overflow -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections  -msse -msse2 -msse3 -fvisibility=hidden -g  -O0 -DDEBUG -D_DEBUG
--     Linker flags (Release):      -Wl,--exclude-libs,libippicv.a -Wl,--exclude-libs,libippiw.a   -Wl,--gc-sections -Wl,--as-needed  
--     Linker flags (Debug):        -Wl,--exclude-libs,libippicv.a -Wl,--exclude-libs,libippiw.a   -Wl,--gc-sections -Wl,--as-needed  
--     ccache:                      NO
--     Precompiled headers:         NO
--     Extra dependencies:          Qt5::Core Qt5::Gui Qt5::Widgets Qt5::Test Qt5::Concurrent Qt5::OpenGL /usr/lib/x86_64-linux-gnu/hdf5/serial/libhdf5.so /usr/lib/x86_64-linux-gnu/libpthread.so /usr/lib/x86_64-linux-gnu/libsz.so /usr/lib/x86_64-linux-gnu/libz.so /usr/lib/x86_64-linux-gnu/libdl.so /usr/lib/x86_64-linux-gnu/libm.so /usr/lib/x86_64-linux-gnu/libfreetype.so /usr/lib/x86_64-linux-gnu/libharfbuzz.so ade correspondence multiview numeric /usr/lib/x86_64-linux-gnu/libglog.so gflags_shared m pthread /usr/lib/x86_64-linux-gnu/libOpenGL.so /usr/lib/x86_64-linux-gnu/libGLX.so /usr/lib/x86_64-linux-gnu/libGLU.so cudart_static -lpthread dl rt nppc nppial nppicc nppidei nppif nppig nppim nppist nppisu nppitc npps cublas cudnn cufft -L/usr/local/cuda/lib64 -L/usr/lib/x86_64-linux-gnu
--     3rdparty dependencies:       libprotobuf libjpeg-turbo libwebp libpng libtiff libjasper IlmImf zlib ittnotify quirc ippiw ippicv
-- 
--   OpenCV modules:
--     To be built:                 alphamat aruco bgsegm bioinspired calib3d ccalib core cudaarithm cudabgsegm cudacodec cudafeatures2d cudafilters cudaimgproc cudalegacy cudaobjdetect cudaoptflow cudastereo cudawarping cudev cvv datasets dnn dnn_objdetect dnn_superres dpm face features2d flann freetype fuzzy gapi hdf hfs highgui img_hash imgcodecs imgproc intensity_transform line_descriptor ml objdetect optflow phase_unwrapping photo plot python2 python3 quality rapid reg rgbd saliency sfm shape stereo stitching structured_light superres surface_matching text tracking ts video videoio videostab world xfeatures2d ximgproc xobjdetect xphoto
--     Disabled:                    -
--     Disabled by dependency:      -
--     Unavailable:                 cnn_3dobj java js julia matlab ovis python2 viz
--     Applications:                tests perf_tests examples apps
--     Documentation:               NO
--     Non-free algorithms:         YES
-- 
--   GUI: 
--     QT:                          YES (ver 5.12.8)
--       QT OpenGL support:         YES (Qt5::OpenGL 5.12.8)
--     GTK+:                        NO
--     OpenGL support:              YES (/usr/lib/x86_64-linux-gnu/libOpenGL.so /usr/lib/x86_64-linux-gnu/libGLX.so /usr/lib/x86_64-linux-gnu/libGLU.so)
--     VTK support:                 NO
-- 
--   Media I/O: 
--     ZLib:                        build (ver 1.2.11)
--     JPEG:                        build-libjpeg-turbo (ver 2.0.5-62)
--     WEBP:                        build (ver encoder: 0x020f)
--     PNG:                         build (ver 1.6.37)
--     TIFF:                        build (ver 42 - 4.0.10)
--     JPEG 2000:                   build Jasper (ver 1.900.1)
--     OpenEXR:                     build (ver 2.3.0)
--     HDR:                         YES
--     SUNRASTER:                   YES
--     PXM:                         YES
--     PFM:                         YES
-- 
--   Video I/O:
--     DC1394:                      NO
--     FFMPEG:                      YES
--       avcodec:                   YES (58.54.100)
--       avformat:                  YES (58.29.100)
--       avutil:                    YES (56.31.100)
--       swscale:                   YES (5.5.100)
--       avresample:                NO
--     GStreamer:                   YES (1.16.2)
--     v4l/v4l2:                    YES (linux/videodev2.h)
-- 
--   Parallel framework:            pthreads
-- 
--   Trace:                         YES (with Intel ITT)
-- 
--   Other third-party libraries:
--     Intel IPP:                   2020.0.0 Gold [2020.0.0]
--            at:                   /home/plamen/Install/OpenCV_install_info/OpenCV/opencv/build/3rdparty/ippicv/ippicv_lnx/icv
--     Intel IPP IW:                sources (2020.0.0)
--               at:                /home/plamen/Install/OpenCV_install_info/OpenCV/opencv/build/3rdparty/ippicv/ippicv_lnx/iw
--     Lapack:                      NO
--     Eigen:                       YES (ver 3.3.7)
--     Custom HAL:                  NO
--     Protobuf:                    build (3.5.1)
-- 
--   NVIDIA CUDA:                   YES (ver 11.0, CUFFT CUBLAS)
--     NVIDIA GPU arch:             30 35 37 50 52 60 61 70 75 80
--     NVIDIA PTX archs:
-- 
--   cuDNN:                         YES (ver 8.0.1)
-- 
--   OpenCL:                        YES (no extra features)
--     Include path:                /home/plamen/Install/OpenCV_install_info/OpenCV/opencv/3rdparty/include/opencl/1.2
--     Link libraries:              Dynamic load
-- 
--   Python 2:
--     Interpreter:                 /usr/bin/python2.7 (ver 2.7.18)
--     Libraries:                   /usr/lib/x86_64-linux-gnu/libpython2.7.so (ver 2.7.18rc1)
--     numpy:                       /usr/lib/python2.7/dist-packages/numpy/core/include (ver 1.16.5)
--     install path:                /usr/lib/python2.7/dist-packages/cv2/python-2.7
-- 
--   Python 3:
--     Interpreter:                 /usr/bin/python3 (ver 3.8.2)
--     Libraries:                   /usr/lib/x86_64-linux-gnu/libpython3.8.so (ver 3.8.2)
--     numpy:                       /usr/lib/python3/dist-packages/numpy/core/include (ver 1.17.4)
--     install path:                /usr/lib/python3/dist-packages/cv2/python-3.8
-- 
--   Python (for build):            /usr/bin/python3
-- 
--   Java:                          
--     ant:                         /snap/bin/ant (ver 1.10.8)
--     JNI:                         /usr/lib/jvm/jdk-14.0.1/include /usr/lib/jvm/jdk-14.0.1/include/linux /usr/lib/jvm/jdk-14.0.1/include
--     Java wrappers:               NO
--     Java tests:                  NO
-- 
--   Install to:                    /usr/local
-- -----------------------------------------------------------------
-- 
-- Configuring done
-- Generating done
-- Build files have been written to: /home/plamen/Install/OpenCV_install_info/OpenCV/opencv/build

I see that cmake finds my python 2 and python 3 versions, finds also my java JNI and ant, but I see that the java module is listed in the unavailable modules list:

Unavailable: cnn_3dobj java js julia matlab ovis python2 viz

I see also that Java Wrappers and Java tests are marked with NO: — Java wrappers: NO — Java tests: NO

Please advise what am I doing wrong and how to make cmake build my java module, and find java wrappers and build java tests?

Thank you in advance for your help!

Advertisement

Answer

Meanwhile I found the reason. The problem was this option: -DBUILD_opencv_world=ON When I removed it:

$ cmake -DBUILD_SHARED_LIBS=OFF -DOPENCV_EXTRA_MODULES_PATH=/home/plamen/Install/OpenCV_install_info/OpenCV/opencv/build/opencv_contrib/modules 
        -DUSE_AVX_INSTRUCTIONS=ON -DUSE_SSE4_INSTRUCTIONS=ON 
        -DWITH_QT=ON -DWITH_OPENGL=ON  -DOpenGL_GL_PREFERENCE=GLVND 
        -DWITH_CUDA=ON -DWITH_TESSERACT=ON 
        -DWITH_LAPACK=ON -DLAPACKE_INCLUDE_DIR=/home/plamen/Install/OpenCV_install_info/lapack-3.9.0/LAPACKE/include 
        -DLAPACK_CBLAS_H=/home/plamen/Install/OpenCV_install_info/lapack-3.9.0/CBLAS/include/cblas.h 
        -DLAPACK_LAPACKE_H=/home/plamen/Install/OpenCV_install_info/lapack-3.9.0/LAPACKE/include/lapacke.h 
        -DWITH_GSTREAMER=ON -DWITH_EIGEN=ON -DWITH_GTK=ON -DWITH_JASPER=ON -DWITH_FFMPEG=ON 
        -DBUILD_EXAMPLES=ON -DINSTALL_C_EXAMPLES=ON -DINSTALL_PYTHON_EXAMPLES=ON 
        -DOPENCV_ENABLE_NONFREE=ON -DINSTALL_TESTS=ON -DINSTALL_PYTHON_SAMPLES=ON -DINSTALL_C_SAMPLES=ON -DOPENCV_FORCE_3RDPARTY_BUILD=ON 
        -DPYTHON2_EXECUTABLE=/usr/bin/python2.7 -DPYTHON2_LIBRARY=/usr/lib/x86_64-linux-gnu/libpython2.7.so 
        -DPYTHON2_INCLUDE_DIR=/usr/include/python2.7 -DPYTHON2_NUMPY_INCLUDE_DIR=/usr/include/python2.7/numpy 
        -DPYTHON2_PACKAGES_PATH=/usr/lib/python2.7/dist-packages 
        -DPYTHON3_EXECUTABLE=/usr/bin/python3 -DPYTHON3_LIBRARY=/usr/lib/x86_64-linux-gnu/libpython3.8.so 
        -DPYTHON3_INCLUDE_DIR=/usr/include/python3.8 -DPYTHON3_NUMPY_INCLUDE_DIR=/usr/include/python3.8/numpy 
        -DPYTHON3_PACKAGES_PATH=/usr/lib/python3/dist-packages -DOPENCV_FORCE_PYTHON_LIBS=ON 
        -DPYTHON_DEFAULT_EXECUTABLE=$(which python3) -DBUILD_NEW_PYTHON_SUPPORT=ON -DBUILD_opencv_python3=ON -DHAVE_opencv_python3=ON 
        -DBUILD_JAVA=ON -DBUILD_opencv_java=ON -DBUILD_opencv_java_bindings_generator=ON -DBUILD_opencv_java_bindings_gen=ON 
        -DJAVA_AWT_INCLUDE_PATH=/usr/lib/jvm/jdk-14.0.1/include -DJAVA_AWT_LIBRARY=/usr/lib/jvm/jdk-14.0.1/lib/libjawt.so 
        -DJAVA_INCLUDE_PATH=/usr/lib/jvm/jdk-14.0.1/include -DJAVA_INCLUDE_PATH2=/usr/lib/jvm/jdk-14.0.1/include/linux 
        -DJAVA_JVM_LIBRARY=/usr/lib/jvm/jdk-14.0.1/lib/server/libjvm.so 
        -DBUILD_TESTS=ON -DBUILD_opencv_imgproc=ON -DBUILD_opencv_imgcodecs=ON -DBUILD_opencv_core=ON 
        -DOPENCV_GENERATE_PKGCONFIG=ON .. 

java was found successfuly and I got this nice output:

-- 
-- General configuration for OpenCV 4.4.0-pre =====================================
--   Version control:               4.3.0-529-ga5fdcf9881
-- 
--   Extra modules:
--     Location (extra):            /home/plamen/Install/OpenCV_install_info/OpenCV/opencv/build/opencv_contrib/modules
--     Version control (extra):     4.3.0-77-g52200a82
-- 
--   Platform:
--     Timestamp:                   2020-07-06T18:51:57Z
--     Host:                        Linux 5.4.0-40-generic x86_64
--     CMake:                       3.16.3
--     CMake generator:             Unix Makefiles
--     CMake build tool:            /usr/bin/make
--     Configuration:               Release
-- 
--   CPU/HW features:
--     Baseline:                    SSE SSE2 SSE3
--       requested:                 SSE3
--     Dispatched code generation:  SSE4_1 SSE4_2 FP16 AVX AVX2 AVX512_SKX
--       requested:                 SSE4_1 SSE4_2 AVX FP16 AVX2 AVX512_SKX
--       SSE4_1 (17 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
--       AVX2 (31 files):           + SSSE3 SSE4_1 POPCNT SSE4_2 FP16 FMA3 AVX AVX2
--       AVX512_SKX (7 files):      + SSSE3 SSE4_1 POPCNT SSE4_2 FP16 FMA3 AVX AVX2 AVX_512F AVX512_COMMON AVX512_SKX
-- 
--   C/C++:
--     Built as dynamic libs?:      NO
--     C++ standard:                11
--     C++ Compiler:                /usr/bin/c++  (ver 9.3.0)
--     C++ flags (Release):         -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wundef -Winit-self -Wpointer-arith -Wshadow -Wsign-promo -Wuninitialized -Winit-self -Wsuggest-override -Wno-delete-non-virtual-dtor -Wno-comment -Wimplicit-fallthrough=3 -Wno-strict-overflow -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections  -msse -msse2 -msse3 -fvisibility=hidden -fvisibility-inlines-hidden -O3 -DNDEBUG  -DNDEBUG
--     C++ flags (Debug):           -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wundef -Winit-self -Wpointer-arith -Wshadow -Wsign-promo -Wuninitialized -Winit-self -Wsuggest-override -Wno-delete-non-virtual-dtor -Wno-comment -Wimplicit-fallthrough=3 -Wno-strict-overflow -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections  -msse -msse2 -msse3 -fvisibility=hidden -fvisibility-inlines-hidden -g  -O0 -DDEBUG -D_DEBUG
--     C Compiler:                  /usr/bin/cc
--     C flags (Release):           -fsigned-char -W -Wall -Werror=return-type -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wundef -Winit-self -Wpointer-arith -Wshadow -Wuninitialized -Winit-self -Wno-comment -Wimplicit-fallthrough=3 -Wno-strict-overflow -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections  -msse -msse2 -msse3 -fvisibility=hidden -O3 -DNDEBUG  -DNDEBUG
--     C flags (Debug):             -fsigned-char -W -Wall -Werror=return-type -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wundef -Winit-self -Wpointer-arith -Wshadow -Wuninitialized -Winit-self -Wno-comment -Wimplicit-fallthrough=3 -Wno-strict-overflow -fdiagnostics-show-option -Wno-long-long -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections  -msse -msse2 -msse3 -fvisibility=hidden -g  -O0 -DDEBUG -D_DEBUG
--     Linker flags (Release):      -Wl,--exclude-libs,libippicv.a -Wl,--exclude-libs,libippiw.a   -Wl,--gc-sections -Wl,--as-needed  
--     Linker flags (Debug):        -Wl,--exclude-libs,libippicv.a -Wl,--exclude-libs,libippiw.a   -Wl,--gc-sections -Wl,--as-needed  
--     ccache:                      NO
--     Precompiled headers:         NO
--     Extra dependencies:          ade Qt5::Test Qt5::Concurrent Qt5::OpenGL Qt5::Core Qt5::Gui Qt5::Widgets /usr/lib/x86_64-linux-gnu/libfreetype.so /usr/lib/x86_64-linux-gnu/libharfbuzz.so /usr/lib/x86_64-linux-gnu/hdf5/serial/libhdf5.so /usr/lib/x86_64-linux-gnu/libpthread.so /usr/lib/x86_64-linux-gnu/libsz.so /usr/lib/x86_64-linux-gnu/libz.so /usr/lib/x86_64-linux-gnu/libdl.so /usr/lib/x86_64-linux-gnu/libm.so correspondence multiview numeric /usr/lib/x86_64-linux-gnu/libglog.so gflags_shared m pthread /usr/lib/x86_64-linux-gnu/libOpenGL.so /usr/lib/x86_64-linux-gnu/libGLX.so /usr/lib/x86_64-linux-gnu/libGLU.so cudart_static -lpthread dl rt nppc nppial nppicc nppidei nppif nppig nppim nppist nppisu nppitc npps cublas cudnn cufft -L/usr/local/cuda/lib64 -L/usr/lib/x86_64-linux-gnu
--     3rdparty dependencies:       ittnotify libprotobuf zlib libjpeg-turbo libwebp libpng libtiff libjasper IlmImf quirc ippiw ippicv
-- 
--   OpenCV modules:
--     To be built:                 alphamat aruco bgsegm bioinspired calib3d ccalib core cudaarithm cudabgsegm cudacodec cudafeatures2d cudafilters cudaimgproc cudalegacy cudaobjdetect cudaoptflow cudastereo cudawarping cudev cvv datasets dnn dnn_objdetect dnn_superres dpm face features2d flann freetype fuzzy gapi hdf hfs highgui img_hash imgcodecs imgproc intensity_transform java line_descriptor ml objdetect optflow phase_unwrapping photo plot python2 python3 quality rapid reg rgbd saliency sfm shape stereo stitching structured_light superres surface_matching text tracking ts video videoio videostab xfeatures2d ximgproc xobjdetect xphoto
--     Disabled:                    world
--     Disabled by dependency:      -
--     Unavailable:                 cnn_3dobj js julia matlab ovis viz
--     Applications:                tests perf_tests examples apps
--     Documentation:               NO
--     Non-free algorithms:         YES
-- 
--   GUI: 
--     QT:                          YES (ver 5.12.8)
--       QT OpenGL support:         YES (Qt5::OpenGL 5.12.8)
--     GTK+:                        NO
--     OpenGL support:              YES (/usr/lib/x86_64-linux-gnu/libOpenGL.so /usr/lib/x86_64-linux-gnu/libGLX.so /usr/lib/x86_64-linux-gnu/libGLU.so)
--     VTK support:                 NO
-- 
--   Media I/O: 
--     ZLib:                        build (ver 1.2.11)
--     JPEG:                        build-libjpeg-turbo (ver 2.0.5-62)
--     WEBP:                        build (ver encoder: 0x020f)
--     PNG:                         build (ver 1.6.37)
--     TIFF:                        build (ver 42 - 4.0.10)
--     JPEG 2000:                   build Jasper (ver 1.900.1)
--     OpenEXR:                     build (ver 2.3.0)
--     HDR:                         YES
--     SUNRASTER:                   YES
--     PXM:                         YES
--     PFM:                         YES
-- 
--   Video I/O:
--     DC1394:                      NO
--     FFMPEG:                      YES
--       avcodec:                   YES (58.54.100)
--       avformat:                  YES (58.29.100)
--       avutil:                    YES (56.31.100)
--       swscale:                   YES (5.5.100)
--       avresample:                NO
--     GStreamer:                   YES (1.16.2)
--     v4l/v4l2:                    YES (linux/videodev2.h)
-- 
--   Parallel framework:            pthreads
-- 
--   Trace:                         YES (with Intel ITT)
-- 
--   Other third-party libraries:
--     Intel IPP:                   2020.0.0 Gold [2020.0.0]
--            at:                   /home/plamen/Install/OpenCV_install_info/OpenCV/opencv/build/3rdparty/ippicv/ippicv_lnx/icv
--     Intel IPP IW:                sources (2020.0.0)
--               at:                /home/plamen/Install/OpenCV_install_info/OpenCV/opencv/build/3rdparty/ippicv/ippicv_lnx/iw
--     Lapack:                      NO
--     Eigen:                       YES (ver 3.3.7)
--     Custom HAL:                  NO
--     Protobuf:                    build (3.5.1)
-- 
--   NVIDIA CUDA:                   YES (ver 11.0, CUFFT CUBLAS)
--     NVIDIA GPU arch:             30 35 37 50 52 60 61 70 75 80
--     NVIDIA PTX archs:
-- 
--   cuDNN:                         YES (ver 8.0.1)
-- 
--   OpenCL:                        YES (no extra features)
--     Include path:                /home/plamen/Install/OpenCV_install_info/OpenCV/opencv/3rdparty/include/opencl/1.2
--     Link libraries:              Dynamic load
-- 
--   Python 2:
--     Interpreter:                 /usr/bin/python2.7 (ver 2.7.18)
--     Libraries:                   /usr/lib/x86_64-linux-gnu/libpython2.7.so (ver 2.7.18rc1)
--     numpy:                       /usr/lib/python2.7/dist-packages/numpy/core/include (ver 1.16.5)
--     install path:                /usr/lib/python2.7/dist-packages/cv2/python-2.7
-- 
--   Python 3:
--     Interpreter:                 /usr/bin/python3 (ver 3.8.2)
--     Libraries:                   /usr/lib/x86_64-linux-gnu/libpython3.8.so (ver 3.8.2)
--     numpy:                       /usr/lib/python3/dist-packages/numpy/core/include (ver 1.17.4)
--     install path:                /usr/lib/python3/dist-packages/cv2/python-3.8
-- 
--   Python (for build):            /usr/bin/python3
-- 
--   Java:                          
--     ant:                         /snap/bin/ant (ver 1.10.8)
--     JNI:                         /usr/lib/jvm/jdk-14.0.1/include /usr/lib/jvm/jdk-14.0.1/include/linux /usr/lib/jvm/jdk-14.0.1/include
--     Java wrappers:               YES
--     Java tests:                  YES
-- 
--   Install to:                    /usr/local
-- -----------------------------------------------------------------
-- 
-- Configuring done
-- Generating done
-- Build files have been written to: /home/plamen/Install/OpenCV_install_info/OpenCV/opencv/build

Please, can somebody explain me why this option blocks the java? And do I need this option to be ON?

User contributions licensed under: CC BY-SA
1 People found this is helpful
Advertisement