commit:     0bd2e06d869142ffffb4a87e4dd8f0d5d5d46856
Author:     Mike Pagano <mpagano <AT> gentoo <DOT> org>
AuthorDate: Fri Feb 19 19:27:42 2021 +0000
Commit:     Mike Pagano <mpagano <AT> gentoo <DOT> org>
CommitDate: Fri Feb 19 19:27:42 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0bd2e06d

sys-kernel/linux-docs: Fix compilation issue due to /bin/sh

Closes: https://bugs.gentoo.org/771213
Package-Manager: Portage-3.0.13, Repoman-3.0.2
Signed-off-by: Mike Pagano <mpagano <AT> gentoo.org>

 sys-kernel/linux-docs/linux-docs-5.10.17.ebuild | 19 +++++++++++++++----
 1 file changed, 15 insertions(+), 4 deletions(-)

diff --git a/sys-kernel/linux-docs/linux-docs-5.10.17.ebuild 
b/sys-kernel/linux-docs/linux-docs-5.10.17.ebuild
index ae8acc49680..bd48e869dd8 100644
--- a/sys-kernel/linux-docs/linux-docs-5.10.17.ebuild
+++ b/sys-kernel/linux-docs/linux-docs-5.10.17.ebuild
@@ -2,7 +2,8 @@
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=7
-inherit toolchain-funcs
+PYTHON_COMPAT=( python3_{8,9} )
+inherit python-any-r1 toolchain-funcs
 
 MY_PV="$(ver_cut 1-2)"
 MY_P=linux-${MY_PV}
@@ -18,17 +19,27 @@ SLOT="0"
 KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~ppc ~ppc64 ~s390 ~sparc 
~x86"
 
 IUSE=""
-BDEPEND="media-libs/fontconfig"
-DEPEND="dev-python/sphinx"
+
+DEPEND=""
 RDEPEND=""
+BDEPEND="${PYTHON_DEPS}
+       dev-python/sphinx
+       dev-python/sphinx_rtd_theme
+       media-libs/fontconfig"
+
+src_prepare() {
+       default
+       # Fix the Python shebangs.
+       python_fix_shebang "${S}/Documentation/sphinx/"
+}
 
 src_compile() {
        local ARCH=$(tc-arch-kernel)
        unset KBUILD_OUTPUT
+       HTML_DOCS=( Documentation/output/. )
        emake htmldocs
 }
 
 src_install() {
-       HTML_DOCS=( Documentation/output/. )
        einstalldocs
 }

Reply via email to