step12
继续编译出现如下错误:
Linking CXX executable ../../bin/opencv_test_nonfree
[ 98%] Built target opencv_test_nonfree
[ 98%] Building CXX object modules/stitching/CMakeFiles/opencv_stitching.dir/src/autocalib.cpp.obj
[ 98%] Building CXX object modules/gpu/CMakeFiles/opencv_perf_gpu.dir/perf/perf_imgproc.cpp.obj
[ 98%] Building CXX object modules/stitching/CMakeFiles/opencv_stitching.dir/src/exposure_compensate.cpp.obj
[ 98%] Building CXX object modules/stitching/CMakeFiles/opencv_stitching.dir/src/warpers.cpp.obj
[ 98%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/fuzzymeanshifttracker.cpp.obj
[ 98%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/selfsimilarity.cpp.obj
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/detection_based_tracker.cpp.obj
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/octree.cpp.obj
[ 99%] Building CXX object modules/stitching/CMakeFiles/opencv_stitching.dir/src/stitcher.cpp.obj
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/colortracker.cpp.obj
[ 99%] Building CXX object modules/stitching/CMakeFiles/opencv_stitching.dir/src/motion_estimators.cpp.obj
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/parvoretinafilter.cpp.obj
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/logpolar_bsm.cpp.obj
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/basicretinafilter.cpp.obj
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/chamfermatching.cpp.obj
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/chamfermatching.cpp: In member function ‘void cv::ChamferMatcher::Matching::computeDistanceTransform(cv::Mat&, cv::Mat&, cv::Mat&, float, float, float)’:
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/chamfermatching.cpp:969:30: error: the compiler can assume that the address of ‘annotate_img’ will never be NULL [-Werror=address]
if (&annotate_img!=NULL) {
^
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/chamfermatching.cpp:1016:34: error: the compiler can assume that the address of ‘annotate_img’ will never be NULL [-Werror=address]
if (&annotate_img!=NULL) {
^
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/chamfermatching.cpp: In member function ‘cv::ChamferMatcher::Match* cv::ChamferMatcher::Matching::localChamferDistance(cv::Point, cv::Mat&, cv::Mat&, cv::ChamferMatcher::Template*, float)’:
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/chamfermatching.cpp:1111:25: error: the compiler can assume that the address of ‘orientation_img’ will never be NULL [-Werror=address]
if (&orientation_img!=NULL) {
^
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/magnoretinafilter.cpp.obj
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/chamfermatching.cpp:1111:5: warning: nonnull argument ‘orientation_img’ compared to NULL [-Wnonnull-compare]
if (&orientation_img!=NULL) {
^~
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/chamfermatching.cpp: In member function ‘void cv::ChamferMatcher::Matching::computeDistanceTransform(cv::Mat&, cv::Mat&, cv::Mat&, float, float, float)’:
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/chamfermatching.cpp:1016:17: warning: nonnull argument ‘annotate_img’ compared to NULL [-Wnonnull-compare]
if (&annotate_img!=NULL) {
^~
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/chamfermatching.cpp:969:13: warning: nonnull argument ‘annotate_img’ compared to NULL [-Wnonnull-compare]
if (&annotate_img!=NULL) {
^~
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/retinafilter.cpp.obj
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/rgbdodometry.cpp.obj
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/rgbdodometry.cpp:65:47: fatal error: unsupported/Eigen/MatrixFunctions: 没有那个文件或目录
# include
^
compilation terminated.
make[2]: *** [modules/contrib/CMakeFiles/opencv_contrib.dir/src/rgbdodometry.cpp.obj] 错误 1
make[2]: *** 正在等待未完成的任务....
Linking CXX shared library ../../lib/libopencv_stitching.so
[ 99%] Built target opencv_stitching
Scanning dependencies of target opencv_perf_stitching
Scanning dependencies of target opencv_test_stitching
[ 99%] [ 99%] [ 99%] Building CXX object modules/stitching/CMakeFiles/opencv_test_stitching.dir/test/test_blenders.cpp.obj
Building CXX object modules/stitching/CMakeFiles/opencv_test_stitching.dir/test/test_main.cpp.obj
Building CXX object modules/stitching/CMakeFiles/opencv_perf_stitching.dir/perf/perf_stich.cpp.obj
In file included from /home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/flann/include/opencv2/flann/params.h:33:0,
from /home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/flann/include/opencv2/flann/flann_base.hpp:41,
from /home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/flann/include/opencv2/flann/flann.hpp:50,
from /home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/stitching/perf/perf_stich.cpp:4:
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/flann/include/opencv2/flann/any.h: In member function ‘virtual void cvflann::anyimpl::big_any_policy::static_delete(void**)’:
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/flann/include/opencv2/flann/any.h:83:9: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
if (* x) delete (* reinterpret_cast(x)); *x = NULL;
^~
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/flann/include/opencv2/flann/any.h:83:55: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the ‘if’
if (* x) delete (* reinterpret_cast(x)); *x = NULL;
^
cc1plus: some warnings being treated as errors
make[2]: *** [modules/contrib/CMakeFiles/opencv_contrib.dir/src/chamfermatching.cpp.obj] 错误 1
make[1]: *** [modules/contrib/CMakeFiles/opencv_contrib.dir/all] 错误 2
make[1]: *** 正在等待未完成的任务....
[ 99%] Building CXX object modules/stitching/CMakeFiles/opencv_pe
以下错误解决办法:
修改build/modules/contrib/CMakeFiles/opencv_contrib.dir/flags.make
删除 CXX_FLAGS 中的 -Werror=address
2.4.9/modules/contrib/src/chamfermatching.cpp:969:30: error: the compiler can assume that the address of ‘annotate_img’ will never be NULL [-Werror=address]
if (&annotate_img!=NULL) {
以下错误解决办法:
进入Eigen3库目录发现缺少unsupported目录,下载新的Eigen库并替换,因为Eigen库全部都是头文件,所以直接替换就好,不依赖具体的平台。
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/rgbdo
step13
再次编译,编译成功。
step14
执行 make install 进行安装,安装完成后,可以将Install目录下的内容拷贝到RK3326板子上/usr目录下相关的目录中即可。
step12
继续编译出现如下错误:
Linking CXX executable ../../bin/opencv_test_nonfree
[ 98%] Built target opencv_test_nonfree
[ 98%] Building CXX object modules/stitching/CMakeFiles/opencv_stitching.dir/src/autocalib.cpp.obj
[ 98%] Building CXX object modules/gpu/CMakeFiles/opencv_perf_gpu.dir/perf/perf_imgproc.cpp.obj
[ 98%] Building CXX object modules/stitching/CMakeFiles/opencv_stitching.dir/src/exposure_compensate.cpp.obj
[ 98%] Building CXX object modules/stitching/CMakeFiles/opencv_stitching.dir/src/warpers.cpp.obj
[ 98%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/fuzzymeanshifttracker.cpp.obj
[ 98%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/selfsimilarity.cpp.obj
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/detection_based_tracker.cpp.obj
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/octree.cpp.obj
[ 99%] Building CXX object modules/stitching/CMakeFiles/opencv_stitching.dir/src/stitcher.cpp.obj
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/colortracker.cpp.obj
[ 99%] Building CXX object modules/stitching/CMakeFiles/opencv_stitching.dir/src/motion_estimators.cpp.obj
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/parvoretinafilter.cpp.obj
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/logpolar_bsm.cpp.obj
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/basicretinafilter.cpp.obj
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/chamfermatching.cpp.obj
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/chamfermatching.cpp: In member function ‘void cv::ChamferMatcher::Matching::computeDistanceTransform(cv::Mat&, cv::Mat&, cv::Mat&, float, float, float)’:
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/chamfermatching.cpp:969:30: error: the compiler can assume that the address of ‘annotate_img’ will never be NULL [-Werror=address]
if (&annotate_img!=NULL) {
^
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/chamfermatching.cpp:1016:34: error: the compiler can assume that the address of ‘annotate_img’ will never be NULL [-Werror=address]
if (&annotate_img!=NULL) {
^
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/chamfermatching.cpp: In member function ‘cv::ChamferMatcher::Match* cv::ChamferMatcher::Matching::localChamferDistance(cv::Point, cv::Mat&, cv::Mat&, cv::ChamferMatcher::Template*, float)’:
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/chamfermatching.cpp:1111:25: error: the compiler can assume that the address of ‘orientation_img’ will never be NULL [-Werror=address]
if (&orientation_img!=NULL) {
^
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/magnoretinafilter.cpp.obj
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/chamfermatching.cpp:1111:5: warning: nonnull argument ‘orientation_img’ compared to NULL [-Wnonnull-compare]
if (&orientation_img!=NULL) {
^~
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/chamfermatching.cpp: In member function ‘void cv::ChamferMatcher::Matching::computeDistanceTransform(cv::Mat&, cv::Mat&, cv::Mat&, float, float, float)’:
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/chamfermatching.cpp:1016:17: warning: nonnull argument ‘annotate_img’ compared to NULL [-Wnonnull-compare]
if (&annotate_img!=NULL) {
^~
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/chamfermatching.cpp:969:13: warning: nonnull argument ‘annotate_img’ compared to NULL [-Wnonnull-compare]
if (&annotate_img!=NULL) {
^~
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/retinafilter.cpp.obj
[ 99%] Building CXX object modules/contrib/CMakeFiles/opencv_contrib.dir/src/rgbdodometry.cpp.obj
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/rgbdodometry.cpp:65:47: fatal error: unsupported/Eigen/MatrixFunctions: 没有那个文件或目录
# include
^
compilation terminated.
make[2]: *** [modules/contrib/CMakeFiles/opencv_contrib.dir/src/rgbdodometry.cpp.obj] 错误 1
make[2]: *** 正在等待未完成的任务....
Linking CXX shared library ../../lib/libopencv_stitching.so
[ 99%] Built target opencv_stitching
Scanning dependencies of target opencv_perf_stitching
Scanning dependencies of target opencv_test_stitching
[ 99%] [ 99%] [ 99%] Building CXX object modules/stitching/CMakeFiles/opencv_test_stitching.dir/test/test_blenders.cpp.obj
Building CXX object modules/stitching/CMakeFiles/opencv_test_stitching.dir/test/test_main.cpp.obj
Building CXX object modules/stitching/CMakeFiles/opencv_perf_stitching.dir/perf/perf_stich.cpp.obj
In file included from /home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/flann/include/opencv2/flann/params.h:33:0,
from /home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/flann/include/opencv2/flann/flann_base.hpp:41,
from /home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/flann/include/opencv2/flann/flann.hpp:50,
from /home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/stitching/perf/perf_stich.cpp:4:
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/flann/include/opencv2/flann/any.h: In member function ‘virtual void cvflann::anyimpl::big_any_policy::static_delete(void**)’:
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/flann/include/opencv2/flann/any.h:83:9: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
if (* x) delete (* reinterpret_cast(x)); *x = NULL;
^~
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/flann/include/opencv2/flann/any.h:83:55: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the ‘if’
if (* x) delete (* reinterpret_cast(x)); *x = NULL;
^
cc1plus: some warnings being treated as errors
make[2]: *** [modules/contrib/CMakeFiles/opencv_contrib.dir/src/chamfermatching.cpp.obj] 错误 1
make[1]: *** [modules/contrib/CMakeFiles/opencv_contrib.dir/all] 错误 2
make[1]: *** 正在等待未完成的任务....
[ 99%] Building CXX object modules/stitching/CMakeFiles/opencv_pe
以下错误解决办法:
修改build/modules/contrib/CMakeFiles/opencv_contrib.dir/flags.make
删除 CXX_FLAGS 中的 -Werror=address
2.4.9/modules/contrib/src/chamfermatching.cpp:969:30: error: the compiler can assume that the address of ‘annotate_img’ will never be NULL [-Werror=address]
if (&annotate_img!=NULL) {
以下错误解决办法:
进入Eigen3库目录发现缺少unsupported目录,下载新的Eigen库并替换,因为Eigen库全部都是头文件,所以直接替换就好,不依赖具体的平台。
/home/rootroot/workspace/BAOLE_CLEAN_ROBOT/BL505/CORE-BOARD-PRO/WITHSRC/RK3326/lib/opencv-2.4.9/modules/contrib/src/rgbdo
step13
再次编译,编译成功。
step14
执行 make install 进行安装,安装完成后,可以将Install目录下的内容拷贝到RK3326板子上/usr目录下相关的目录中即可。
举报