The Unix Heritage Society mailing list
 help / color / mirror / Atom feed
From: carl.lowenstein@gmail.com (Carl Lowenstein)
Subject: [pups]  extract old archive format?
Date: Thu, 8 Apr 2010 21:39:04 -0700	[thread overview]
Message-ID: <z2o5904d5731004082139v1498ef52pd36fc318437e04e7@mail.gmail.com> (raw)
In-Reply-To: <n2m5904d5731004082137u5b054823wd4a9ce55113b1dee@mail.gmail.com>

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1239 bytes --]

On Thu, Apr 8, 2010 at 7:40 PM, John  Holden <johnh at psych.usyd.edu.au> wrote:
>
>> Well I found the ar specification (in ar.5 not ar.1).
>>
>>              struct ar_hdr {
>>                      char      ar_name[14];
>>                      long      ar_date;
>>                      char      ar_uid;
>>                      char      ar_gid;
>>                      int       ar_mode;
>>                      long      ar_size;
>>              };
>
> Endian should not be a problem on a Intel/AMD processor. More likely your C
> compiler is padding out the array for alignment. Try a '-fpack-struct' or
> more safely, read the elements individually rather than a structure.
>

In the PDP-11 long is 32 bits, int 16 bits.   And the PDP-11 is
determinedly little-endian if you stick to integers.

They got floating-point software right in 1971, but somebody screwed
up the word order when building FP hardware, which led to the
middle-endian mess.

   carl
--
   carl lowenstein         marine physical lab     u.c. san diego
                                                clowenstein at ucsd.edu



  parent reply	other threads:[~2010-04-09  4:39 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-09  2:40 John Holden
     [not found] ` <n2m5904d5731004082137u5b054823wd4a9ce55113b1dee@mail.gmail.com>
2010-04-09  4:39   ` Carl Lowenstein [this message]
2010-04-09 10:23     ` Johnny Billquist
2010-04-09 10:21 ` Johnny Billquist
     [not found] <337550.74945.qm@web82407.mail.mud.yahoo.com>
2010-04-09  5:35 ` Jeremy C. Reed
  -- strict thread matches above, loose matches on Subject: below --
2010-04-09  1:13 Norman Wilson
2010-04-09  2:11 ` Jeremy C. Reed
2010-04-09 10:15   ` Johnny Billquist
2010-04-09  5:49 ` Bob Eager
2010-04-08 13:25 Jeremy C. Reed
2010-04-08 14:49 ` Tim Bradshaw
2010-04-08 15:16 ` Brantley Coile
2010-04-08 17:09 ` Bob Eager
2010-04-09  5:11 ` Warren Toomey

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=z2o5904d5731004082139v1498ef52pd36fc318437e04e7@mail.gmail.com \
    --to=carl.lowenstein@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).