From e5772aa46e02f2560985fb19e9795018ca6643d5 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Micha=C5=82=20G=C3=B3rny?= Date: Sat, 21 Dec 2019 09:12:27 +0100 Subject: [PATCH] sys-devel/clang: Support pregenerated manpages MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Michał Górny --- sys-devel/clang/clang-9.0.1.ebuild | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/sys-devel/clang/clang-9.0.1.ebuild b/sys-devel/clang/clang-9.0.1.ebuild index 8636b7166174..926c06a7ee9c 100644 --- a/sys-devel/clang/clang-9.0.1.ebuild +++ b/sys-devel/clang/clang-9.0.1.ebuild @@ -7,8 +7,11 @@ PYTHON_COMPAT=( python{2_7,3_{5,6,7}} ) inherit cmake-utils llvm llvm.org multilib-minimal multiprocessing \ pax-utils python-single-r1 toolchain-funcs +MANPAGE_P=llvm-9.0.0-manpages DESCRIPTION="C language family frontend for LLVM" HOMEPAGE="https://llvm.org/" +SRC_URI=" + !doc? ( https://dev.gentoo.org/~mgorny/dist/llvm/${MANPAGE_P}.tar.bz2 )" LLVM_COMPONENTS=( clang clang-tools-extra ) LLVM_TEST_COMPONENTS=( llvm/lib/Testing/Support @@ -80,6 +83,12 @@ src_unpack() { cd x/y || die llvm.org_src_unpack mv clang-tools-extra clang/tools/extra || die + + if ! use doc; then + ebegin "Unpacking ${MANPAGE_P}.tar.bz2" + tar -xf "${DISTDIR}/${MANPAGE_P}.tar.bz2" || die + eend + fi } multilib_src_configure() { @@ -243,6 +252,12 @@ multilib_src_install_all() { python_optimize "${ED}"/usr/lib/llvm/${SLOT}/share/scan-view fi + # install pre-generated manpages + if ! use doc; then + insinto "/usr/lib/llvm/${SLOT}/share/man/man1" + doins "${WORKDIR}/x/y/${MANPAGE_P}/clang"/*.1 + fi + docompress "/usr/lib/llvm/${SLOT}/share/man" # match 'html' non-compression use doc && docompress -x "/usr/share/doc/${PF}/tools-extra" -- 2.26.2