Bug 14117

Summary: locales are deleted according to the language
Product: Sisyphus Reporter: Mikhail Gusarov <dottedmag>
Component: alterator-sysconfigAssignee: Anton Farygin <rider>
Status: CLOSED FIXED QA Contact: qa-sisyphus
Severity: normal    
Priority: P2 CC: boyarsh, ktirf, ldv, mike, rider, rom_as, snejok, wart
Version: unstable   
Hardware: all   
OS: Linux   

Description Mikhail Gusarov 2008-01-22 02:09:37 MSK
Many locales are deleted during installation because they are 
marked as %lang-files. This is utterly wrong, as available 
locales should not be bound to the language selected during 
installation.
Comment 1 Dmitry V. Levin 2008-01-22 02:42:12 MSK
Described behavior was introduced in glibc-locales-2.2.5-alt5 (20.05.2002) and
was mentioned in the %changelog entry for that release.

There is a macro switch, langify, which controls (at glibc build time) whether
glibc-locales subpackage will be built langified or not.
The default is to enable langify.

AWAIR the reason for this default was to save disk space.
Comment 2 Mikhail Gusarov 2008-01-22 02:54:04 MSK
I doubt it is useful anywhere except the embedded device. Maybe it should be 
disabled by default?

2ktirf: please note.
Comment 3 Wartan Hachaturow 2008-01-22 12:55:05 MSK
I agree :) Removing locales forever, even during updates and glibc-locales
reinstalls, just because I used to choose "English" as an *installation*
language in the installer is just plain wrong. If we can't handle full-blown
locales packages, let's reinvent the whee^W^WDebian runtime locale generation
mechanism and propose the users to choose the locales they'd like to have compiled.
Comment 4 Alexey Rusakov 2008-01-23 03:12:56 MSK
I agree with dottedmag@. Given that ALT Linux has some installation prospects in
regions with non-Russian, non-English locales, I believe we have to install all
translated messages. Btw, how much space is saved thanks to langify? (estimated,
if there are no actual data)
Comment 5 Dmitry V. Levin 2008-01-23 03:27:03 MSK
(In reply to comment #4)
> I agree with dottedmag@. Given that ALT Linux has some installation prospects in
> regions with non-Russian, non-English locales, I believe we have to install all
> translated messages.

Nobody forces us to activate %_install_langs in /etc/rpm/macros file during OS
installation.

> Btw, how much space is saved thanks to langify? (estimated,
> if there are no actual data)

$ du -hsc /usr/lib64/locale/{en,ru}_* |fgrep total
4.7M    total
$ du -hs /usr/lib64/locale
64M     /usr/lib64/locale

So, is there any reason to install all locales, but at the same time install
only russian translations?
If yes, then there is a reason to disable langify in glibc-locales.
If no, then there is a reason to disable %_install_langs in installer.
Comment 6 Alexey Rusakov 2008-01-23 03:30:21 MSK
Only Russian translations are not suitable. I have just received a request about
Spanish localization in ALT Linux %-)
Comment 7 Mikhail Gusarov 2008-01-23 09:20:12 MSK
> So, is there any reason to install all locales, but at the 
same time install only russian translations?

Yes. If l10n is stripped then user gets English messages, which 
is ok (for some value of ok). If locales are stripped then user 
gets broken system which can't handle his LC_CTYPE/LC_COLLATE/LC_
WHATEVER (especially if user logs in using ssh).
Comment 8 Alexey Rusakov 2008-01-23 19:49:16 MSK
Do 60M matter that much nowadays?
Comment 9 Dmitry V. Levin 2008-01-23 20:19:20 MSK
(In reply to comment #8)
> Do 60M matter that much nowadays?

translations take less disk space than locales.
Comment 10 Dmitry V. Levin 2008-01-23 20:23:57 MSK
Let's disable %_install_langs in installer then.
Comment 11 Alexey Rusakov 2008-01-23 20:33:22 MSK
(In reply to comment #9)
> (In reply to comment #8)
> > Do 60M matter that much nowadays?
> 
> translations take less disk space than locales.
Oh. That's a surprise to me. Live and learn %-)
Comment 12 Wartan Hachaturow 2008-01-23 23:36:03 MSK
(In reply to comment #10)
> Let's disable %_install_langs in installer then.

I agree, that was more of a bug in the installer than in glibc-locales.
Comment 13 inger@altlinux.org 2008-01-24 09:58:54 MSK
OK, I will disable %__rpm_install_langs in the next alterator-sysconfig release.
Comment 14 Dmitry V. Levin 2008-02-29 20:14:49 MSK
Was fixed in alterator-sysconfig-0.5-alt2
Comment 15 Dmitry V. Levin 2008-02-29 20:16:25 MSK
*** Bug 14706 has been marked as a duplicate of this bug. ***