添加opencv库遇到的编译问题

想要在rza2m_cam_and_disp_sample_freertos_gcc中添加opencv,已经添加了opencv的库和两个宏定义,编译出现错误,找到的错误信息如下图所示:

希望工程师能给予回复,非常感谢!

  • 截图太模糊看不清错误,你使用的编译器是什么版本
    另外请确认增加的两个预编译宏是在C++选项里面,不是Assembler选项里
  • 感谢工程师的回复,使用的编译器是下图上面的6.3.1.20170620

    添加的两个预编译宏是在C++选项里,错误的截图如下:

  • 你对比看一下控制台里面编译r_opencv.cpp时的那行输出,以下是我这边输出(我编译时把所有的warning选项去掉了,方便看错误输出):
    arm-none-eabi-gcc -mcpu=cortex-a9 -march=armv7-a -marm -mlittle-endian -mfloat-abi=hard -mfpu=neon -mno-unaligned-access -Og -ffunction-sections -fdata-sections -Wnull-dereference -Wmaybe-uninitialized -g3 -Wstack-usage=100 -D__MBED__ -DNO_ICONV -I"D:\Renesas\Product\10_RZ\RZA2\Applications\00_APN\r01an4494xx0800-rza2m-simple-apl-swpkg-gcc\rza2m_cam_and_disp_sample_freertos_gcc\src\FreeRTOS\include" -I"D:\Renesas\Product\10_RZ\RZA2\Applications\00_APN\r01an4494xx0800-rza2m-simple-apl-swpkg-gcc\rza2m_cam_and_disp_sample_freertos_gcc\src\FreeRTOS\include\private" -I"D:\Renesas\Product\10_RZ\RZA2\Applications\00_APN\r01an4494xx0800-rza2m-simple-apl-swpkg-gcc\rza2m_cam_and_disp_sample_freertos_gcc\src\FreeRTOS\portable\GCC\ARM_CA9_RZA2M" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/compiler/inc" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/configuration" -I"D:\Renesas\Product\10_RZ\RZA2\Applications\00_APN\r01an4494xx0800-rza2m-simple-apl-swpkg-gcc\rza2m_cam_and_disp_sample_freertos_gcc\src\config_files" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/system/inc" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/system/iodefine" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/src/renesas/application/inc" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/sc_drivers/r_scifa/inc" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/sc_drivers/r_riic/inc" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/sc_drivers/r_ostm/inc" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/sc_drivers/r_ceu/inc" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/sc_drivers/r_mipi/inc" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/sc_drivers/r_rvapi/inc" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/sc_drivers/r_vdc/inc" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/sc_drivers/r_cbuffer/inc" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/drivers/r_cache/inc" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/drivers/r_cpg/inc" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/drivers/r_gpio/inc" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/drivers/r_intc/inc" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/drivers/r_mmu/inc" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/drivers/r_stb/inc" -I"D:/Renesas/Product/10_RZ/RZA2/Applications/00_APN/r01an4494xx0800-rza2m-simple-apl-swpkg-gcc/rza2m_cam_and_disp_sample_freertos_gcc/generate/os_abstraction/inc" -I"D:\Renesas\e2_studio\workspace_nuedc\RZA2M_DRP_Benchmark_V1.0.0\mw\src\opencv_neon" -I"D:\Renesas\e2_studio\workspace_nuedc\RZA2M_DRP_Benchmark_V1.0.0\mw\src\opencv_neon\calib3d\include" -I"D:\Renesas\e2_studio\workspace_nuedc\RZA2M_DRP_Benchmark_V1.0.0\mw\src\opencv_neon\core\include" -I"D:\Renesas\e2_studio\workspace_nuedc\RZA2M_DRP_Benchmark_V1.0.0\mw\src\opencv_neon\features2d\include" -I"D:\Renesas\e2_studio\workspace_nuedc\RZA2M_DRP_Benchmark_V1.0.0\mw\src\opencv_neon\flann\include" -I"D:\Renesas\e2_studio\workspace_nuedc\RZA2M_DRP_Benchmark_V1.0.0\mw\src\opencv_neon\imgcodecs\include" -I"D:\Renesas\e2_studio\workspace_nuedc\RZA2M_DRP_Benchmark_V1.0.0\mw\src\opencv_neon\imgproc\include" -I"D:\Renesas\e2_studio\workspace_nuedc\RZA2M_DRP_Benchmark_V1.0.0\mw\src\opencv_neon\ml\include" -I"D:\Renesas\e2_studio\workspace_nuedc\RZA2M_DRP_Benchmark_V1.0.0\mw\src\opencv_neon\objdetect\include" -I"D:\Renesas\e2_studio\workspace_nuedc\RZA2M_DRP_Benchmark_V1.0.0\mw\src\opencv_neon\opencv_contrib\modules\face" -I"D:\Renesas\e2_studio\workspace_nuedc\RZA2M_DRP_Benchmark_V1.0.0\mw\src\opencv_neon\photo\include" -I"D:\Renesas\e2_studio\workspace_nuedc\RZA2M_DRP_Benchmark_V1.0.0\mw\src\opencv_neon\shape\include" -I"D:\Renesas\e2_studio\workspace_nuedc\RZA2M_DRP_Benchmark_V1.0.0\mw\src\opencv_neon\stitching\include" -I"D:\Renesas\e2_studio\workspace_nuedc\RZA2M_DRP_Benchmark_V1.0.0\mw\src\opencv_neon\superres\include" -I"D:\Renesas\e2_studio\workspace_nuedc\RZA2M_DRP_Benchmark_V1.0.0\mw\src\opencv_neon\video\include" -I"D:\Renesas\e2_studio\workspace_nuedc\RZA2M_DRP_Benchmark_V1.0.0\mw\src\opencv_neon\videostab\include" -fabi-version=0 -Wa,-adhlns="src/renesas/application/r_opencv.o.lst" -MMD -MP -MF"src/renesas/application/r_opencv.d" -MT"src/renesas/application/r_opencv.o" -c -o "src/renesas/application/r_opencv.o" "../src/renesas/application/r_opencv.cpp"