>>>>> On Thu, 27 Jun 2024, Andrew Nowa Ammerlaan wrote: > On 27/06/2024 06:00, Ulrich Mueller wrote: >> AFAICS, no EAPI 6 ebuild inherits mount-boot, so EAPI 6 could be >> dropped? > Yes, might as well drop that now. Here's v2: > +# @FUNCTION: mount-boot_is_disabled > +# @INTERNAL > +# @DESCRIPTION: > +# Detect whether the current environment/build settings are such that > we do not > +# want to mess with any mounts. > +mount-boot_is_disabled() { > + # Since this eclass only deals with /boot, skip things when > EROOT is active. > + if [[ ${EROOT:-/} != / ]] ; then This could be simplified to [[ -n ${EROOT} ]], because EROOT is guaranteed not to end in a slash in EAPI 7 and later. (Sorry, I had missed this one in v1.) > + return 0 > + fi > + > + # If we're only building a package, then there's no need to check things. > + if [[ ${MERGE_TYPE} == buildonly ]] ; then > + return 0 > + fi > + > + # The user wants us to leave things be. > + if [[ -n ${DONT_MOUNT_BOOT} ]] ; then > + return 0 > + fi > + > + # OK, we want to handle things ourselves. > + return 1 > +}