Gentoo Archives: gentoo-commits

From: "Ulrich Müller" <ulm@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/pms:eapi-7 commit in: /
Date: Sat, 24 Feb 2018 12:58:53
Message-Id: 1519476924.dde8b8b1253408be9181a58b4b08e6e0b3866487.ulm@gentoo
1 commit: dde8b8b1253408be9181a58b4b08e6e0b3866487
2 Author: James Le Cuirot <chewi <AT> gentoo <DOT> org>
3 AuthorDate: Sat Sep 23 20:53:59 2017 +0000
4 Commit: Ulrich Müller <ulm <AT> gentoo <DOT> org>
5 CommitDate: Sat Feb 24 12:55:24 2018 +0000
6 URL: https://gitweb.gentoo.org/proj/pms.git/commit/?id=dde8b8b1
7
8 EAPI 7 drops --host-root in favor of -b, -d, and -r
9
10 Bug: https://bugs.gentoo.org/317337
11
12 eapi-differences.tex | 8 +++++---
13 pkg-mgr-commands.tex | 30 ++++++++++++++++++++----------
14 2 files changed, 25 insertions(+), 13 deletions(-)
15
16 diff --git a/eapi-differences.tex b/eapi-differences.tex
17 index 989784c..df8ef98 100644
18 --- a/eapi-differences.tex
19 +++ b/eapi-differences.tex
20 @@ -215,8 +215,8 @@ Most utilities die & \compactfeatureref{die-on-failure} &
21 \t{einstall} & \compactfeatureref{banned-commands} &
22 Yes & Yes & Yes & Banned & Banned \\
23
24 -Option \t{-{}-host-root} & \compactfeatureref{host-root-option} &
25 - No & No & Yes & Yes & Yes \\
26 +Query command options & \compactfeatureref{pm-query-options} &
27 + None & None & \t{-{}-host-root} & \t{-{}-host-root} & \t{-b}, \t{-d}, \t{-r} \\
28
29 \t{die -n} & \compactfeatureref{nonfatal-die} &
30 No & No & No & Yes & Yes \\
31 @@ -381,7 +381,7 @@ EAPI 5 is EAPI 4 with the following changes:
32 \item \t{USE} is calculated differently, \featureref{profile-iuse-inject}.
33 \item \t{find} is guaranteed to be GNU, \featureref{gnu-find}.
34 \item \t{best_version} and \t{has_version} support the \t{-{}-host-root} option,
35 - \featureref{host-root-option}.
36 + \featureref{pm-query-options}.
37 \item \t{econf} adds \t{-{}-disable-silent-rules}, \featureref{econf-options}.
38 \item \t{doheader} and \t{newheader} support, \featureref{doheader}.
39 \item \t{new*} can read from standard input, \featureref{newfoo-stdin}.
40 @@ -435,6 +435,8 @@ EAPI 7 is EAPI 6 with the following changes:
41 \item \t{econf} adds \t{-{}-with-sysroot}, \featureref{econf-options}.
42 \item \t{BDEPEND}, \featureref{bdepend}.
43 \item \t{BROOT}, \featureref{broot}.
44 +\item \t{best_version} and \t{has_version} support \t{-b}, \t{-d} and \t{-r} options instead of
45 + \t{-{}-host-root}, \featureref{pm-query-options}.
46 \end{compactitem}
47
48 \ChangeWhenAddingAnEAPI{7}
49
50 diff --git a/pkg-mgr-commands.tex b/pkg-mgr-commands.tex
51 index 13eed79..e3c27f7 100644
52 --- a/pkg-mgr-commands.tex
53 +++ b/pkg-mgr-commands.tex
54 @@ -82,27 +82,37 @@ These commands are used to extract information about the system. Ebuilds must no
55 these commands in parallel with any other package manager command. Ebuilds must not run any of
56 these commands once the current phase function has returned.
57
58 -\featurelabel{host-root-option} In EAPIs listed in table~\ref{tab:foo-version-host-root-table} as
59 -supporting option \t{-{}-host-root}, this flag as the first argument will cause the query to apply
60 -to the host root instead of \t{ROOT}.
61 +\featurelabel{pm-query-options} In EAPIs listed in table~\ref{tab:pm-query-options} as supporting
62 +option \t{-{}-host-root}, this flag as the first argument will cause the query to apply to the
63 +host root. Otherwise, it applies to \t{ROOT}.
64 +
65 +In EAPIs listed in table~\ref{tab:pm-query-options} as supporting options \t{-b}, \t{-d} and \t{-r},
66 +these mutually exclusive flags as the first argument will cause the query to apply to locations
67 +targetted by \t{BDEPEND}, \t{DEPEND} and \t{RDEPEND}, respectively. When none of these options
68 +are given, \t{-r} is assumed.
69 +
70 \begin{description}
71 \item[has_version] Takes exactly one package dependency specification as an argument. Returns
72 - true if a package matching the specification is installed in \t{ROOT}, and false otherwise.
73 + true if a package matching the specification is installed, and false otherwise.
74 \item[best_version] Takes exactly one package dependency specification as an argument. If a
75 matching package is installed, prints the category, package name and version of the highest
76 matching version; otherwise, prints an empty string. The exit code is unspecified.
77 \end{description}
78
79 \ChangeWhenAddingAnEAPI{7}
80 -\begin{centertable}{EAPIs supporting \t{-{}-host-root} for \t{*_version} commands}
81 - \label{tab:foo-version-host-root-table}
82 - \begin{tabular}{ll}
83 +\begin{centertable}{Package manager query command options supported by EAPIs}
84 + \label{tab:pm-query-options}
85 + \begin{tabular}{lllll}
86 \toprule
87 \multicolumn{1}{c}{\textbf{EAPI}} &
88 - \multicolumn{1}{c}{\textbf{\t{*_version} supports \t{-{}-host-root}?}} \\
89 + \multicolumn{1}{c}{\textbf{\t{-{}-host-root}?}} &
90 + \multicolumn{1}{c}{\textbf{\t{-b}?}} &
91 + \multicolumn{1}{c}{\textbf{\t{-d}?}} &
92 + \multicolumn{1}{c}{\textbf{\t{-r}?}} \\
93 \midrule
94 - 0, 1, 2, 3, 4 & No \\
95 - 5, 6 & Yes \\
96 + 0, 1, 2, 3, 4 & No & No & No & No \\
97 + 5, 6 & Yes & No & No & No \\
98 + 7 & No & Yes & Yes & Yes \\
99 \bottomrule
100 \end{tabular}
101 \end{centertable}