* Fixing shebang in /usr/share/virt-manager/virt-clone. * The file has incompatible shebang: * file: /usr/share/virt-manager/virt-clone * current shebang: #!/usr/bin/env python3 * requested impl: python2.7 * ERROR: app-emulation/virt-manager-9999::gentoo failed (install phase): * python_fix_shebang: conversion of incompatible shebang requested * * Call stack: * ebuild.sh, line 124: Called src_install * environment, line 4605: Called python_fix_shebang '/var/tmp/portage/app-emulation/virt-manager-9999/image//usr/share/virt-manager/virt-clone' '/var/tmp/portage/app-emulation/virt-manager-9999/image//usr/share/virt-manager/virt-convert' '/var/tmp/portage/app-emulation/virt-manager-9999/image//usr/share/virt-manager/virt-install' '/var/tmp/portage/app-emulation/virt-manager-9999/image//usr/share/virt-manager/virt-manager' * environment, line 4122: Called die * The specific snippet of code: * die "${FUNCNAME}: conversion of incompatible shebang requested"; In virt-manager's upstream commit of ddba9c1702cfbb2e94ad23799b9c4a9f0e70809a the shebang turned from '#!/usr/bin/env python2' to '#!/usr/bin/env python3' (as a part of big python3 rewrite of the project). However, the ebuild still calls python_fix_shebang. This is the patch that fixes the problem: diff --git i/app-emulation/virt-manager/virt-manager-9999.ebuild w/app-emulation/virt-manager/virt-manager-9999.ebuild index a3b8ec6f354..b68e5a3b6ce 100644 --- i/app-emulation/virt-manager/virt-manager-9999.ebuild +++ w/app-emulation/virt-manager/virt-manager-9999.ebuild @@ -69,9 +69,6 @@ src_install() { local mydistutilsargs=( --no-update-icon-cache --no-compile-schemas ) distutils-r1_src_install - - python_fix_shebang \ - "${ED}"/usr/share/virt-manager/virt-{clone,convert,install,manager} } pkg_preinst() {
Jeroen, thanks for the cleanup but actually I think we shouldn't try to fix shebang at all not only for virt-clone. As can be seen in the patch, virt-convert, virt-install and virt-manager suffer from the same problem. But I don't care that much. I just wanted to point out that virt-clone is only a 1/4 of problem.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0e6753f646fc079ae499aaef034d1a7bdeb94467 commit 0e6753f646fc079ae499aaef034d1a7bdeb94467 Author: Michal Privoznik <mprivozn@redhat.com> AuthorDate: 2018-03-24 10:02:15 +0000 Commit: Matthias Maier <tamiko@gentoo.org> CommitDate: 2018-03-24 15:23:02 +0000 app-emulation/virt-manager-9999: Drop python2 support With upstream commit of bd891eb380cdf771f0296a39193614a10749088b virt-manager is strictly python3 only. Update the ebuild to follow this change. Closes: https://bugs.gentoo.org/650790 Closes: https://bugs.gentoo.org/647376 Signed-off-by: Michal Privoznik <mprivozn@redhat.com> Signed-off-by: Matthias Maier <tamiko@gentoo.org> app-emulation/virt-manager/virt-manager-9999.ebuild | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-)