Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-14 Thread Ulrich Mueller
> On Fri, 13 Nov 2015, Michał Górny wrote: > Ok, I recalled the issue I was particularly concerned about. > PV="1_beta2" > MY_PV="${PV/_/~}" > This triggers different behavior between bash<=4.2 and bash>=4.3, > with the latter requiring: > PV="1_beta2" > MY_PV="${PV/_/\~}" >

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-13 Thread Ulrich Mueller
> On Thu, 12 Nov 2015, Zac Medico wrote: > On 11/12/2015 04:06 PM, Mike Frysinger wrote: >> from ebuilds/eclasses that have already stopped using __: >> __do_sed_fix () >> ___ECLASS_RECUR_MULTILIB=yes >> ___ECLASS_RECUR_TOOLCHAIN_FUNCS=yes >> __versionator_shopt_toggle () >>

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-13 Thread Zac Medico
On 11/13/2015 12:12 AM, Ulrich Mueller wrote: >> On Thu, 12 Nov 2015, Zac Medico wrote: > >> On 11/12/2015 04:06 PM, Mike Frysinger wrote: >>> from ebuilds/eclasses that have already stopped using __: >>> __do_sed_fix () >>> ___ECLASS_RECUR_MULTILIB=yes >>> ___ECLASS_RECUR_TOOLCHAIN_FUNCS=yes

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-13 Thread Michał Górny
On Wed, 11 Nov 2015 12:52:05 +0100 Ulrich Mueller wrote: > > On Wed, 11 Nov 2015, Michał Górny wrote: > > > I'm not convinced we ought to do this for EAPI < 6. It is a breaking > > change after all, and as such changes the behavior of EAPI < 6 > > ebuilds. > > Which

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-12 Thread Mike Frysinger
On 12 Nov 2015 16:58, Zac Medico wrote: > On 11/12/2015 04:06 PM, Mike Frysinger wrote: > > from ebuilds/eclasses that have already stopped using __: > > __do_sed_fix () > > ___ECLASS_RECUR_MULTILIB=yes > > ___ECLASS_RECUR_TOOLCHAIN_FUNCS=yes > > __versionator_shopt_toggle () > >

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-12 Thread Mike Frysinger
On 12 Nov 2015 21:07, Tim Harder wrote: > On 2015-11-11 14:42, Zac Medico wrote: > > Please unset all new internal function inside bin/save-ebuild-env.sh. > > Note that it already uses this line to unset functions beginning with > > ___eapi: > > > >unset -f $(compgen -A function ___eapi_) > >

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-12 Thread Tim Harder
On 2015-11-11 14:42, Zac Medico wrote: > Please unset all new internal function inside bin/save-ebuild-env.sh. > Note that it already uses this line to unset functions beginning with > ___eapi: >unset -f $(compgen -A function ___eapi_) > However, your __eapi functions will not be matched

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-12 Thread Zac Medico
On 11/12/2015 06:07 PM, Tim Harder wrote: > On 2015-11-11 14:42, Zac Medico wrote: >> Please unset all new internal function inside bin/save-ebuild-env.sh. >> Note that it already uses this line to unset functions beginning with >> ___eapi: > >>unset -f $(compgen -A function ___eapi_) > >>

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-12 Thread Tim Harder
On 2015-11-12 21:25, Zac Medico wrote: > > Just to note another approach, pkgcore generates global and per-eapi > > function lists at install time (or uses the generation scripts when > > running from a checkout) so manually tracking lists of functions isn't > > required. > That seems like a

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-12 Thread Zac Medico
On 11/12/2015 06:33 PM, Tim Harder wrote: > On 2015-11-12 21:25, Zac Medico wrote: >>> Just to note another approach, pkgcore generates global and per-eapi >>> function lists at install time (or uses the generation scripts when >>> running from a checkout) so manually tracking lists of functions

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-11 Thread Mike Frysinger
On 11 Nov 2015 10:32, Michał Górny wrote: > I'm not convinced we ought to do this for EAPI < 6. It is a breaking > change after all, and as such changes the behavior of EAPI < 6 ebuilds. that is a false statement. anything not working with bash-3.2 is already broken according to the PMS. >

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-11 Thread Mike Frysinger
On 11 Nov 2015 07:33, Ulrich Mueller wrote: > > On Tue, 10 Nov 2015, Mike Frysinger wrote: > > + # Set the compat level in case things change with newer ones. We must > > not > > + # export this into the env otherwise we might break other shell > > scripts we > > + # execute (e.g.

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-11 Thread Michał Górny
On Tue, 10 Nov 2015 23:39:29 -0500 Mike Frysinger wrote: > To try and provide better stability across bash versions, > set the language compat level based on the current EAPI. > --- > bin/eapi.sh | 8 > bin/ebuild.sh | 39 +++ >

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-11 Thread Ulrich Mueller
> On Wed, 11 Nov 2015, Michał Górny wrote: > I'm not convinced we ought to do this for EAPI < 6. It is a breaking > change after all, and as such changes the behavior of EAPI < 6 > ebuilds. Which according to PMS should assume bash version 3.2. Also, AFAICS the only feature where the compat

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-11 Thread Zac Medico
On 11/11/2015 01:11 PM, Mike Frysinger wrote: > On 11 Nov 2015 13:04, Zac Medico wrote: >> On 11/11/2015 12:55 PM, Mike Frysinger wrote: >>> On 11 Nov 2015 11:42, Zac Medico wrote: On 11/10/2015 08:39 PM, Mike Frysinger wrote: > +# Set up the bash version compatibility level. >

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-11 Thread Zac Medico
On 11/11/2015 10:33 PM, Zac Medico wrote: > On 11/11/2015 01:11 PM, Mike Frysinger wrote: >> On 11 Nov 2015 13:04, Zac Medico wrote: >>> On 11/11/2015 12:55 PM, Mike Frysinger wrote: On 11 Nov 2015 11:42, Zac Medico wrote: > On 11/10/2015 08:39 PM, Mike Frysinger wrote: >> +# Set up

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-11 Thread Zac Medico
On 11/10/2015 08:39 PM, Mike Frysinger wrote: > To try and provide better stability across bash versions, > set the language compat level based on the current EAPI. > --- > bin/eapi.sh | 8 > bin/ebuild.sh | 39 +++ > 2 files changed, 47

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-11 Thread Mike Frysinger
On 11 Nov 2015 13:04, Zac Medico wrote: > On 11/11/2015 12:55 PM, Mike Frysinger wrote: > > On 11 Nov 2015 11:42, Zac Medico wrote: > >> On 11/10/2015 08:39 PM, Mike Frysinger wrote: > >>> +# Set up the bash version compatibility level. > >>> +__check_bash_version() { > >> > >> Please unset all

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-11 Thread Mike Frysinger
On 11 Nov 2015 11:42, Zac Medico wrote: > On 11/10/2015 08:39 PM, Mike Frysinger wrote: > > +# Set up the bash version compatibility level. > > +__check_bash_version() { > > Please unset all new internal function inside bin/save-ebuild-env.sh. > Note that it already uses this line to unset

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-11 Thread Zac Medico
On 11/11/2015 12:55 PM, Mike Frysinger wrote: > On 11 Nov 2015 11:42, Zac Medico wrote: >> On 11/10/2015 08:39 PM, Mike Frysinger wrote: >>> +# Set up the bash version compatibility level. >>> +__check_bash_version() { >> >> Please unset all new internal function inside bin/save-ebuild-env.sh. >>

Re: [gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-10 Thread Ulrich Mueller
> On Tue, 10 Nov 2015, Mike Frysinger wrote: > + # Set the compat level in case things change with newer ones. We must > not > + # export this into the env otherwise we might break other shell > scripts we > + # execute (e.g. ones in /usr/bin). > +

[gentoo-portage-dev] [PATCH] ebuild: set up bash compat levels

2015-11-10 Thread Mike Frysinger
To try and provide better stability across bash versions, set the language compat level based on the current EAPI. --- bin/eapi.sh | 8 bin/ebuild.sh | 39 +++ 2 files changed, 47 insertions(+) diff --git a/bin/eapi.sh b/bin/eapi.sh index