shithub: scc

ref: b1d89be9c61f4ab4c470dc480077fc90a00c4294
dir: /src/libc/time/gentz.awk/

View raw version
BEGIN { print "#include \"../libc.h\"\nstruct tzone tzones[] = {" }
{
    split($2,a,":")
    min = a[1] * 60
    min = min + a[2]
    sec = min * 60
    printf "\t{\"%s\", %d},\n", $1, sec
}
END { print "\t{0,\t0}\n};\n" }