commit:     41a8354c8d6f7578eb84bae8d818d835a4122001
Author:     Joonas Niilola <juippis <AT> gentoo <DOT> org>
AuthorDate: Tue Jan 19 10:35:50 2021 +0000
Commit:     Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Tue Jan 19 10:37:42 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=41a8354c

x11-terms/terminology: fix python-exec[-native-symlinks]

Closes: https://bugs.gentoo.org/766081
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>

 x11-terms/terminology/terminology-1.9.0.ebuild | 19 +++++++++++++++++--
 1 file changed, 17 insertions(+), 2 deletions(-)

diff --git a/x11-terms/terminology/terminology-1.9.0.ebuild 
b/x11-terms/terminology/terminology-1.9.0.ebuild
index c855f868258..17d64492f40 100644
--- a/x11-terms/terminology/terminology-1.9.0.ebuild
+++ b/x11-terms/terminology/terminology-1.9.0.ebuild
@@ -3,7 +3,9 @@
 
 EAPI=7
 
-inherit meson xdg-utils
+PYTHON_COMPAT=( python3_{7,8,9} )
+
+inherit meson python-any-r1 xdg-utils
 
 DESCRIPTION="Feature rich terminal emulator using the Enlightenment Foundation 
Libraries"
 HOMEPAGE="https://www.enlightenment.org/about-terminology";
@@ -19,9 +21,22 @@ RDEPEND="|| ( dev-libs/efl[gles2-only] dev-libs/efl[opengl] )
        app-arch/lz4
        dev-libs/efl[eet,fontconfig]"
 DEPEND="${RDEPEND}"
-BDEPEND="virtual/pkgconfig
+BDEPEND="${PYTHON_DEPS}
+       virtual/pkgconfig
        nls? ( sys-devel/gettext )"
 
+pkg_setup() {
+       python-any-r1_pkg_setup
+}
+
+src_prepare() {
+       default
+
+       # Fix python shebangs for python-exec[-native-symlinks], #766081
+       local shebangs=($(grep -rl "#!/usr/bin/env python3" || die))
+       python_fix_shebang -q ${shebangs[*]}
+}
+
 src_configure() {
        local emesonargs=(
                $(meson_use nls)

Reply via email to