From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: <gentoo-commits+bounces-1004268-garchives=archives.gentoo.org@lists.gentoo.org> Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 15C0B1382C5 for <garchives@archives.gentoo.org>; Sun, 18 Feb 2018 13:36:33 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 375DEE0CBC; Sun, 18 Feb 2018 13:36:25 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 0B4BFE0CBA for <gentoo-commits@lists.gentoo.org>; Sun, 18 Feb 2018 13:36:25 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 02DE0335C4E for <gentoo-commits@lists.gentoo.org>; Sun, 18 Feb 2018 13:36:24 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 03766243 for <gentoo-commits@lists.gentoo.org>; Sun, 18 Feb 2018 13:36:20 +0000 (UTC) From: "Ulrich Müller" <ulm@gentoo.org> To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Ulrich Müller" <ulm@gentoo.org> Message-ID: <1518960954.f162015a61954fc60e07453912b7a5136eb1ceac.ulm@gentoo> Subject: [gentoo-commits] proj/pms:eapi-7 commit in: / X-VCS-Repository: proj/pms X-VCS-Files: eapi-differences.tex pkg-mgr-commands.tex X-VCS-Directories: / X-VCS-Committer: ulm X-VCS-Committer-Name: Ulrich Müller X-VCS-Revision: f162015a61954fc60e07453912b7a5136eb1ceac X-VCS-Branch: eapi-7 Date: Sun, 18 Feb 2018 13:36:20 +0000 (UTC) Precedence: bulk List-Post: <mailto:gentoo-commits@lists.gentoo.org> List-Help: <mailto:gentoo-commits+help@lists.gentoo.org> List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org> List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org> List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org> X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 50efc3b6-f115-4050-a873-398646e3a43c X-Archives-Hash: 02f95e225ec1b7044046d3e1ca420609 commit: f162015a61954fc60e07453912b7a5136eb1ceac Author: Michał Górny <mgorny <AT> gentoo <DOT> org> AuthorDate: Fri Sep 29 14:33:22 2017 +0000 Commit: Ulrich Müller <ulm <AT> gentoo <DOT> org> CommitDate: Sun Feb 18 13:35:54 2018 +0000 URL: https://gitweb.gentoo.org/proj/pms.git/commit/?id=f162015a EAPI 7 allows die in subshell. Bug: https://bugs.gentoo.org/465008 eapi-differences.tex | 4 ++++ pkg-mgr-commands.tex | 25 ++++++++++++++++--------- 2 files changed, 20 insertions(+), 9 deletions(-) diff --git a/eapi-differences.tex b/eapi-differences.tex index 97ca9ad..ddf480e 100644 --- a/eapi-differences.tex +++ b/eapi-differences.tex @@ -245,6 +245,9 @@ Output commands use stdout & \compactfeatureref{output-no-stdout} & \t{die -n} & \compactfeatureref{nonfatal-die} & No & No & No & Yes & Yes \\ +\t{die} in subshell & \compactfeatureref{subshell-die} & + No & No & No & No & Yes \\ + \t{eapply} & \compactfeatureref{eapply} & No & No & No & Yes & Yes \\ @@ -469,6 +472,7 @@ EAPI 7 is EAPI 6 with the following changes: \item Sandbox path removal commands, \featureref{sandbox-rm}. \item Output commands no longer use stdout, \featureref{output-no-stdout}. \item \t{eqawarn}, \featureref{eqawarn}. +\item \t{die} is guaranteed to work in a subshell, \featureref{subshell-die}. \end{compactitem} \ChangeWhenAddingAnEAPI{7} diff --git a/pkg-mgr-commands.tex b/pkg-mgr-commands.tex index 9820340..91c19b6 100644 --- a/pkg-mgr-commands.tex +++ b/pkg-mgr-commands.tex @@ -27,7 +27,7 @@ The following commands affect this behaviour: implementations to account for calling directly in ebuild scope or through \t{xargs}. Explicit \t{die} or \t{assert} commands only respect \t{nonfatal} when called with the \t{-n} - option and in EAPIs supporting this option, see table~\ref{tab:nonfatal-die}. + option and in EAPIs supporting this option, see table~\ref{tab:die-properties}. \end{description} \ChangeWhenAddingAnEAPI{7} @@ -209,23 +209,30 @@ completing. Ebuilds must not run any of these commands once the current phase fu \item[die] \featurelabel{nonfatal-die} If called under the \t{nonfatal} command (as per section~\ref{sec:failure-behaviour}) and with \t{-n} as its first parameter, displays a failure message provided in its following argument and then returns a non-zero exit status. Only in - EAPIs listed in table~\ref{tab:nonfatal-die} as supporting option~\t{-n}. Otherwise, displays + EAPIs listed in table~\ref{tab:die-properties} as supporting option~\t{-n}. Otherwise, displays a failure message provided in its first and only argument, and then aborts the build process. - \t{die} is \e{not} guaranteed to work correctly if called from a subshell environment. + + \featurelabel{subshell-die} In EAPIs listed in table~\ref{tab:die-properties} as not providing + subshell support, \t{die} is \e{not} guaranteed to work correctly if called from a subshell + environment. \item[assert] Checks the value of the shell's pipe status variable, and if any component is non-zero (indicating failure), calls \t{die}, passing any parameters to it. \end{description} \ChangeWhenAddingAnEAPI{7} -\begin{centertable}{EAPIs supporting \t{-n} for \t{die} and \t{assert} commands} - \label{tab:nonfatal-die} - \begin{tabular}{ll} +\begin{centertable}{Properties of \t{die} and \t{assert} commands in EAPIs} + \label{tab:die-properties} + \begin{tabular}{lll} \toprule \multicolumn{1}{c}{\textbf{EAPI}} & - \multicolumn{1}{c}{\textbf{\t{die} and \t{assert} support \t{-n}?}} \\ + \multicolumn{2}{c}{\textbf{\t{die} and \t{assert}}} \\ + & + \multicolumn{1}{c}{\textbf{support \t{-n}?}} & + \multicolumn{1}{c}{\textbf{work in subshell?}} \\ \midrule - 0, 1, 2, 3, 4, 5 & No \\ - 6, 7 & Yes \\ + 0, 1, 2, 3, 4, 5 & No & No \\ + 6 & Yes & No \\ + 7 & Yes & Yes \\ \bottomrule \end{tabular} \end{centertable}