[PATCH/RFA]: Allow default locale different from "C"

Corinna Vinschen vinschen@redhat.com
Sat Oct 10 01:27:00 GMT 2009


On Oct  8 12:32, Jeff Johnston wrote:
> On 07/10/09 01:07 PM, Corinna Vinschen wrote:
>> Hi,
>>
>> per POSIX, a system can have a default locale different from "C".
>> See http://www.opengroup.org/onlinepubs/7990989775/xbd/locale.html:
>>[...]
>
> I'm striving to remove all the OS/platform checks throughout shared code so 
> I would prefer you do it this way:
>
> #ifndef DEFAULT_LOCALE
> #define DEFAULT_LOCALE "C"
> #endif
>
> and then set DEFAULT_LOCALE in libc/include/sys/config.h or configure.host 
> for Cygwin.
>
> That way, any platform may reset it if desired and we don't have a huge
> if/else check in the code.
>
> Ok to apply if you do it that way.

Thanks, applied.  I'm going to move the Cygwin-specific DEFAULT_LOCALE
into winsup/cygwin/include/cygwin/config.h.


Corinna

-- 
Corinna Vinschen
Cygwin Project Co-Leader
Red Hat



More information about the Newlib mailing list