tech-toolchain archive

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

Re: make: time stamps



On Fri, Apr 08, 2011 at 04:34:44PM -0700, Simon J. Gerraty wrote:
 > In my build at work, we like to have timestamps at various places,
 > to help track where all the time is going.
 > This is currently done by running date(1), but it would be more
 > efficient to do it from make itself.
 > The patch below adds :tL (localtime) and :tU (UTC) as modifiers to cause
 > us to treat the current value as a fmt string for strftime.

Once again: how about using words as the modifier names?

(thus, :localtime and :gmtime)

 > $ bmake -r -V '${The time is %c:L:tU}' -V '${Which is %Y-%m-%d %T %Z:L:tL}'

that is, to be honest, really ugly. :-(

-- 
David A. Holland
dholland%netbsd.org@localhost


Home | Main Index | Thread Index | Old Index