I changed in make.conf: PYTHON_SINGLE_TARGET="python3_8" to PYTHON_SINGLE_TARGET="python3_9" virtualbox was rebuilt after that. Then I changed in make.conf: PYTHON_TARGETS="python3_8 python3_9" to PYTHON_TARGETS="python3_9" ================================================================= Package Settings ================================================================= app-emulation/virtualbox-6.1.20-r1::gentoo was built with the following: USE="alsa java opengl opus pam pulseaudio python qt5 sdk udev vnc -debug -doc -dtrace -headless (-libressl) -lvm -pax_kernel -vboxwebsrv" ABI_X86="(64)" PYTHON_SINGLE_TARGET="python3_9 -python3_7 -python3_8" "[1] python3.9" was also set with eselect before depclean: >>> Calculating removal order... >>> These are the packages that would be unmerged: dev-lang/python selected: 3.8.9 protected: none omitted: 3.9.4 All selected packages: =dev-lang/python-3.8.9 >>> 'Selected' packages are slated for removal. >>> 'Protected' and 'omitted' packages will not be removed. Would you like to unmerge these packages? [Yes/No] >>> Waiting 5 seconds before starting... >>> (Control-C to abort)... >>> Unmerging in: 5 4 3 2 1 >>> Unmerging (1 of 1) dev-lang/python-3.8.9... Packages installed: 1340 Packages in world: 184 Packages in system: 43 Required packages: 1340 Number removed: 1 * GNU info directory index is up-to-date. !!! existing preserved libs: >>> package: dev-lang/python-3.8.9 * - /usr/lib64/libpython3.8.so.1.0 * used by /usr/lib64/virtualbox/VBoxPython3_8.so (app-emulation/virtualbox-6.1.20-r1) Use emerge @preserved-rebuild to rebuild packages using these libraries ls -l /usr/lib64/virtualbox/VBoxPython* -rwxr-x--- 1 root vboxusers 213616 26. Apr 04:09 /usr/lib64/virtualbox/VBoxPython3_8.so -rwxr-x--- 1 root vboxusers 213608 26. Apr 04:09 /usr/lib64/virtualbox/VBoxPython3_9.so -rwxr-x--- 1 root vboxusers 213616 26. Apr 04:09 /usr/lib64/virtualbox/VBoxPython.so VBoxPython.so and VBoxPython3_8.so have same size.
Maybe usage of python-single-r1 is wrong