From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 6F52515808B for ; Sun, 18 Feb 2024 13:23:46 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id AB08F2BC016; Sun, 18 Feb 2024 13:23:44 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 897FDE2B7D for ; Sun, 18 Feb 2024 13:23:44 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 9691334312E for ; Sun, 18 Feb 2024 13:23:43 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 2D75E1082 for ; Sun, 18 Feb 2024 13:23:42 +0000 (UTC) From: "Michał Górny" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Michał Górny" Message-ID: <1708262609.1082225d340c4ef7f12565f1722ea7ef7647dcfa.mgorny@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: eclass/ X-VCS-Repository: repo/gentoo X-VCS-Files: eclass/llvm.org.eclass X-VCS-Directories: eclass/ X-VCS-Committer: mgorny X-VCS-Committer-Name: Michał Górny X-VCS-Revision: 1082225d340c4ef7f12565f1722ea7ef7647dcfa X-VCS-Branch: master Date: Sun, 18 Feb 2024 13:23:42 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 28e11be3-37fe-4371-9c95-24d978e48f62 X-Archives-Hash: ab1de24fd51bac57d35ba3e792539078 commit: 1082225d340c4ef7f12565f1722ea7ef7647dcfa Author: Michał Górny gentoo org> AuthorDate: Sat Feb 17 19:30:25 2024 +0000 Commit: Michał Górny gentoo org> CommitDate: Sun Feb 18 13:23:29 2024 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1082225d llvm.org.eclass: Put manpage dist filename into global var Signed-off-by: Michał Górny gentoo.org> eclass/llvm.org.eclass | 48 ++++++++++++++++++++++-------------------------- 1 file changed, 22 insertions(+), 26 deletions(-) diff --git a/eclass/llvm.org.eclass b/eclass/llvm.org.eclass index ff10a4384789..ea704cf8fd94 100644 --- a/eclass/llvm.org.eclass +++ b/eclass/llvm.org.eclass @@ -268,14 +268,30 @@ llvm.org_set_globals() { fi if [[ ${LLVM_MANPAGES} ]]; then - IUSE+=" doc" + # @ECLASS_VARIABLE: LLVM_MANPAGE_DIST + # @OUTPUT_VARIABLE + # @DESCRIPTION: + # The filename of the prebuilt manpage tarball for this version. + LLVM_MANPAGE_DIST= + if [[ ${_LLVM_SOURCE_TYPE} == tar && ${PV} != *_rc* ]]; then + case ${PV} in + 14*|15*|16.0.[0-3]) + LLVM_MANPAGE_DIST="llvm-${PV}-manpages.tar.bz2" + ;; + 16*) + LLVM_MANPAGE_DIST="llvm-16.0.4-manpages.tar.bz2" + ;; + 17*) + LLVM_MANPAGE_DIST="llvm-17.0.1-manpages.tar.bz2" + ;; + esac + fi - # use pregenerated tarball if available - local manpage_dist=$(llvm_manpage_get_dist) - if [[ -n ${manpage_dist} ]]; then + IUSE+=" doc" + if [[ -n ${LLVM_MANPAGE_DIST} ]]; then SRC_URI+=" !doc? ( - https://dev.gentoo.org/~mgorny/dist/llvm/${manpage_dist} + https://dev.gentoo.org/~mgorny/dist/llvm/${LLVM_MANPAGE_DIST} ) " else @@ -436,32 +452,12 @@ get_lit_flags() { echo "-vv;-j;${LIT_JOBS:-$(makeopts_jobs)}" } -# @FUNCTION: llvm_manpage_get_dist -# @DESCRIPTION: -# Output the filename of the manpage dist for this version, -# if available. Otherwise returns without output. -llvm_manpage_get_dist() { - if [[ ${_LLVM_SOURCE_TYPE} == tar && ${PV} != *_rc* ]]; then - case ${PV} in - 14*|15*|16.0.[0-3]) - echo "llvm-${PV}-manpages.tar.bz2" - ;; - 16*) - echo "llvm-16.0.4-manpages.tar.bz2" - ;; - 17*) - echo "llvm-17.0.1-manpages.tar.bz2" - ;; - esac - fi -} - # @FUNCTION: llvm_are_manpages_built # @DESCRIPTION: # Return true (0) if manpages are going to be built from source, # false (1) if preinstalled manpages will be used. llvm_are_manpages_built() { - use doc || [[ -z $(llvm_manpage_get_dist) ]] + use doc || [[ -z ${LLVM_MANPAGE_DIST} ]] } # @FUNCTION: llvm_install_manpages