opencv: disable sse4.1 and sse4.2 on x86

Disable sse4.1 and sse4.2 on x86 to fix the below build failure [1].
 | ./opencv-4.5.5/git/modules/gapi/src/backends/fluid/gfluidcore_simd_sse41.hpp:387:47: error: '_mm_insert_epi64' was not declared in this scope; did you mean '_mm_insert_epi8'?
 387 | val_0 = _mm_unpacklo_epi8(_mm_insert_epi64(val_0, reinterpret_cast<const int64_t>(&tmp[4 * (chanNum * mapsx[x + 1] + 1)]), 0), zero);
 | ^~~~~~~~~~~~~~~~
 | _mm_insert_epi8

[1] https://github.com/opencv/opencv/issues/21597

Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
This commit is contained in:
Mingli Yu 2022-02-14 18:53:37 +08:00 committed by Khem Raj
parent 2cfaa70818
commit 3f26c46cbd

View File

@ -100,6 +100,9 @@ EXTRA_OECMAKE = "-DOPENCV_EXTRA_MODULES_PATH=${WORKDIR}/contrib/modules \
${@bb.utils.contains("TARGET_CC_ARCH", "-msse4.2", "-DENABLE_SSE=1 -DENABLE_SSE2=1 -DENABLE_SSE3=1 -DENABLE_SSSE3=1 -DENABLE_SSE41=1 -DENABLE_SSE42=1", "", d)} \
"
EXTRA_OECMAKE:append:x86 = " -DX86=ON"
# disable sse4.1 and sse4.2 to fix 32bit build failure
# https://github.com/opencv/opencv/issues/21597
EXTRA_OECMAKE:remove:x86 = " -DENABLE_SSE41=1 -DENABLE_SSE42=1"
PACKAGECONFIG ??= "gapi python3 eigen jpeg png tiff v4l libv4l gstreamer samples tbb gphoto2 \
${@bb.utils.contains("DISTRO_FEATURES", "x11", "gtk", "", d)} \