diff --git a/modules/gapi/cmake/DownloadADE.cmake b/modules/gapi/cmake/DownloadADE.cmake index 3157436369..e22c4f1a32 100644 --- a/modules/gapi/cmake/DownloadADE.cmake +++ b/modules/gapi/cmake/DownloadADE.cmake @@ -24,6 +24,12 @@ add_library(ade STATIC ${OPENCV_3RDPARTY_EXCLUDE_FROM_ALL} ${ADE_include} ${ADE_sources} ) + +# https://github.com/opencv/ade/issues/32 +if(CV_CLANG AND CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang" AND NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS 13.1) + ocv_warnings_disable(CMAKE_CXX_FLAGS -Wdeprecated-copy) +endif() + target_include_directories(ade PUBLIC $) set_target_properties(ade PROPERTIES POSITION_INDEPENDENT_CODE True diff --git a/modules/ts/include/opencv2/ts.hpp b/modules/ts/include/opencv2/ts.hpp index 2e7a241d8e..eee0376a0e 100644 --- a/modules/ts/include/opencv2/ts.hpp +++ b/modules/ts/include/opencv2/ts.hpp @@ -123,6 +123,9 @@ //#pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wsuggest-override" #endif +#if defined(__OPENCV_BUILD) && defined(__APPLE__) && defined(__clang__) && ((__clang_major__*100 + __clang_minor__) >= 1301) +#pragma clang diagnostic ignored "-Wdeprecated-copy" +#endif #include "opencv2/ts/ts_gtest.h" #if defined(__OPENCV_BUILD) && defined(__GNUC__) && __GNUC__ >= 5 //#pragma GCC diagnostic pop