|
|
1.1 ! root 1: .TH CPIO 5 ! 2: .CT 1 comm_users ! 3: .SH NAME ! 4: cpio \- format of cpio archive ! 5: .SH DESCRIPTION ! 6: The archived files are recorded consecutively, each ! 7: preceded by a ! 8: .BR header . ! 9: The header ! 10: structure, when the ! 11: .B \-c ! 12: option of ! 13: .IR cpio (1) ! 14: is not used, is: ! 15: .PP ! 16: .EX ! 17: .ta \w'short 'u +\w'ushort 'u ! 18: typdef unsigned short ushort; ! 19: struct { ! 20: short h_magic, ! 21: h_dev; ! 22: ushort h_ino, ! 23: h_mode, ! 24: h_uid, ! 25: h_gid; ! 26: short h_nlink, ! 27: h_rdev, ! 28: h_mtime[2], ! 29: h_namesize, ! 30: h_filesize[2]; ! 31: char h_name[h_namesize rounded to word]; ! 32: } Hdr; ! 33: .EE ! 34: .PP ! 35: When the ! 36: .B \-c ! 37: option is used, the ! 38: .B header ! 39: information is printable, as described by the ! 40: .IR printf (3) ! 41: call ! 42: .IP ! 43: .EX ! 44: printf(Chdr, "%6o%6o%6o%6o%6o%6o%6o%6o%11lo%6o%11lo%s", ! 45: Hdr.h_magic, Hdr.h_dev, Hdr.h_ino, Hdr.h_mode, ! 46: Hdr.h_uid, Hdr.h_gid, Hdr.h_nlink, Hdr.h_rdev, ! 47: Longtime, Hdr.h_namesize, Longfile, Hdr.h_name ! 48: .EE ! 49: .PP ! 50: .L Longtime ! 51: and ! 52: .L Longfile ! 53: are equivalent to ! 54: .L Hdr.h_mtime ! 55: and ! 56: .LR Hdr.h_filesize , ! 57: respectively. ! 58: Every instance of ! 59: .L h_magic ! 60: contains the octal constant ! 61: .LR 070707 . ! 62: The items ! 63: .L h_dev ! 64: through ! 65: .L h_mtime ! 66: have meanings explained in ! 67: .IR stat (2). ! 68: The length of the null-terminated path name ! 69: .LR h_name , ! 70: including the null byte, ! 71: is given by ! 72: .LR h_namesize . ! 73: .PP ! 74: The last element ! 75: of the archive ! 76: is a dummy entry for the name ! 77: .BR TRAILER!!! , ! 78: with padding to a multiple of 512 bytes. ! 79: Special files, directories, and the trailer are recorded ! 80: with ! 81: .L h_filesize ! 82: equal to zero. ! 83: .SH "SEE ALSO" ! 84: .IR cpio (1), ! 85: .IR find (1), ! 86: .IR stat (2). ! 87: .\" @(#)cpio.4 5.2 of 5/18/82
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.