Gentoo Archives: gentoo-commits

From: "Michał Górny" <mgorny@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/pms:eapi-7 commit in: /
Date: Sun, 01 Oct 2017 07:11:55
Message-Id: 1506841900.9cf9fc132e3d7f4431ab3db43555bd5c123d692d.mgorny@gentoo
1 commit: 9cf9fc132e3d7f4431ab3db43555bd5c123d692d
2 Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
3 AuthorDate: Sun Oct 1 07:07:48 2017 +0000
4 Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
5 CommitDate: Sun Oct 1 07:11:40 2017 +0000
6 URL: https://gitweb.gentoo.org/proj/pms.git/commit/?id=9cf9fc13
7
8 [WIP] EAPI 7 forbids empty dependency groups.
9
10 [TODO: add label & update eapi-differences]
11
12 Bug: https://bugs.gentoo.org/632000
13
14 dependencies.tex | 31 +++++++++++++++++++++++++++++--
15 1 file changed, 29 insertions(+), 2 deletions(-)
16
17 diff --git a/dependencies.tex b/dependencies.tex
18 index dca4a21..0cad80e 100644
19 --- a/dependencies.tex
20 +++ b/dependencies.tex
21 @@ -208,6 +208,8 @@ In particular, note that whitespace is not optional.
22
23 In an all-of group, all of the child elements must be matched.
24
25 +The behavior for an empty group is defined in table~\ref{tab:depend-group-empty}.
26 +
27 \subsection{USE-conditional dependency specifications}
28
29 In a use-conditional group, if the associated use flag is enabled (or disabled if it has an
30 @@ -216,6 +218,8 @@ exclamation mark prefix), all of the child elements must be matched.
31 It is an error for a flag to be used if it is not included in \t{IUSE_EFFECTIVE} as described in
32 section~\ref{sec:use-iuse-handling}.
33
34 +The behavior for an empty group is defined in table~\ref{tab:depend-group-empty}.
35 +
36 \subsection{Any-of dependency specifications}
37
38 Any use-conditional group that is an immediate child of an any-of group, if not enabled (disabled
39 @@ -225,7 +229,7 @@ for match purposes.
40 In an any-of group, at least one immediate child element must be matched. A blocker is
41 considered to be matched if its associated package dependency specification is not matched.
42
43 -An empty any-of group counts as being matched.
44 +The behavior for an empty group is defined in table~\ref{tab:depend-group-empty}.
45
46 \subsection{Exactly-one-of dependency specifications}
47
48 @@ -235,7 +239,7 @@ exactly-one-of group for match purposes.
49
50 In an exactly-one-of group, exactly one immediate child element must be matched.
51
52 -An empty exactly-one-of group counts as being matched.
53 +The behavior for an empty group is defined in table~\ref{tab:depend-group-empty}.
54
55 \subsection{At-most-one-of dependency specifications}
56
57 @@ -245,6 +249,29 @@ at-most-one-of group for match purposes.
58
59 In an at-most-one-of group, at most one immediate child element must be matched.
60
61 +The behavior for an empty group is defined in table~\ref{tab:depend-group-empty}.
62 +
63 +\ChangeWhenAddingAnEAPI{7}
64 +\begin{centertable}{EAPI-specific empty group behavior}
65 + \label{tab:depend-group-empty}
66 + \begin{tabular}{llllll}
67 + \toprule
68 + \multicolumn{1}{c}{\textbf{EAPI}} &
69 + \multicolumn{5}{c}{\textbf{Empty group counts as…}} \\
70 + &
71 + \multicolumn{1}{c}{\textbf{all-of}} &
72 + \multicolumn{1}{c}{\textbf{use-conditional}} &
73 + \multicolumn{1}{c}{\textbf{any-of}} &
74 + \multicolumn{1}{c}{\textbf{exactly-one-of}} &
75 + \multicolumn{1}{c}{\textbf{at-most-one-of}} \\
76 + \midrule
77 + 0, 1, 2, 3, 4 & undefined & undefined & matched & matched & n/a \\
78 + 5, 6 & undefined & undefined & matched & matched & matched \\
79 + 7 & forbidden & forbidden & forbidden & forbidden & forbidden \\
80 + \bottomrule
81 + \end{tabular}
82 +\end{centertable}
83 +
84 \subsection{Package dependency specifications}
85
86 A package dependency can be in one of the following base formats. A package manager must warn or