Right, probably the slickest solution is to figure out how to set up LE and
call mktime() or gmtime() and then strftime(). See the C library manual for
details. People here can help you with setting up an LE environment and
calling a C routine.

Charles

-----Original Message-----
From: IBM Mainframe Discussion List [mailto:[email protected]] On Behalf
Of McKown, John
Sent: Tuesday, March 27, 2012 5:48 AM
To: [email protected]
Subject: Re: Assembler - convrssion of Epoch (Unix) time to printable

Cheat? I'm a big fan of cheating. I often use LE enabled HLASM just so that
I can use the subroutines from the C language to do "fancy" printing by
using sprintf() calls. Of course, you could also cheat by converting the C
epoch to a Lilian date (simple addition) and using the LE subroutine CEEDATE
to convert it to printable form. But, then, the UNIX epoch is simply a
number. The number of seconds since 00:00:00 GMT 1 Jan 1970. It would be
rather easy to convert to yyyy-mm-ddThh:mm:ss if it weren't for the "leap
seconds". Which may or may not be of any interest to you.

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to