GNOME Bugzilla – Bug 777933
opencv plugin build error using mingw
Last modified: 2018-11-03 14:04:02 UTC
Created attachment 344530 [details] [review] patch building with mingw for 64 bit windows produces these errors (works for 32 bit) CXX libgstopencv_1.0_la-gstopencvutils.lo <built-in>: error: redundant redeclaration of ‘unsigned int __builtin_ia32_crc32qi(unsigned int, unsigned char)’ in same scope [-Werror=redundant-decls] In file included from /usr/x86_64-w64-mingw32/include/opencv2/core/types_c.h:93:0, from /usr/x86_64-w64-mingw32/include/opencv2/core/core.hpp:46, from ../../../../gst-libs/gst/opencv/gstopencvutils.cpp:27: /usr/x86_64-w64-mingw32/include/intrin.h:59:23: note: previous declaration of ‘unsigned int __builtin_ia32_crc32qi(unsigned int, unsigned char)’ extern unsigned int __builtin_ia32_crc32qi (unsigned int, unsigned char); ^~~~~~~~~~~~~~~~~~~~~~ <built-in>: error: redundant redeclaration of ‘unsigned int __builtin_ia32_crc32hi(unsigned int, short unsigned int)’ in same scope [-Werror=redundant-decls] /usr/x86_64-w64-mingw32/include/intrin.h:60:23: note: previous declaration of ‘unsigned int __builtin_ia32_crc32hi(unsigned int, short unsigned int)’ extern unsigned int __builtin_ia32_crc32hi (unsigned int, unsigned short); ^~~~~~~~~~~~~~~~~~~~~~ <built-in>: error: redundant redeclaration of ‘unsigned int __builtin_ia32_crc32si(unsigned int, unsigned int)’ in same scope [-Werror=redundant-decls] /usr/x86_64-w64-mingw32/include/intrin.h:61:23: note: previous declaration of ‘unsigned int __builtin_ia32_crc32si(unsigned int, unsigned int)’ extern unsigned int __builtin_ia32_crc32si (unsigned int, unsigned int); ^~~~~~~~~~~~~~~~~~~~~~ opencv plugins was ported to cpp so use cpp header and not c
please note that this does not fix the compilation error that is caused by mingw/opencv headers
Review of attachment 344530 [details] [review]: ::: gst-libs/gst/opencv/gstopencvutils.cpp @@ +26,2 @@ #include "gstopencvutils.h" +#include <opencv2/core/core.hpp> You probably want to do the same elsewhere, e.g. ext/opencv/gstcvdilateerode.cpp and ext/opencv/gstmotioncells.h Also in meson.build and configure.ac
-- GitLab Migration Automatic Message -- This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/512.