1 |
Russian translation attached |
2 |
|
3 |
+Sergey to see any obvious mistakes |
4 |
|
5 |
24.12.2022 11:34, Sam James пишет: |
6 |
> Bug: https://bugs.gentoo.org/886247 |
7 |
> Bug: https://bugs.gentoo.org/886017 |
8 |
> Signed-off-by: Sam James <sam@g.o> |
9 |
> --- |
10 |
> ...022-12-24-alternatives-introduction.en.txt | 92 +++++++++++++++++++ |
11 |
> 1 file changed, 92 insertions(+) |
12 |
> create mode 100644 2022-12-24-alternatives-introduction/2022-12-24-alternatives-introduction.en.txt |
13 |
> |
14 |
> diff --git a/2022-12-24-alternatives-introduction/2022-12-24-alternatives-introduction.en.txt b/2022-12-24-alternatives-introduction/2022-12-24-alternatives-introduction.en.txt |
15 |
> new file mode 100644 |
16 |
> index 0000000..841e07a |
17 |
> --- /dev/null |
18 |
> +++ b/2022-12-24-alternatives-introduction/2022-12-24-alternatives-introduction.en.txt |
19 |
> @@ -0,0 +1,92 @@ |
20 |
> +Title: Introduction of app-alternatives ebuilds |
21 |
> +Author: Sam James <sam@g.o> |
22 |
> +Posted: 2022-12-24 |
23 |
> +Revision: 1 |
24 |
> +News-Item-Format: 2.0 |
25 |
> + |
26 |
> +Gentoo is introducing a new category of ebuilds called 'app-alternatives' |
27 |
> +to handle cases where a symlink for a common binary may want to be switched |
28 |
> +between different packages by a user. |
29 |
> + |
30 |
> +Traditionally, eselect was used for this, and while eselect still has its |
31 |
> +place, it's unsuitable for cases like /bin/awk and /bin/sh because it |
32 |
> +prevents immutable system directories and (more importantly |
33 |
> +from a package management perspective) relies on orphaned symlinks which |
34 |
> +means no package owns /bin/awk, /bin/sh, etc. This is not reliable and |
35 |
> +can lead to dead symlinks (or no symlink at all) in some edge cases [0]. |
36 |
> + |
37 |
> +Systems will be more robust and desired system configuration |
38 |
> +can be achieved using the package manager rather than manual steps outside of it. |
39 |
> + |
40 |
> +The initial list of packages which support alternatives is as follows: |
41 |
> +- app-alternatives/awk |
42 |
> +- app-alternatives/bzip2 |
43 |
> +- app-alternatives/bc |
44 |
> +- app-alternatives/cpio |
45 |
> +- app-alternatives/gzip |
46 |
> +- app-alternatives/lex |
47 |
> +- app-alternatives/sh |
48 |
> +- app-alternatives/tar |
49 |
> +- app-alternatives/yacc |
50 |
> + |
51 |
> +The stabilization of these new ebuilds and packages depending |
52 |
> +on them is ongoing in bug 886017 [1]. |
53 |
> + |
54 |
> +## Per-upgrade requirements |
55 |
> + |
56 |
> +The default configuration on Gentoo systems is FEATURES="protect-owned" |
57 |
> +which works similarly to FEATURES="collision-protect" but it allows |
58 |
> +collisions between orphaned files. In this case, a one-off collision |
59 |
> +occurs as the app-alternatives/ ebuilds begin to claim once-orphaned |
60 |
> +symlinks. |
61 |
> + |
62 |
> +A similar issue occurred during the libxcrypt migration where users |
63 |
> +had upgrades interrupted by using the older, more aggressive |
64 |
> +FEATURES="collision-protect". |
65 |
> + |
66 |
> +It is recommended that users alter their configuration to |
67 |
> +remove references to 'collision-protect' in FEATURES and instead either |
68 |
> +explicitly enable 'protect-owned' in FEATURES or rely on the default |
69 |
> +(equivalent). It is also acceptable to simply disable collision-protect |
70 |
> +temporarily for the purposes of this news item. |
71 |
> + |
72 |
> +WARNING: Users with collision-protect enabled must disable FEATURES="collision-protect" |
73 |
> +in /etc/portage/make.conf by removing it or setting FEATURES="-collision-protect" |
74 |
> +if they have enabled it. collision-protect detects collisions between files including |
75 |
> +orphaned files where no package owns the file. |
76 |
> + |
77 |
> +## Migrating |
78 |
> + |
79 |
> +To migrate your system, a standard world upgrade will suffice: |
80 |
> +1. # emerge --sync |
81 |
> +2. # emerge -a -uvDU @world (or other similar standard world upgrade command) |
82 |
> + |
83 |
> +## Configuration |
84 |
> + |
85 |
> +Users who are not interested in using different implementations for |
86 |
> +various tools listed above can ignore this section. |
87 |
> + |
88 |
> +No configuration should be required by default, but users may wish |
89 |
> +to configure the new app-alternatives/ ebuilds to their tastes as they |
90 |
> +used to do via e.g. eselect-sh and eselect-awk. |
91 |
> + |
92 |
> +Going forward, /etc/portage/package.use will be used for this purpose. |
93 |
> + |
94 |
> +Users should review the USE flags available for the various app-alternatives |
95 |
> +ebuilds like app-alternatives/sh and adjust their configuration as desired. |
96 |
> + |
97 |
> +For example, to have /usr/bin/gzip be provided by app-arch/pigz for automatic |
98 |
> +parallelization of 'gzip', one would have the following in /etc/portage/package.use: |
99 |
> +``` |
100 |
> +# https://wiki.gentoo.org/wiki/Gzip#Parallelization |
101 |
> +# Make /usr/bin/gzip be a symlink to pigz for a speedup in compression |
102 |
> +app-alternatives/gzip -reference pigz |
103 |
> +``` |
104 |
> + |
105 |
> +## Further reading |
106 |
> + |
107 |
> +For more details, please see the technical documentation on the wiki [2]. |
108 |
> + |
109 |
> +[0] https://wiki.gentoo.org/wiki/Project:Base/Alternatives#Why.3F |
110 |
> +[1] https://bugs.gentoo.org/886017 |
111 |
> +[2] https://wiki.gentoo.org/wiki/Project:Base/Alternatives |
112 |
|
113 |
-- |
114 |
Best regards, |
115 |
Alexey "DarthGandalf" Sokolov |