Importing usr.bin/hexdump

Replaces commands/hexdump as well as commands/od.
No Minix-specific changes were needed.

test/testsh2.sh was modified to match the spacing
used in the output of the NetBSD od command.

Change-Id: I65ee1d30e8cdd546097462df7c38c2d38f3e891d
This commit is contained in:
Thomas Cort
2013-10-29 14:48:38 -04:00
parent 69ccf97d12
commit 1e33498f8c
19 changed files with 209 additions and 552 deletions

View File

@@ -116,18 +116,18 @@ head -1 $f |od >x # see if od converts ascii to octal ok
if [ $ARCH = i86 -o $ARCH = i386 ]
then
cat >answer <<END
0000000 064124 020145 064564 062555 064040 071541 061440 066557
0000020 020145 064164 020145 060567 071154 071565 071440 064541
0000040 020144 067564 072040 066141 020153 063157 066440 067141
0000060 020171 064164 067151 071547 000012
0000000 064124 020145 064564 062555 064040 071541 061440 066557
0000020 020145 064164 020145 060567 071154 071565 071440 064541
0000040 020144 067564 072040 066141 020153 063157 066440 067141
0000060 020171 064164 067151 071547 000012
0000071
END
else
cat >answer <<END
0000000 052150 062440 072151 066545 020150 060563 020143 067555
0000020 062440 072150 062440 073541 066162 072563 020163 060551
0000040 062040 072157 020164 060554 065440 067546 020155 060556
0000060 074440 072150 064556 063563 005000
0000000 052150 062440 072151 066545 020150 060563 020143 067555
0000020 062440 072150 062440 073541 066162 072563 020163 060551
0000040 062040 072157 020164 060554 065440 067546 020155 060556
0000060 074440 072150 064556 063563 005000
0000071
END
fi
@@ -138,18 +138,18 @@ head -1 $f |od -d >x # see if od converts ascii to decimal ok
if [ $ARCH = i86 -o $ARCH = i386 ]
then
cat >answer <<END
0000000 26708 08293 26996 25965 26656 29537 25376 28015
0000020 08293 26740 08293 24951 29292 29557 29472 26977
0000040 08292 28532 29728 27745 08299 26223 27936 28257
0000060 08313 26740 28265 29543 00010
0000000 26708 08293 26996 25965 26656 29537 25376 28015
0000020 08293 26740 08293 24951 29292 29557 29472 26977
0000040 08292 28532 29728 27745 08299 26223 27936 28257
0000060 08313 26740 28265 29543 00010
0000071
END
else
cat >answer <<END
0000000 21608 25888 29801 28005 08296 24947 08291 28525
0000020 25888 29800 25888 30561 27762 30067 08307 24937
0000040 25632 29807 08308 24940 27424 28518 08301 24942
0000060 31008 29800 26990 26483 02560
0000000 21608 25888 29801 28005 08296 24947 08291 28525
0000020 25888 29800 25888 30561 27762 30067 08307 24937
0000040 25632 29807 08308 24940 27424 28518 08301 24942
0000060 31008 29800 26990 26483 02560
0000071
END
fi