Gentoo Archives: gentoo-dev

From: "Michał Górny" <mgorny@g.o>
To: gentoo-dev@l.g.o, Martin Vaeth <martin@×××××.de>
Subject: Re: [gentoo-dev] Re: [RFC] Masterplan for solving LINGUAS problems
Date: Wed, 01 Jun 2016 13:20:07
Message-Id: AF7CC769-9154-4C73-9E96-0F2D92BA81D6@gentoo.org
In Reply to: [gentoo-dev] Re: [RFC] Masterplan for solving LINGUAS problems by Martin Vaeth
1 Dnia 1 czerwca 2016 11:23:09 CEST, Martin Vaeth <martin@×××××.de> napisał(a):
2 >Michał Górny <mgorny@g.o> wrote:
3 >>
4 >> 1. Get approval on INSTALL_MASK GLEP [1] and finish implementing it
5 >> in Portage.
6 >
7 >As already mentioned by some, INSTALL_MASK is something else than
8 >LINGUAS, because LINGUAS involves also files which are generated
9 >by the build system. Although I appreciate a more configurable
10 >INSTALL_MASK, this should not be mixed with the LINGUAS problem.
11
12 LINGUAS will be passed through from the environment so nothing is lost.
13
14 >
15 >> 2. Introduce a new USE_EXPAND that can be used to control
16 >localizations
17 >> whenever this is really required (dependencies, large files, etc.).
18 >> Let's use L10N as a draft name for it.
19 >
20 >Just to be sure that there is no misunderstanding:
21 >L10N should take the role which LINGUAS currently has for most
22 >packages from the user perspective.
23 >In other words, all ebuilds for packages whose build systems treat
24 >LINGUAS in a clean way (not relying on order etc.)
25 >and which currently have IUSE=linuguas_* will very likely contain
26 >corresponding ISUE=l10n_* and the line
27 >
28 >export LINGUAS=$L10N
29 >
30 >Therefore, I suggest to put this line in l10n.eclass
31 >(perhaps with a mechanism to avoid it for some exceptional packages
32 >which have to treat LINGUAS differently.)
33 >This way, none of these ebuilds inheriting l10n needs to be patched.
34
35 This eclass should be killed with fire as ugly nonsense that makes some packages useless for binary packages. As far as I'm concerned, it may not exist, be broken or whatever.
36
37 As for LINGUAS, it should be left as a toy for advanced users and not presented as a recommended solution.
38
39 >
40 >> 3. Fix all packages using LINGUAS as USE_EXPAND, either by converting
41 >> to L10N or by removing the needless flags.
42 >
43 >I would strongly discourage doing the latter (unless IUSE=linguas_*
44 >was there only by mistake): When users change their L10N (or
45 >USE-flags), users should be able to see which packages need a
46 >recompilation when using emerge -N. Also for binary packages, it
47 >must be easily possible to see changes.
48 >See the more lengthy explanation below.
49 >
50 >> Request changing LINGUAS to L10N in make.conf,
51 >
52 >+
53 >
54 >> and make LINGUAS considered an 'advanced variable' for
55 >> implicit localization control (i.e. passed through to build systems).
56 >
57 >With only some rare exceptions (e.g. where the order matters),
58 >ebuilds should better set this variable according to IUSE=l10n_*.
59 >It would be better if these exceptions would not have to exist
60 >at all, i.e. if e.g. the ebuilds for packages for which the order
61 >of LINGUAS matters also use IUSE=l10n_* and introduce other
62 >USE flags to specify the order somehow (AFAIK only mplayer is
63 >involved, and for this only the first item is important, so that
64 >one can introduce e.g. IUSE=default_l10n_* variables for which exactly
65 >one must be set, or something similar.)
66 >Indeed, these exceptions are very inconvenient for the user
67 >as well as for the package manager:
68 >
69 >1) In contrast to packages with L10N, the user cannot see with
70 >tools like eix for which linguas a certain package is installed.
71 >In fact, the user would have to analyze the compressed environment
72 >file find this out (this is also very package manager specific):
73
74 What's the use of this? Most of the packages don't have the flags anyway. For those who have, you can't trust them being up-to-date.
75
76 As for installed package, all files are listed in vdb (including those masked), so you can easily figure out the differences. In fact, app-portage/install-mask supports rebuilding due to IM changes for a long time.
77
78 >
79 >2) Even worse for binary packages.
80
81 Wrong. All localizations are included in the binary package, so it's perfectly reusable across all systems. Of course, as long as maintainer doesn't start playing with LINGUAS.
82
83 >
84 >3) The package manager cannot see after a change of LINGUAS,
85 >which packages need a recompilaten.
86
87 Wrong, as already explained above.
88
89 >
90 >4) The same for binary packages.
91
92 Likewise.
93
94 >
95 >> Recommend clean INSTALL_MASK solution instead.
96 >
97 >I would also not mix these unrelated things in the documentation.
98 >One can hint that this takes additional actions for build
99 >systems not honouring L10N correctly, but usually it is
100 >not a substitute for setting L10N (or LINGUAS for the
101 >exceptional packages) but only a supplement.
102
103
104 --
105 Best regards,
106 Michał Górny (by phone)

Replies