PDP-10 / its

Incompatible Timesharing System
Other
858 stars 81 forks source link

Added files and directories that support the MDL 55 runtime. #2160

Closed eswenson1 closed 1 year ago

larsbrinkhoff commented 1 year ago

Oops, forgot about timestamps.

eswenson1 commented 1 year ago

Do you have some way to capture all the timestamps, from, say an itstar extract, so I don’t have to do this manually?

larsbrinkhoff commented 1 year ago

I have no ready to go solution, but what I will usually do is to get it out of a tree of extracted tapes. Matching on file names and maybe sha1sum if names are not unique. You have to be careful to set TZ right when listing the files to not get your local time, but "MIT time".

eswenson1 commented 1 year ago

When I extract the files, I don't see the times for the files that are in previous years. I see output like:

 15478160     12 -rw-rw-r--   1 eswenson eswenson     8594 Jun  7  1974 ./mprog/mudcom.utt045
 15478141      4 -rw-rw-r--   1 eswenson eswenson     1375 Aug 22  1979 ./mprog/fmacro.ubkd10
 15478115      4 -rw-rw-r--   1 eswenson eswenson      450 Apr 11  1976 ./mprog/blt.1
 15478186      4 -rw-rw-r--   1 eswenson eswenson     1239 Jun 17  1976 ./mprog/unload.ubkd08

How do I get the times?

eswenson1 commented 1 year ago

Never mind, I see that ls has a --full-time option.

But I'm not sure how to interpret this:

-rw-rw-r-- 1 eswenson eswenson   508 1974-11-18 06:54:01.000000000 -0800 fillen.udl003
-rw-rw-r-- 1 eswenson eswenson  1375 1979-08-22 18:08:45.000000000 -0700 fmacro.ubkd10
-rw-rw-r-- 1 eswenson eswenson  4604 1977-09-24 18:37:44.000000000 -0700 fold.ubkd04
-rw-rw-r-- 1 eswenson eswenson  4007 1976-11-01 12:08:44.000000000 -0800 gc.ubkd13

Why are some files listed with -0800 and some with -0700? I assume it was because of daylight savings time? So I can tell which ones are from EDT and which are from EST based on the -0800 (PST) and -0700 (PDT), right? And then convert to EST/EDT? I tried setting my time zone (TZ) to EST, but then I get output like this:

-rw-rw-r-- 1 eswenson eswenson   329 1977-02-09 20:59:44.000000000 +0000 acchrs.udl001
-rw-rw-r-- 1 eswenson eswenson  5290 1975-05-30 18:51:05.000000000 +0000 aconst.udl005
-rw-rw-r-- 1 eswenson eswenson  3877 1975-01-22 19:22:33.000000000 +0000 ahelp.udl001
-rw-rw-r-- 1 eswenson eswenson  3856 1975-03-14 18:24:28.000000000 +0000 aprint.udl001
-rw-rw-r-- 1 eswenson eswenson 58201 1979-02-02 04:23:05.000000000 +0000 assem.nbin

where everything is +0800. I'm not sure what this means. Do you?

eswenson1 commented 1 year ago

I’m writing a program to generate the appropriate entries for timestamps.txt.

larsbrinkhoff commented 1 year ago

I see +0000 in the latter output, not +0800. I don't understand it either. Maybe the one with timezones (-0800 and -0700) are in GMT, and the ones with +0000 are local time according to TZ? But why would it output +0000?

I have been using stat to get the full timestamp, but ls --full-time ought to do the same thing.

eswenson1 commented 1 year ago

I wrote a program generating timestamps for a directory with ITS directories as children. For all the ITS files that were written in EST, the date/times are correct, and for all those in EST, they are (predictably) 1 hour off.

So I need to first determine which time zone (EST or EDT) would have been in effect and then adjust all the EDT times by an hour. Should be simple. As soon as I’m convinced the program works correctly, I’ll update all the timestamps in build/timestamps.txt with the MDL library files.

eswenson1 commented 1 year ago

Fixed program. Ran it and generated a timestamps.txt. Merged with build/timestamps.txt and successfully ran make EMULATOR=simh out/simh/stamp/touch. Will commit shortly and generate a PR.