You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
70 lines
2.8 KiB
70 lines
2.8 KiB
From: Pavel Raiskup <praiskup@redhat.com>
|
|
Date: Mon, 14 Sep 2015 09:27:21 +0200
|
|
Subject: [PATCH 1/7] make '-c' equivalent to '-H newc'
|
|
|
|
diff --git a/doc/cpio.texi b/doc/cpio.texi
|
|
index e631934..a788b5d 100644
|
|
--- a/doc/cpio.texi
|
|
+++ b/doc/cpio.texi
|
|
@@ -261,7 +261,8 @@ Sets the I/O block size to @var{block-size} * 512 bytes.
|
|
@item -B
|
|
Set the I/O block size to 5120 bytes.
|
|
@item -c
|
|
-Use the old portable (ASCII) archive format.
|
|
+Identical to "-H newc", use the new (SVR4) portable format. If you wish the old
|
|
+portable (ASCII) archive format, use "-H odc" instead.
|
|
@item -C @var{number}
|
|
@itemx --io-size=@var{number}
|
|
Set the I/O block size to the given @var{number} of bytes.
|
|
@@ -343,7 +344,8 @@ Equivalent to @option{-sS}.
|
|
@item -B
|
|
Set the I/O block size to 5120 bytes.
|
|
@item -c
|
|
-Use the old portable (ASCII) archive format.
|
|
+Identical to "-H newc", use the new (SVR4) portable format. If you wish the old
|
|
+portable (ASCII) archive format, use "-H odc" instead.
|
|
@item -C @var{number}
|
|
@itemx --io-size=@var{number}
|
|
Set the I/O block size to the given @var{number} of bytes.
|
|
@@ -454,7 +456,8 @@ Sets the I/O block size to @var{block-size} * 512 bytes.
|
|
@item -B
|
|
Set the I/O block size to 5120 bytes.
|
|
@item -c
|
|
-Use the old portable (ASCII) archive format.
|
|
+Identical to "-H newc", use the new (SVR4) portable format. If you wish the old
|
|
+portable (ASCII) archive format, use "-H odc" instead.
|
|
@item -C @var{number}
|
|
@itemx --io-size=@var{number}
|
|
Set the I/O block size to the given @var{number} of bytes.
|
|
@@ -600,7 +603,8 @@ block size is 512 bytes.
|
|
|
|
@item -c
|
|
[@ref{copy-in},@ref{copy-out},@ref{copy-pass}]
|
|
-@*Use the old portable (ASCII) archive format.
|
|
+@*Identical to "-H newc", use the new (SVR4) portable format. If you wish the
|
|
+old portable (ASCII) archive format, use "-H odc" instead.
|
|
|
|
@item -C @var{io-size}
|
|
@itemx --io-size=@var{io-size}
|
|
diff --git a/src/main.c b/src/main.c
|
|
index a13861f..a875a13 100644
|
|
--- a/src/main.c
|
|
+++ b/src/main.c
|
|
@@ -124,7 +124,7 @@ static struct argp_option options[] = {
|
|
{"block-size", BLOCK_SIZE_OPTION, N_("BLOCK-SIZE"), 0,
|
|
N_("Set the I/O block size to BLOCK-SIZE * 512 bytes"), GRID+1 },
|
|
{NULL, 'c', NULL, 0,
|
|
- N_("Use the old portable (ASCII) archive format"), GRID+1 },
|
|
+ N_("Identical to \"-H newc\", use the new (SVR4) portable format. If you wish the old portable (ASCII) archive format, use \"-H odc\" instead."), GRID+1 },
|
|
{"dot", 'V', NULL, 0,
|
|
N_("Print a \".\" for each file processed"), GRID+1 },
|
|
{"io-size", 'C', N_("NUMBER"), 0,
|
|
@@ -329,6 +329,7 @@ parse_opt (int key, char *arg, struct argp_state *state)
|
|
case 'c': /* Use the old portable ASCII format. */
|
|
if (archive_format != arf_unknown)
|
|
USAGE_ERROR ((0, 0, _("Archive format multiply defined")));
|
|
+#define SVR4_COMPAT
|
|
#ifdef SVR4_COMPAT
|
|
archive_format = arf_newascii; /* -H newc. */
|
|
#else
|