From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: 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 80F1113933E for ; Wed, 21 Jul 2021 16:37:30 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 7B041E09C9; Wed, 21 Jul 2021 16:37:25 +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 35263E09C3 for ; Wed, 21 Jul 2021 16:37:25 +0000 (UTC) From: Ulrich Mueller To: Florian Schmaus Cc: gentoo-dev@lists.gentoo.org Subject: Re: [gentoo-dev] [PATCH v2] xdg.eclass: add EAPI 8 support In-Reply-To: <20210721150849.175482-1-flow@gentoo.org> (Florian Schmaus's message of "Wed, 21 Jul 2021 17:08:49 +0200") References: <20210715111956.297120-1-flow@gentoo.org> <20210721150849.175482-1-flow@gentoo.org> Date: Wed, 21 Jul 2021 18:37:14 +0200 Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@lists.gentoo.org Reply-to: gentoo-dev@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" X-Archives-Salt: 5de2a401-c27e-4f4a-8552-717a927edd10 X-Archives-Hash: 98ea6f2741cf7a58da29c1fcc962c98e --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable >>>>> On Wed, 21 Jul 2021, Florian Schmaus wrote: =20 > case "${EAPI:-0}" in This could be simplified to ${EAPI} (and no quotation marks). > 4|5|6|7) > - EXPORT_FUNCTIONS src_prepare pkg_preinst pkg_postinst pkg_postrm > + # src_prepare is only exported in EAPI < 8. > + EXPORT_FUNCTIONS src_prepare > + ;& The ;& terminator is a new Bash feature and cannot be used in EAPIs older than 6. (Easy to fix: Simply move the following EXPORT_FUNCTIONS below the case block.) > + 8) > + EXPORT_FUNCTIONS pkg_preinst pkg_postinst pkg_postrm > ;; > *) die "EAPI=3D${EAPI} is not supported" ;; Please prepend "${ECLASS}: " to the die message. > esac =20 > # @FUNCTION: xdg_src_prepare > # @DESCRIPTION: > # Prepare sources to work with XDG standards. > +# Note that this function is only exported in EAPIs < 8. > xdg_src_prepare() { > xdg_environment_reset I wonder, should the function be defined in EAPI 8 then? It calls default, so presumably ebuilds would rather call xdg_environment_reset directly? Ulrich --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQFDBAEBCAAtFiEEtDnZ1O9xIP68rzDbUYgzUIhBXi4FAmD4TToPHHVsbUBnZW50 b28ub3JnAAoJEFGIM1CIQV4uYHEH/AyhScAT9yjtDq7+lotwaju8f41q68zZbBwP Go0Owage3zAonhlVONP2ePsB9I+/D6BwhHcA+FuznJdDvEgWBbXRzVXefDt36KUI DIT5RMVZ5T9Tw+eHqipBkROdUOKSuv0nkUzjhpO5p2oozqKLq2xVj6s26gNOVESx U2PS/oBm16w3JUAlZGg9Fy8BdHbte0nR5UV+GfXiGeC4ylyC1N3jiwuExdmTVHT7 gT0j1fQkasry1Ojz6tzw8r3klK+sw/g/D22374J9rTNDTgHikCVUyyPOHrV3j4vV T6PFAcE4reD2z6/MLHwW+MdYt2SFcea4KhyiC+1KmWtvY4OJIbk= =XMi6 -----END PGP SIGNATURE----- --=-=-=--