Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 788712 - media-libs/opencv-4.5.0 fails to re-install on no-multilib(?) (rm: cannot remove 'modules/python3': No such file or directory)
Summary: media-libs/opencv-4.5.0 fails to re-install on no-multilib(?) (rm: cannot rem...
Status: RESOLVED OBSOLETE
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal major (vote)
Assignee: Amy Liffey
URL:
Whiteboard:
Keywords: PullRequest
: 789315 (view as bug list)
Depends on: 788184
Blocks:
  Show dependency tree
 
Reported: 2021-05-07 10:39 UTC by MickKi
Modified: 2021-05-25 05:42 UTC (History)
6 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
opencv-4.5.0.log (opencv-4.5.0.log,791.32 KB, text/x-log)
2021-05-07 10:39 UTC, MickKi
Details

Note You need to log in before you can comment on or make changes to this bug.
Description MickKi 2021-05-07 10:39:01 UTC
Created attachment 706488 [details]
opencv-4.5.0.log

The ebuild fails to (re)install with "rm: cannot remove 'modules/python3': No such file or directory".

Last time it was installed successfully was in Jan 2021, but it now needs to be rebuilt due to dependencies (protobuf) and fails as per attached log.
Comment 1 MickKi 2021-05-07 10:39:47 UTC
# emerge --info opencv

Repositories:

gentoo
    location: /usr/portage
    sync-type: rsync
    sync-uri: rsync://rsync.uk.gentoo.org/gentoo-portage/
    priority: -1000
    sync-rsync-verify-jobs: 1
    sync-rsync-extra-opts: 
    sync-rsync-verify-metamanifest: yes
    sync-rsync-verify-max-age: 24

local
    location: /usr/local/portage
    masters: gentoo
    priority: 100

ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="@FREE AdobeFlash-11.x RAR"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt"

 openmp pam pcre png policykit qt5 readline seccomp semantic-desktop split-usr sse sse2 sse3 sse4_1 ssl ssse3 svg tcpd udev udisks unicode upower webp xattr zlib" ABI_X86="64" ADA_TARGET="gnat_2018" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="mmx mmxext sse sse2 sse3 sse4_1 ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="libinput" KERNEL="linux" L10N="en-GB" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-3 php7-4" POSTGRES_TARGETS="postgres10 postgres11" PYTHON_SINGLE_TARGET="python3_8" PYTHON_TARGETS="python3_8" RUBY_TARGETS="ruby26" USERLAND="GNU" VIDEO_CARDS="intel i965" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq proto steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CC, CPPFLAGS, CTARGET, CXX, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RUSTFLAGS

=================================================================
                        Package Settings
=================================================================

media-libs/opencv-4.5.0::gentoo was built with the following:
USE="eigen features2d ffmpeg opengl openmp png python qt5 webp -contrib (-contribcvv) -contribdnn -contribfreetype (-contribhdf) (-contribovis) (-contribsfm) (-contribxfeatures2d) (-cuda) -debug -dnnsamples -download -examples -gdal (-gflags) (-glog) -gphoto2 -gstreamer -gtk3 -ieee1394 -java -jpeg -jpeg2k -lapack -lto -opencl -opencvapps -openexr (-tesseract) -testprograms -threads -tiff -v4l -vaapi (-vtk) -xine" CPU_FLAGS_X86="sse sse2 sse3 sse4_1 ssse3 -avx -avx2 -avx512f -f16c -fma3 -popcnt -sse4_2" PYTHON_TARGETS="python3_8 -python3_7 -python3_9"
Comment 2 MickKi 2021-05-09 14:45:21 UTC
Until someone has time to look into a fix, I created a symlink as a workaround to allow me to continue:

# cd /var/tmp/portage/media-libs/opencv-4.5.0/work/opencv-4.5.0_build-abi_x86_64.amd64/modules
# ln -s .firstpass/python/python3 python3
# cd ..
# chown -Rv portage:portage modules

Which allowed it to complete the installation and remove whatever it wanted to remove, with minimal warnings:

-- Up-to-date: /var/tmp/portage/media-libs/opencv-4.5.0/image/usr/share/opencv4/lbpcascades/lbpcascade_frontalcatface.xml
-- Up-to-date: /var/tmp/portage/media-libs/opencv-4.5.0/image/usr/share/opencv4/lbpcascades/lbpcascade_frontalface.xml
-- Up-to-date: /var/tmp/portage/media-libs/opencv-4.5.0/image/usr/share/opencv4/lbpcascades/lbpcascade_frontalface_improved.xml
-- Up-to-date: /var/tmp/portage/media-libs/opencv-4.5.0/image/usr/share/opencv4/lbpcascades/lbpcascade_profileface.xml
-- Up-to-date: /var/tmp/portage/media-libs/opencv-4.5.0/image/usr/share/opencv4/lbpcascades/lbpcascade_silverware.xml
Can't list '/var/tmp/portage/media-libs/opencv-4.5.0/image//usr/lib/python3.8/site-packages'
Can't list '/var/tmp/portage/media-libs/opencv-4.5.0/image//usr/lib/python3.8/site-packages'
Can't list '/var/tmp/portage/media-libs/opencv-4.5.0/image//usr/lib/python3.8/site-packages'
>>> Completed installing media-libs/opencv-4.5.0 into /var/tmp/portage/media-libs/opencv-4.5.0/image

 * Final size of build directory: 243888 KiB (238.1 MiB)
 * Final size of installed tree:   35220 KiB ( 34.3 MiB)

strip: x86_64-pc-linux-gnu-strip --strip-unneeded -N __gentoo_check_ldflags__ -R .comment -R .GCC.command.line -R .note.gnu.gold-version
   /usr/lib64/libopencv_core.so.4.5.0
   /usr/lib64/libopencv_flann.so.4.5.0
   /usr/lib64/libopencv_imgproc.so.4.5.0
   /usr/lib64/libopencv_ml.so.4.5.0
   /usr/lib64/libopencv_photo.so.4.5.0
   /usr/lib64/libopencv_features2d.so.4.5.0
   /usr/lib64/libopencv_dnn.so.4.5.0
   /usr/lib64/libopencv_imgcodecs.so.4.5.0
   /usr/lib64/libopencv_videoio.so.4.5.0
   /usr/lib64/libopencv_calib3d.so.4.5.0
   /usr/lib64/libopencv_objdetect.so.4.5.0
   /usr/lib64/libopencv_highgui.so.4.5.0
   /usr/lib64/libopencv_stitching.so.4.5.0
   /usr/lib64/libopencv_video.so.4.5.0

>>> Installing (1 of 1) media-libs/opencv-4.5.0::gentoo
<<< !needed  sym /usr/lib64/libprotobuf.so.25
<<< !needed  obj /usr/lib64/libprotobuf.so.25.0.0
>>> Auto-cleaning packages...

>>> No outdated packages were found on your system.

 * GNU info directory index is up-to-date.
Comment 3 manu 2021-05-10 07:31:56 UTC
Same problem here
Comment 4 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2021-05-10 14:03:38 UTC
*** Bug 789315 has been marked as a duplicate of this bug. ***
Comment 5 Ross Charles C. 2021-05-10 22:15:30 UTC
Traceback (most recent call last):
  File "<string>", line 1, in <module>
ImportError: No module named numpy.distutils
-- Found PythonInterp: /var/tmp/portage/media-libs/opencv-4.5.0/temp/python3.8/bin/python (found suitable version "3.8.9", minimum required is "3.2") 
-- Found PythonLibs: /usr/lib64/libpython3.8.so (found suitable exact version "3.8.9") 
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/usr/lib/python3.8/site-packages/numpy/__init__.py", line 145, in <module>
    from . import core
  File "/usr/lib/python3.8/site-packages/numpy/core/__init__.py", line 22, in <module>
    from . import multiarray
  File "/usr/lib/python3.8/site-packages/numpy/core/multiarray.py", line 12, in <module>
    from . import overrides
  File "/usr/lib/python3.8/site-packages/numpy/core/overrides.py", line 7, in <module>
    from numpy.core._multiarray_umath import (
RuntimeError: NumPy was built with baseline optimizations: 
(SSE SSE2 SSE3 SSSE3 SSE41 POPCNT SSE42) but your machine doesn't support:
(POPCNT).

From the context, I conjecture that python module is not enabled during the configuration because of the error in detecting numpy.
Comment 6 Michal Plichta 2021-05-11 13:59:18 UTC
I have same problem with 4.5.0 and with 4.5.1
Comment 7 Krzysiek 2021-05-13 20:51:43 UTC
I have the same problem with opencv rebuilding.
Also the amdgpu-fan script for controlling GPU fan (https://github.com/chestm007/amdgpu-fan) has stopped working with similar error:

# amdgpu-fan
Traceback (most recent call last):
File "/usr/local/sbin/amdgpu-fan", line 33, in <module>
sys.exit(load_entry_point('amdgpu-fan==0.0.22.post1556022696', 'console_scripts', 'amdgpu-fan')())
File "/usr/local/sbin/amdgpu-fan", line 25, in importlib_load_entry_point
return next(matches).load()
File "/usr/lib/python3.8/importlib/metadata.py", line 77, in load
module = import_module(match.group('module'))
File "/usr/lib/python3.8/importlib/__init__.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
File "<frozen importlib._bootstrap>", line 991, in _find_and_load
File "<frozen importlib._bootstrap>", line 975, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 671, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 783, in exec_module
File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
File "/root/.local/lib/python3.8/site-packages/amdgpu_fan/controller.py", line 9, in <module>
from amdgpu_fan.lib.curve import Curve
File "/root/.local/lib/python3.8/site-packages/amdgpu_fan/lib/curve.py", line 1, in <module>
import numpy as np
File "/usr/lib/python3.8/site-packages/numpy/__init__.py", line 145, in <module>
from . import core
File "/usr/lib/python3.8/site-packages/numpy/core/__init__.py", line 22, in <module>
from . import multiarray
File "/usr/lib/python3.8/site-packages/numpy/core/multiarray.py", line 12, in <module>
from . import overrides
File "/usr/lib/python3.8/site-packages/numpy/core/overrides.py", line 7, in <module>
from numpy.core._multiarray_umath import (
RuntimeError: NumPy was built with baseline optimizations:
(SSE SSE2 SSE3 SSSE3 SSE41 POPCNT SSE42) but your machine doesn't support:
(POPCNT).


# lscpu
Architektura:                    x86_64
Tryb(y) pracy CPU:               32-bit, 64-bit
Kolejność bajtów:                Little Endian
Rozmiary adresów:                36 bits physical, 48 bits virtual
CPU:                             4
Lista aktywnych CPU:             0-3
Wątków na rdzeń:                 1
Rdzeni na gniazdo:               4
Gniazd:                          1
ID producenta:                   GenuineIntel
Rodzina CPU:                     6
Model:                           23
Nazwa modelu:                    Intel(R) Core(TM)2 Quad CPU    Q9650  @ 3.00GHz
Wersja:                          10
CPU MHz:                         2158.746
CPU max MHz:                     2997,0000
CPU min MHz:                     1998,0000
BogoMIPS:                        6010.86
Wirtualizacja:                   VT-x
Cache L1d:                       128 KiB
Cache L1i:                       128 KiB
Cache L2:                        12 MiB
Vulnerability Itlb multihit:     KVM: Mitigation: VMX disabled
Vulnerability L1tf:              Mitigation; PTE Inversion; VMX EPT disabled
Vulnerability Mds:               Vulnerable; SMT disabled
Vulnerability Meltdown:          Vulnerable
Vulnerability Spec store bypass: Vulnerable
Vulnerability Spectre v1:        Vulnerable: __user pointer sanitization and usercopy barriers only; no swapgs ba
rriers
Vulnerability Spectre v2:        Vulnerable, STIBP: disabled
Vulnerability Srbds:             Not affected
Vulnerability Tsx async abort:   Not affected
Flagi:                           fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush
dts acpi mmx fxsr sse sse2 ht tm pbe syscall nx lm constant_tsc arch_perfmon pebs bts rep_good nopl cpuid aperfmperf pni dtes64 monitor ds_cpl vmx smx est tm2 ssse3 cx16 xtpr pdcm sse4_1 xsave lahf_lm tpr_shadow vnmi flexpriority vpid dtherm


# emerge --info opencv numpy
Portage 3.0.18 (python 3.8.9-final-0, default/linux/amd64/17.1/desktop/plasma, gcc-10.2.0, glibc-2.32-r7, 5.10.27-gentoo x86_64)
=================================================================
System Settings
=================================================================
System uname: Linux-5.10.27-gentoo-x86_64-Intel-R-_Core-TM-2_Quad_CPU_Q9650_@_3.00GHz-with-glibc2.2.5
KiB Mem:     8158616 total,   3712360 free
KiB Swap:   18785332 total,  16338928 free
Timestamp of repository gentoo: Sat, 08 May 2021 05:15:01 +0000
Head commit of repository gentoo: e49ac3859ed745c80ba5e31be5395de6508f226d
sh bash 5.0_p18
ld GNU ld (Gentoo 2.35.2 p1) 2.35.2
app-shells/bash:          5.0_p18::gentoo
dev-java/java-config:     2.3.1::gentoo
dev-lang/perl:            5.30.3::gentoo
dev-lang/python:          2.7.18_p9::gentoo, 3.7.10_p3::gentoo, 3.8.9_p2::gentoo, 3.9.4_p1::gentoo
dev-lang/rust:            1.51.0-r2::gentoo
dev-util/cmake:           3.18.5::gentoo
dev-util/pkgconfig:       0.29.2::gentoo
sys-apps/baselayout:      2.7::gentoo
sys-apps/openrc:          0.42.1-r1::gentoo
sys-apps/sandbox:         2.22::gentoo
sys-devel/autoconf:       2.13-r1::gentoo, 2.69-r5::gentoo
sys-devel/automake:       1.13.4-r2::gentoo, 1.16.2-r1::gentoo
sys-devel/binutils:       2.35.2::gentoo
sys-devel/gcc:            10.2.0-r5::gentoo
sys-devel/gcc-config:     2.4::gentoo
sys-devel/libtool:        2.4.6-r6::gentoo
sys-devel/make:           4.3::gentoo
sys-kernel/linux-headers: 5.10::gentoo (virtual/os-headers)
sys-libs/glibc:           2.32-r7::gentoo
Repositories:

gentoo
location: /usr/portage
sync-type: rsync
sync-uri: rsync://rsync.pl.gentoo.org/gentoo-portage
priority: -1000
sync-rsync-verify-metamanifest: yes
sync-rsync-extra-opts: 
sync-rsync-verify-jobs: 1
sync-rsync-verify-max-age: 24

local_overlay
location: /usr/local/portage
masters: gentoo
priority: 0

pentoo
location: /var/lib/layman/pentoo
masters: gentoo
priority: 50

steam-overlay
location: /var/lib/layman/steam-overlay
masters: gentoo
priority: 50

torbrowser
location: /var/lib/layman/torbrowser
masters: gentoo
priority: 50

ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/lib64/libreoffice/program/sofficerc /usr/share/config /usr/share/easy-rsa /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php7.3/ext-active/ /etc/php/apache2-php7.4/ext-active/ /etc/php/cgi-php7.3/ext-active/ /etc/php/cgi-php7.4/ext-active/ /etc/php/cli-php7.3/ext-active/ /etc/php/cli-php7.4/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-march=native -O2 -pipe -floop-interchange -floop-strip-mine -floop-block -w"
DISTDIR="/usr/portage/distfiles"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITYXDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="ftp://ftp.vectranet.pl/gentoo/"
LANG="pl_PL.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LINGUAS="pl"
MAKEOPTS="-j4"
PKGDIR="/usr/portage/packages"
PORTAGE_BZIP2_COMMAND="lbzip2"
PORTAGE_COMPRESS="lbzip2"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
USE="7zip X a52 aac aalib acl acpi activities aio akonadi alsa amd64 amr amrnb amrwb ao ares aspell audiofile avi bash-completion beagle berkdb branding bzip2 bzlib cairo caps cdda cddb cdinstall cdio cdr clang cli crypt cups curl dbus declarative dga dirac directfb djvu dri dts dvd dvdr egl elogind emboss encode exif expat fbcon ffmpeg fftw flac fltk fortran ftp fuse gd gdbm gif gimp glib glitz gmp gnutls gpm gs gui hyperestraier iconv icu id3tag idn ieee1394 imagemagick imlib inotify ithreads jabber jack java java6 jbig jemalloc jpeg jpeg2k kde kipi kwallet ladcca ladspa lame lapack lcms libcaca libglvnd libnotify libsamplerate libtirpc live lm_sensors logrotate lto lzma lzo mad mbox md5sum mmap mmx mmxext mng modplug module mono mp3 mp4 mpeg mpi mplayer mtp multilib musepack musicbrainz mysql ncurses network networkmanager nls nptlnsplugin ogg openal openexr opengl openmp pam pango pcre pdf pgo phonon pic plasma png policykit postscript ppds projectm pulseaudio qml qt5quicktime rdesktop readline rtmp scanner schroedinger sdl seccomp semantic-desktop slang smp sndfile sound sox speex spell split-usr sse sse2 sse3 sse4 ssl ssse3 startup-notification svg syslog system-sqlite taglib tcpd tetex theora threads thumbnail tiff tk truetype udev udisks unicode upnp upower urandom usb utempter v4l vaapi vcd vdpau vim-syntax vlc vorbis vpx vulkan wavpack webkit widgets wmf wxwidgets x264 xattr xcb xcomposite xine xml xosd xpm xprint xscreensaver xv xvid xvmc zip zlib" ABI_X86="64 32" ADA_TARGET="gnat_2018" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon sheets words" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="mmx mmxext sse sse2 sse3 sse4_1 ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="libinput evdev" KERNEL="linux" L10N="pl" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="pdfimport" LLVM_TARGETS="X86 AMDGPU" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-3" POSTGRES_TARGETS="postgres10 postgres11" PYTHON_SINGLE_TARGET="python3_8" PYTHON_TARGETS="python3_8" QEMU_SOFTMMU_TARGETS="i386 x86_64" QEMU_USER_TARGETS="i386 x86_64" RUBY_TARGETS="ruby25 ruby26" SANE_BACKENDS="*-" USERLAND="GNU" VIDEO_CARDS="amdgpu radeonsi fbdev" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq proto steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CC, CPPFLAGS, CTARGET, CXX, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RUSTFLAGS

=================================================================
Package Settings
=================================================================

media-libs/opencv-4.5.0::gentoo was built with the following:
USE="contrib contribdnn download eigen features2d ffmpeg gdal gphoto2 gstreamer ieee1394 java jpeg jpeg2k lapack lto opencl opencvapps openexr opengl openmp png python qt5 threads tiff v4l vaapi xine (-contribcvv) -contribfreetype (-contribhdf) (-contribovis) (-contribsfm) (-contribxfeatures2d) (-cuda) -debug -dnnsamples -examples (-gflags) (-glog) -gtk3 (-tesseract) -testprograms (-vtk) -webp" ABI_X86="32 (64) (-x32)" CPU_FLAGS_X86="sse sse2 sse3 sse4_1 ssse3 -avx -avx2 -avx512f -f16c -fma3 -popcnt -sse4_2" PYTHON_TARGETS="python3_8 -python3_7 -python3_9"

dev-python/numpy-1.20.2::gentoo was built with the following:
USE="lapack -doc -test" ABI_X86="(64)" PYTHON_TARGETS="python3_7 python3_8 -python3_9"
CFLAGS="-march=native -O2 -pipe -floop-interchange -floop-strip-mine -floop-block -w -fno-strict-aliasing"
CXXFLAGS="-march=native -O2 -pipe -floop-interchange -floop-strip-mine -floop-block -w -fno-strict-aliasing"
FEATURES="unmerge-logs distlocks userpriv ebuild-locks usersync ipc-sandbox unknown-features-warn preserve-libs parallel-fetch binpkg-dostripxattr usersandbox fixlafiles config-protect-if-modified userfetch sandbox unmerge-orphans binpkg-docompress pid-sandbox news strict protect-owned binpkg-logs sfperms network-sandbox qa-unresolved-soname-deps multilib-strict assume-digests merge-sync"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -shared"
Comment 8 Alexander Koryushkin 2021-05-25 05:39:42 UTC
Same problem. Not only with opencv. 
scipy, pandas also fails.
Comment 9 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2021-05-25 05:42:26 UTC
(In reply to Alexander Koryushkin from comment #8)
> Same problem. Not only with opencv. 
> scipy, pandas also fails.

Please verify this with the latest ~arch Boost and boost-build.