cygwin started speaking German today

Eric Blake
Tue Sep 13 18:39:00 GMT 2011

On 09/09/2011 08:59 AM, Corinna Vinschen wrote:
> On Sep  9 13:33, Andy Koppe wrote:
>> The 'C.UTF-8' default locale is not a bug, it was a deliberate design decision.
> Exactly.  And it has been discussed a lot on the cygwin-apps mailing
> list.
> And above all, there *is* an official way for the user to align the
> Cygwin locale with the Windows locale, see the -s and -u options
> of the locale(1) command:

On 09/09/2011 09:09 AM, Corinna Vinschen wrote:
 >> OK, then the following four facilities are needed in Cygwin.
 >> 1) We need the name of the locale which is in effect when the user has
 >>     not specified environment variables.
 > In Fedora, for instance, the fallback is what is set as system default
 > in /etc/sysconfig/i18n.
 > In Cygwin the fallback is the system default set in 
 > or /etc/profile.d/lang.csh.
 > Why should libintl use anything else on Cygwin, but not on Linux?

Given this, I think the bug is in cygwin for having base files 
/etc/profile.d/lang.{sh,csh} which hardcode LANG to C.UTF-8 instead of 
using locale -s -u to default LANG to the preferred Windows settings. 
Libintl should NOT be second-guessing an explicit setting of LANG, but 
cygwin should NOT be explicitly setting LANG to C.UTF-8 in its default 
startup scripts without any regards to the Windows settings.  Whether 
setlocale(LC_ALL,"") returns C.UTF-8 or a Windows-appropriate string 
_when LANG is undefined_ is still worth solving, but right now, an 
out-of-the-box cygwin installation _always has LANG defined_ by the 
default startup scripts.  So our first focus should be to get that 
setting of LANG fixed to honor Windows, and to teach libintl that when 
LANG is set we really meant it.

Eric Blake    +1-801-349-2682
Libvirt virtualization library

Problem reports:
Unsubscribe info:

More information about the Cygwin mailing list