[comp.unix.questions] tar or cpio? When is byte swapping necessary?

chris@trantor.umd.edu (Chris Torek) (02/17/88)

>In article <2071@bsu-cs.UUCP> dhesi@bsu-cs.UUCP (Rahul Dhesi) writes:
>>... portability ought to be achieved by making the cpio *format*
>>portable, not just by compensating for nonportability in the format....

[I agree]

In article <699@mcdsun.UUCP> fnf@mcdsun.UUCP (Fred Fish) writes:
>Unfortunately this will not work for one not-so-obvious reason, and that
>is because there are systems that when reading the exact same media,
>will return bytes ordered differently.

Such systems are broken.

Yes, there are pieces of hardware that do virtual byteswaps, for
whatever reason.  If your tape or disk controller returns bytes in
the wrong order, your kernel should fix this.  (If you worry about
efficiency, provide a bit in the minor device number to control
this.)

You could equally say `unfortunately, this will not always work,
because there are systems that when reading the exact same media,
sometimes discard all the odd numbered bytes'.  The situation is
the same, except that in the latter case the breakage is much harder
to deny.
-- 
In-Real-Life: Chris Torek, Univ of MD Computer Science, +1 301 454 7163
(hiding out on trantor.umd.edu until mimsy is reassembled in its new home)
Domain: chris@mimsy.umd.edu		Path: not easily reachable