[GRASS-dev] Messing with locale during start-up in r53620

Maris Nartiss maris.gis at gmail.com
Mon Nov 12 09:41:51 PST 2012


Hello,
OK, I missed the bashrc change, still it seems that GRASS is
interfering with locale where it shouldn't:
Set language to "system" == no entry in rc or bashrc
LANG=garbage bin.x86_64-unknown-linux-gnu/grass70

Satīra pagaidu failus...
Startē GRASS GIS...
Failed to set LC_ALL to garbage.UTF-8 (unsupported locale setting)

^^^ WTF?!? I didn't asked GRASS to touch anything locale related!

Also for some reason it isn't using the user provided language for
startup messages. Here's an example:
bin.x86_64-unknown-linux-gnu/grass70
Satīra pagaidu failus...
Startē GRASS GIS...
Failed to set LC_ALL to de_DE.UTF-8 (unsupported locale setting) <---
this is correct message, as I don't have de_DE

GUI comes up in de, still "Satīra pagaidu failus" isn't de nor
C/POSIX. I translated that string as "TEXT IN GERMAN", still it comes
up in system LANG.

I hope it clears a bit,
Maris.

2012/11/12 Martin Landa <landa.martin at gmail.com>:
> Hi,
>
> 2012/11/12 Maris Nartiss <maris.gis at gmail.com>:
>
>> can You, please, explain me rationale behind r53620?
>> Now GRASS mangles with LANG and LOCALE settings also when it shouldn't
>> - when no language overrider is in force. IMHO GRASS shouldn't
>> interfere with existing system settings unless explicitly requested by
>> user.
>
> not fully understanding your report, wxGUI stores environmental
> variables in .grass7/bashrc.
>
> 1)
>
> env | grep LANG
> LANG=en_US.UTF-8
> LANGUAGE=en_US:en
>
> start GRASS -> starts using system language settings
>
> 2)
>
> LANG=cs_CZ grass70 -gui
>
> -> starts in user defined settings
>
> 3)
>
> * start wxGUI -> Settings -> Preferences -> Appearance -> change
> language settings -> Save
> * restart GRASS
>
> -> starts with locales defined in .grass7/bashrc
>
> $ cat /home/landa/.grass7/bashrc
> export LANG=cs
>
> grass70
>
> env | grep LANG
> LANG=cs
> LANGUAGE=cs
>
> Martin
>
> --
> Martin Landa <landa.martin gmail.com> * http://geo.fsv.cvut.cz/~landa


More information about the grass-dev mailing list