1 |
Ühel kenal päeval, L, 21.05.2016 kell 11:19, kirjutas |
2 |
waltdnes@××××××××.org: |
3 |
> On Sat, May 21, 2016 at 09:41:28AM +0200, Micha?? Górny wrote |
4 |
> > 3. We remove LINGUAS from USE_EXPAND and stop using it. If ebuilds |
5 |
> > have |
6 |
> > a good reason to use flags for localization, we introduce a new, |
7 |
> > non-colliding USE_EXPAND for that. We also ask users to replace |
8 |
> > LINGUAS |
9 |
> > with the new flag in their make.conf files. LINGUAS gets the |
10 |
> > original |
11 |
> > upstream behavior back, and we eventually discourage it in favor of |
12 |
> > new |
13 |
> > INSTALL_MASK features (WiP) [2]. |
14 |
|
15 |
Short of making an exception to LINGUAS in the USE_EXPAND rules, I |
16 |
think this is the only way. |
17 |
|
18 |
> 5. An reversed variant of INSTALL_MASK in make.conf, e.g. |
19 |
> LOCALE_ALLOW="foo bar fubar" |
20 |
> |
21 |
> 6. Integrate localepurge into Portage, and run it post install |
22 |
> |
23 |
> There are some lazy programmers out there who *DO NOT* respect the |
24 |
> LINGUAS setting, and splatter files throughout /usr/share/locale/* |
25 |
> and |
26 |
> /usr/share/man/* regardless. That's the reason "localepurge" was |
27 |
> written in the first place. Any proposed solution should take that |
28 |
> problem into consideration, and handle it too. |
29 |
|
30 |
For both of these cases, I have to point out that e.g |
31 |
LINGUAS="en et pl" |
32 |
does not mean "keep only /usr/share/locale/{en,et,pl}/*", it means have |
33 |
support for only these languages. This means for example that *.desktop |
34 |
files will have translations in them only for those language. Same for |
35 |
dconf schema files. Same for many other things. MO Translation files |
36 |
and manuals aren't the only thing here, especially with intltool (and |
37 |
many of these intltool features are now part of gettext proper). |
38 |
In short, LINGUAS affects the content of files too, not only the |
39 |
existence of files. See any file in /usr/share/applications/ for |
40 |
example. |
41 |
I always put "en" as my first in LINGUAS, due to historical abuse of |
42 |
the first value there, I think e.g mplayer or vlc used to do this. |
43 |
LINGUAS is an unordered list, but some packages used to took the first |
44 |
value as meaning the default and switch the UI to that by default, |
45 |
instead of honoring LC_* variables. Another reason I put "en" there, is |
46 |
because of IUSE_EXPAND and packages that might not be natively english, |
47 |
but do have english translations (I think I've seen some french ones |
48 |
like that :D) |
49 |
|
50 |
|
51 |
And no, localepurge is not capable of stripping these translations out |
52 |
of existing files. To my knowledge at least. Though it could be |
53 |
improved to do so in some cases. |
54 |
|
55 |
|
56 |
Mart |