LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Error with Locale C library (https://www.linuxquestions.org/questions/linux-software-2/error-with-locale-c-library-599940/)

Alt-Ox 11-15-2007 04:29 PM

Error with Locale C library
 
hello guys

I'm having some troubles when executing beryl-settings, got the following:

Quote:

alt-ox@pc1:~$ beryl-settings

(beryl-settings:5578): Gtk-WARNING **: Locale not supported by C library.
Using the fallback 'C' locale.
Traceback (most recent call last):
File "/usr/bin/beryl-settings", line 35, in ?
locale.setlocale(locale.LC_ALL, '')
File "/usr/lib/python2.4/locale.py", line 381, in setlocale
return _setlocale(category, locale)
locale.Error: unsupported locale setting
Quote:

alt-ox@pc1:~$ cat /etc/debian_version
4.0
alt-ox@pc1:~$ uname -a
Linux pc1 2.6.18 #1 Sat Jun 2 13:03:17 BRT 2007 i686 GNU/Linux
Does anyone know how I can fix it?

Thanks!

alar 11-17-2007 06:56 PM

Do you have LANG variables set?
locale.LC_ALL is a language variable.
Check the beryl settings for things like language environment settings...

getdefaultlocale(envvars=('LANGUAGE', 'LC_ALL', 'LC_CTYPE', 'LANG'))
Tries to determine the default locale settings and returns
them as tuple (language code, encoding).

According to POSIX, a program which has not called
setlocale(LC_ALL, "") runs using the portable 'C' locale.
Calling setlocale(LC_ALL, "") lets it use the default locale as
defined by the LANG variable. Since we don't want to interfere
with the current locale setting we thus emulate the behavior
in the way described above.

To maintain compatibility with other platforms, not only the
LANG variable is tested, but a list of variables given as
envvars parameter. The first found to be defined will be
used. envvars defaults to the search path used in GNU gettext;
it must always contain the variable name 'LANG'.


Except for the code 'C', the language code corresponds to RFC
1766. code and encoding can be None in case the values cannot
be determined.


All times are GMT -5. The time now is 12:35 PM.