1 |
On Wed, 11 Nov 2015 07:16:42 +0100 |
2 |
Patrick Lauer <patrick@g.o> wrote: |
3 |
|
4 |
> On 11/11/2015 03:51 AM, Mike Frysinger wrote: |
5 |
> > On 10 Nov 2015 18:53, Mike Frysinger wrote: |
6 |
> >> i randomly stumbled across an ebuild that was using ^^ to make a variable |
7 |
> >> uppercase. this is new to bash-4.0 and thus invalid for EAPI=[0-5]. only |
8 |
> >> the fresh EAPI=6 permits it since we bumped the min ver to bash-4.2. |
9 |
> > Arfrever highlights these are not even safe to use. bash is locale aware, |
10 |
> > so it'll apply LC_COLLATE rules when processing the ^/, casemods. while |
11 |
> > you can fix this with external programs ala: |
12 |
> > LC_COLLATE=C tr ... |
13 |
> > |
14 |
> > you can't do it with inline code like: |
15 |
> > LC_COLLATE=C SRC_URI=".../${PN^^}/..." |
16 |
> > |
17 |
> > you can if you do something like: |
18 |
> > SRC_URI=".../$(LC_COLLATE=C; echo "${PN^^}")/..." |
19 |
> > |
20 |
> This points out a class of problems we've hit in the past: locale-aware |
21 |
> things in ebuilds. |
22 |
> |
23 |
> Wouldn't it be 'easier' (fsov easy) to have portage use sane-default |
24 |
> locale settings, so that estonian or turkish users don't get hit by |
25 |
> weirdness in the [a-z] character class etc.? |
26 |
> |
27 |
> (And as a side-effect the build logs are always readable ;) ) |
28 |
|
29 |
Pretty much +1 here. Not saying we need to force full locale, but |
30 |
having sane LC_CTYPE and LC_COLLATE would make sense. PMS already |
31 |
forces it in a few places... we may as well force it globally. |
32 |
|
33 |
-- |
34 |
Best regards, |
35 |
Michał Górny |
36 |
<http://dev.gentoo.org/~mgorny/> |