Gentoo Archives: gentoo-dev

From: David Seifert <soap@g.o>
To: gentoo-dev@l.g.o
Cc: David Seifert <soap@g.o>
Subject: [gentoo-dev] [PATCH 07/41] docs.eclass: drop EAPI 6 support
Date: Sun, 25 Dec 2022 22:17:47
Message-Id: 20221225221552.8023-7-soap@gentoo.org
In Reply to: [gentoo-dev] [PATCH 01/41] ada.eclass: drop EAPI 6 support by David Seifert
1 Signed-off-by: David Seifert <soap@g.o>
2 ---
3 eclass/docs.eclass | 24 +++++++-----------------
4 1 file changed, 7 insertions(+), 17 deletions(-)
5
6 diff --git a/eclass/docs.eclass b/eclass/docs.eclass
7 index 5a63044a864..ed1558bc9a8 100644
8 --- a/eclass/docs.eclass
9 +++ b/eclass/docs.eclass
10 @@ -7,7 +7,7 @@
11 # @AUTHOR:
12 # Author: Andrew Ammerlaan <andrewammerlaan@g.o>
13 # Based on the work of: Michał Górny <mgorny@g.o>
14 -# @SUPPORTED_EAPIS: 6 7 8
15 +# @SUPPORTED_EAPIS: 7 8
16 # @BLURB: A simple eclass to build documentation.
17 # @DESCRIPTION:
18 # A simple eclass providing basic functions and variables to build
19 @@ -57,15 +57,9 @@
20 # ...
21 # @CODE
22
23 -case "${EAPI:-0}" in
24 - 0|1|2|3|4|5)
25 - die "Unsupported EAPI=${EAPI:-0} (too old) for ${ECLASS}"
26 - ;;
27 - 6|7|8)
28 - ;;
29 - *)
30 - die "Unsupported EAPI=${EAPI} (unknown) for ${ECLASS}"
31 - ;;
32 +case ${EAPI} in
33 + 7|8) ;;
34 + *) die "${ECLASS}: EAPI ${EAPI:-0} not supported" ;;
35 esac
36
37 # @ECLASS_VARIABLE: DOCS_BUILDER
38 @@ -152,7 +146,8 @@ esac
39 # will initialize a dummy git repository before compiling. A dependency
40 # on dev-vcs/git is automatically added.
41
42 -if [[ ! ${_DOCS} ]]; then
43 +if [[ ! ${_DOCS_ECLASS} ]]; then
44 +_DOCS_ECLASS=1
45
46 # For the python based DOCS_BUILDERS we need to inherit any python eclass
47 case ${DOCS_BUILDER} in
48 @@ -423,11 +418,7 @@ esac
49
50 [[ ${DOCS_INITIALIZE_GIT} ]] && DOCS_DEPEND+=" dev-vcs/git "
51
52 -if [[ ${EAPI} != 6 ]]; then
53 - BDEPEND+=" doc? ( ${DOCS_DEPEND} )"
54 -else
55 - DEPEND+=" doc? ( ${DOCS_DEPEND} )"
56 -fi
57 +BDEPEND+=" doc? ( ${DOCS_DEPEND} )"
58
59 # If this is a python package using distutils-r1
60 # then put the compile function in the specific
61 @@ -437,5 +428,4 @@ if [[ ${_DISTUTILS_R1} && ( ${DOCS_BUILDER}="mkdocs" || ${DOCS_BUILDER}="sphinx"
62 python_compile_all() { docs_compile; }
63 fi
64
65 -_DOCS=1
66 fi
67 --
68 2.39.0