From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: <gentoo-commits+bounces-1282911-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 5BCCD1382C5 for <garchives@archives.gentoo.org>; Sun, 16 May 2021 19:13:44 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 8ECBDE0928; Sun, 16 May 2021 19:13:43 +0000 (UTC) Received: from smtp.gentoo.org (dev.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 3BF5FE0928 for <gentoo-commits@lists.gentoo.org>; Sun, 16 May 2021 19:13:43 +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 15EE3340FD0 for <gentoo-commits@lists.gentoo.org>; Sun, 16 May 2021 19:13:42 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id A0150796 for <gentoo-commits@lists.gentoo.org>; Sun, 16 May 2021 19:13:39 +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: <1621191962.9a4dec7285edc68d7dd2166abe798e8b3b8a354d.ulm@gentoo> Subject: [gentoo-commits] proj/pms:eapi-8 commit in: / X-VCS-Repository: proj/pms X-VCS-Files: eapi-differences.tex ebuild-functions.tex X-VCS-Directories: / X-VCS-Committer: ulm X-VCS-Committer-Name: Ulrich Müller X-VCS-Revision: 9a4dec7285edc68d7dd2166abe798e8b3b8a354d X-VCS-Branch: eapi-8 Date: Sun, 16 May 2021 19:13:39 +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-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 07856054-ecaf-42cd-b975-072b2449fe8f X-Archives-Hash: 980c6c13d1cc08e82f757f8f1cd9deb6 commit: 9a4dec7285edc68d7dd2166abe798e8b3b8a354d Author: Ulrich Müller <ulm <AT> gentoo <DOT> org> AuthorDate: Sun May 16 19:06:02 2021 +0000 Commit: Ulrich Müller <ulm <AT> gentoo <DOT> org> CommitDate: Sun May 16 19:06:02 2021 +0000 URL: https://gitweb.gentoo.org/proj/pms.git/commit/?id=9a4dec72 EAPI 8: Default src_prepare doesn't accept options in PATCHES Bug: https://bugs.gentoo.org/752486 Signed-off-by: Ulrich Müller <ulm <AT> gentoo.org> eapi-differences.tex | 3 ++- ebuild-functions.tex | 21 ++++++++++++++++++++- 2 files changed, 22 insertions(+), 2 deletions(-) diff --git a/eapi-differences.tex b/eapi-differences.tex index 559a686..ab0ee97 100644 --- a/eapi-differences.tex +++ b/eapi-differences.tex @@ -121,7 +121,7 @@ Use dependencies & \compactfeatureref{use-deps} & * & Yes & Yes & Yes & Yes \\ \t{src_prepare} style & \compactfeatureref{src-prepare} & - * & no-op & 6 & 6 & 6 \\ + * & no-op & 6 & 6 & 8 \\ \t{src_configure} & \compactfeatureref{src-configure} & * & Yes & Yes & Yes & Yes \\ @@ -536,6 +536,7 @@ EAPI 8 is EAPI 7 with the following changes: \item \t{dosym} can create relative paths, \featureref{dosym-relative}. \item \t{PROPERTIES}, \t{RESTRICT} accumulated across eclasses, \featureref{accumulate-vars}. \item \t{usev} supports an optional second argument, \featureref{usev}. +\item Different \t{src_prepare} implementation, \featureref{src-prepare-8}. \end{compactitem} \ChangeWhenAddingAnEAPI{8} diff --git a/ebuild-functions.tex b/ebuild-functions.tex index 108b8bc..c8e02db 100644 --- a/ebuild-functions.tex +++ b/ebuild-functions.tex @@ -144,6 +144,24 @@ src_prepare() { \end{verbatim} \end{listing} +\featurelabel{src-prepare-8} For EAPIs listed in table~\ref{tab:src-prepare-table} as using format +8, the default implementation used when the ebuild lacks the \t{src_prepare} function shall behave +as: + +\begin{listing}[H] +\caption{\t{src_prepare}, format~8} +\begin{verbatim} +src_prepare() { + if [[ $(declare -p PATCHES 2>/dev/null) == "declare -a"* ]]; then + [[ -n ${PATCHES[@]} ]] && eapply -- "${PATCHES[@]}" + else + [[ -n ${PATCHES} ]] && eapply -- ${PATCHES} + fi + eapply_user +} +\end{verbatim} +\end{listing} + For other EAPIs supporting \t{src_prepare}, the default implementation used when the ebuild lacks the \t{src_prepare} function is a no-op. @@ -158,7 +176,8 @@ the \t{src_prepare} function is a no-op. \midrule 0, 1 & No & Not applicable \\ 2, 3, 4, 5 & Yes & no-op \\ - 6, 7, 8 & Yes & 6 \\ + 6, 7 & Yes & 6 \\ + 8 & Yes & 8 \\ \bottomrule \end{tabular} \end{centertable}