coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: RFE: Modification to the Timezone Modifier


From: Eric Blake
Subject: Re: RFE: Modification to the Timezone Modifier
Date: Mon, 30 Sep 2013 14:18:18 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130923 Thunderbird/17.0.9

On 09/30/2013 07:54 AM, Marko Myllynen wrote:
> Hi,
> 
> On 2013-09-11 15:24, Marko Myllynen wrote:
>>
>> the national recommendations in Finland for Finnish concerning date
>> strings containing timezone state that they should use format like
>> "UTC+3" or "UTC+5.30".
>>
>> I've filed a RFE about glibc's strftime at
>> http://sourceware.org/bugzilla/show_bug.cgi?id=12747 in order to be able
>> to update the Finnish locale according to the recommendations.
>>
>> Given that GNU date's "UTC%:::z" produces almost what we're looking for
>> full hours ("UTC+03" vs "UTC+3") I'm wondering would it be possible to
>> add support for GNU date to express timezone in a way to match the
>> aforementioned recommendations?
>>
>> This might hopefully help in possible future discussions with Austin
>> Group which, if leading to positive results, could then in turn used as
>> basis for glibc strftime changes which would then, finally, allow
>> changing the Finnish locale as described above.

It seems like it would be reasonable to add some sort of modifier to the
existing %:::z to request suppression of leading 0.  If we didn't have
back-compat to worry about, I'd even suggest making %:::z be the short
form, and %0:::z be the 0-padded form.

> 
> since there were no comments about this I looked at the sources myself
> and noticed that GNU date (coreutils/src/date.c) uses in fact gnulib
> (gnulib/lib/strftime.c) which in turn states that the canonical copy of
> the file strftime.c is maintained with the GNU C Library.
> 
> This seems a bit of the chicken and the egg problem to me so I'm not
> sure how to proceed here. Of course, if you think this is something that
> will not be considered at least today it'd be also helpful to know.

Gnulib tries to copy from glibc, but we've diverged in the past and then
later fed it back into glibc where such things make sense (ie. fixing
gnulib does not necessarily require fixing glibc first).  But first, I'd
echo the advice that glibc gave you: open a bug with the Austin Group
(http://austingroupbugs.net/login_select_proj_page.php?ref=bug_report_page.php)
and point them to the existing GNU date extension of %:::z as something
that might be worth standardizing to meet the needs of the Finnish
government.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]