Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Qmail: users

New leapsecs.dat for mess822.

 

 

Qmail users RSS feed   Index | Next | Previous | View Threaded


amb-sendok-1343603179.nfeloaabagojcdldoihh at bradfo

Jun 29, 2012, 4:06 PM

Post #1 of 6 (1302 views)
Permalink
New leapsecs.dat for mess822.

Hello,

For those who might be using mess822 (or anything libtai), there is a
new update for leapsecs.dat that needs to be applied.

Andy


search-web-for-address at pyropus

Jun 30, 2012, 2:04 PM

Post #2 of 6 (1208 views)
Permalink
Re: New leapsecs.dat for mess822. [In reply to]

Andy Bradford <amb-sendok-1343603179.nfeloaabagojcdldoihh [at] bradfords> wrote:
>
> For those who might be using mess822 (or anything libtai), there is a
> new update for leapsecs.dat that needs to be applied.

djb's page at http://cr.yp.to/libtai.html says leapsecs.dat was last updated
on 2008-06-30. Where is the newer version with the recently-announced
leapsecond found?

Charles
--
--------------------------------------------------------------------------
Charles Cazabon
GPL'ed software available at: http://pyropus.ca/software/
Read http://pyropus.ca/personal/writings/12-steps-to-qmail-list-bliss.html
--------------------------------------------------------------------------


prj at case

Jun 30, 2012, 3:03 PM

Post #3 of 6 (1206 views)
Permalink
Re: New leapsecs.dat for mess822. [In reply to]

"Charles Cazabon" <search-web-for-address [at] pyropus> wrote:
> Where is the newer version with the recently-announced leapsecond
> found?

You can build one from the leapseconds file in the latest tzdata using
this Perl script:

TZ=UTC0 perl -e '
use strict;
use POSIX qw(&mktime);
use integer;
my @mon=qw(Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec);
my %months=map(($mon[$_] => $_), 0..$#mon);
my $line;
my $leaps=10;
$|=1;
while (defined($line=<STDIN>)) {
if ($line=~/^Leap\t(\d+)\t(\w+)\t(\d+)\t(\d+):(\d+):(\d+)\t\+\tS\n\z/) {
my $t=(mktime($6-1, $5, $4, $3, $months{$2}, $1-1900)+
1+$leaps++);
my @bytes=();
while ($t!=0) { unshift(@bytes, $t%256); $t/=256; }
while (@bytes<7) { unshift(@bytes, 0); }
unshift(@bytes, 64);
print(map(chr($_), @bytes)) or die($!);
}
}
' < leapseconds > leapsecs.dat


paul


search-web-for-address at pyropus

Jun 30, 2012, 3:14 PM

Post #4 of 6 (1204 views)
Permalink
Re: New leapsecs.dat for mess822. [In reply to]

Charles Cazabon <search-web-for-address [at] pyropus> wrote:
> Where is the newer version with the recently-announced leapsecond found?

I didn't find anyone maintaining an updated copy, though I could have easily
missed it. Attached is the updated .txt which the .dat can be compiled from.

Charles

--
--------------------------------------------------------------------------
Charles Cazabon
GPL'ed software available at: http://pyropus.ca/software/
Read http://pyropus.ca/personal/writings/12-steps-to-qmail-list-bliss.html
--------------------------------------------------------------------------
Attachments: leapsecs.txt.2012-06-30 (0.91 KB)


toby at su

Jun 30, 2012, 4:08 PM

Post #5 of 6 (1209 views)
Permalink
Re: New leapsecs.dat for mess822. [In reply to]

Charles Cazabon wrote:
> Andy Bradford <amb-sendok-1343603179.nfeloaabagojcdldoihh [at] bradfords> wrote:
> >
> > For those who might be using mess822 (or anything libtai), there is a
> > new update for leapsecs.dat that needs to be applied.
>
> djb's page at http://cr.yp.to/libtai.html says leapsecs.dat was last updated
> on 2008-06-30. Where is the newer version with the recently-announced
> leapsecond found?

I don't believe it's been updated yet. I wrote a libtai-based leapsecs.dat
compiling utility a few years back:

<URL:http://su.bze.ro/software/leapsunpack-0.05.tar.gz>

It pulls the current compressed leapseconds table from leap.yp.to (which isn't
updated yet) or another DNS-based table of your choice, such as leap.bze.ro. You
can also forgo the DNS part and just manually update leapsecs.txt with a new
line "+2012-06-30" and compile leapsecs.dat from that.


Toby


amb-sendok-1343708612.ijmkmcofljopobnjceid at bradfo

Jun 30, 2012, 9:23 PM

Post #6 of 6 (1207 views)
Permalink
Re: New leapsecs.dat for mess822. [In reply to]

Thus said "Charles Cazabon" on 30 Jun 2012 15:04:46 MDT:

> djb's page at http://cr.yp.to/libtai.html says leapsecs.dat was
> last updated on 2008-06-30. Where is the newer version with the
> recently-announced leapsecond found?

It looks like Dan hasn't yet updated that webpage. I'm not sure if he
still reads this mailing list, so I'll Cc him directly.

As far as updating is concerned, I usually just have a locally modified
copy of leapsecs.txt and then use the leapsecs binary from libtai to
regenerate:

./leapsecs < leapsecs.txt > leapsecs.dat

Andy

Qmail users RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.