diff options
author | 2018-08-17 17:29:18 +0200 | |
---|---|---|
committer | 2018-08-18 07:10:58 +0100 | |
commit | b396186669ec607562148b9f5303565a5d01aa2b (patch) | |
tree | 10164b07bcbcd96c7f36d6d5ff299f4f0870724a /media-libs/opencv | |
parent | dev-perl/UNIVERSAL-can: Cleanup old version 1.201.401.240 (diff) | |
download | gentoo-b396186669ec607562148b9f5303565a5d01aa2b.tar.gz gentoo-b396186669ec607562148b9f5303565a5d01aa2b.tar.bz2 gentoo-b396186669ec607562148b9f5303565a5d01aa2b.zip |
media-libs/opencv: disable implied CPU flags
The OpenCV build system tries to be helpful by enabling unrequested CPU
flags based on requested ones. Unfortunately, this breaks the build on
AMD Piledriver because FMA3 implies AVX2 which is not available on this
architecture.
Further more, these CPU flags should only be handled by the
corresponding Portage flags, instead of CMake's hard-coded automagic.
This commit fixes that by disabling the whole "implication" mechanism
for CPU flags, while also undoing the previous attempt at solving the
problem by translating those broken "implications" into REQUIRED_USE.
Authored-by: Ștefan Talpalaru <stefantalpalaru@yahoo.com>
Bug: https://bugs.gentoo.org/656638
Diffstat (limited to 'media-libs/opencv')
-rw-r--r-- | media-libs/opencv/opencv-3.4.1-r4.ebuild (renamed from media-libs/opencv/opencv-3.4.1-r3.ebuild) | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/media-libs/opencv/opencv-3.4.1-r3.ebuild b/media-libs/opencv/opencv-3.4.1-r4.ebuild index 89dc5ebc8192..e2aeffdea2cd 100644 --- a/media-libs/opencv/opencv-3.4.1-r3.ebuild +++ b/media-libs/opencv/opencv-3.4.1-r4.ebuild @@ -41,16 +41,7 @@ REQUIRED_USE=" java? ( python ) opengl? ( || ( gtk qt5 ) ) python? ( ${PYTHON_REQUIRED_USE} ) - tesseract? ( contrib ) - cpu_flags_x86_avx2? ( cpu_flags_x86_avx cpu_flags_x86_fma3 ) - cpu_flags_x86_fma3? ( cpu_flags_x86_avx2 ) - cpu_flags_x86_avx? ( cpu_flags_x86_sse4_2 ) - cpu_flags_x86_sse4_2? ( cpu_flags_x86_sse4_1 cpu_flags_x86_popcnt ) - cpu_flags_x86_popcnt? ( cpu_flags_x86_sse4_1 ) - cpu_flags_x86_sse4_1? ( cpu_flags_x86_sse3 cpu_flags_x86_ssse3 ) - cpu_flags_x86_ssse3? ( cpu_flags_x86_sse3 ) - cpu_flags_x86_sse3? ( cpu_flags_x86_sse2 ) - cpu_flags_x86_sse2? ( cpu_flags_x86_sse )" + tesseract? ( contrib )" # The following logic is intrinsic in the build system, but we do not enforce # it on the useflags since this just blocks emerging pointlessly: @@ -413,6 +404,7 @@ multilib_src_configure() { # ================================================== # cpu flags, should solve 633900 #=================================================== + -DOPENCV_CPU_OPT_IMPLIES_IGNORE=ON -DCPU_DISPATCH= -DENABLE_SSE=$(usex cpu_flags_x86_sse) -DENABLE_SSE2=$(usex cpu_flags_x86_sse2) |