home *** CD-ROM | disk | FTP | other *** search
/ linuxmafia.com 2016 / linuxmafia.com.tar / linuxmafia.com / pub / linux / backup / tar-1.13-bzip2-option-I.patch < prev    next >
Internet Message Format  |  2001-09-04  |  3KB

  1. From rmoen@valinux.com Wed Sep 05 13:42:11 2001
  2. Return-path: <rmoen@valinux.com>
  3. Envelope-to: rick@linuxmafia.com
  4. Delivery-date: Wed, 05 Sep 2001 13:42:11 -0700
  5. Received: from mail.valinux.com ([198.186.202.175] ident=mail)
  6.     by uncle-enzo with esmtp (Exim 3.31 #1 (Debian))
  7.     id 15ejUx-0006p9-00
  8.     for <rick@linuxmafia.com>; Wed, 05 Sep 2001 13:42:11 -0700
  9. Received: from alanine.hdqt.valinux.com ([10.5.5.10] ident=mail)
  10.     by mail.valinux.com with esmtp (Exim 3.31-VA-mm2 #1 (Debian))
  11.     id 15ejUH-0005Mj-00
  12.     for <rick@linuxmafia.com>; Wed, 05 Sep 2001 13:41:29 -0700
  13. Received: from rmoen by alanine.hdqt.valinux.com with local (Exim 3.12 #1 (Debian))
  14.     id 15ejWc-0007Fo-00
  15.     for <rick@linuxmafia.com>; Wed, 05 Sep 2001 13:43:54 -0700
  16. Date: Wed, 5 Sep 2001 13:43:54 -0700
  17. To: rick@linuxmafia.com
  18. Subject: tar patch
  19. Message-ID: <20010905134353.C2946@valinux.com>
  20. Mime-Version: 1.0
  21. Content-Type: text/plain; charset=us-ascii
  22. Content-Disposition: inline
  23. User-Agent: Mutt/1.2.5i
  24. From: Rick Moen <rmoen@valinux.com>
  25. Content-Length: 2080
  26. Lines: 56
  27.  
  28.  
  29. ===============================================================================
  30. patch by Hiroshi Takekawa to integrate bzip2 compression filter (option -I)
  31.  
  32.  - Clifford
  33.  
  34. --- src/tar.c.orig    Wed Jul  7 07:49:50 1999
  35. +++ src/tar.c    Sun Jul 11 17:25:49 1999
  36. @@ -16,6 +16,9 @@
  37.     with this program; if not, write to the Free Software Foundation, Inc.,
  38.     59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
  39.  
  40. +/* 13 Oct 97: patched by Hiroshi Takekawa to integrate bzip2 as
  41. +              compression filter (option -I) */
  42. +
  43.  #include "system.h"
  44.  
  45.  #include <getopt.h>
  46. @@ -164,6 +167,8 @@
  47.    {"block-number", no_argument, NULL, 'R'},
  48.    {"block-size", required_argument, NULL, OBSOLETE_BLOCKING_FACTOR},
  49.    {"blocking-factor", required_argument, NULL, 'b'},
  50. +  {"bzip2", required_argument, NULL, 'I'},
  51. +  {"bunzip2", required_argument, NULL, 'I'},
  52.    {"catenate", no_argument, NULL, 'A'},
  53.    {"checkpoint", no_argument, &checkpoint_option, 1},
  54.    {"compare", no_argument, NULL, 'd'},
  55. @@ -340,6 +345,7 @@
  56.                PATTERN                at list/extract time, a globbing
  57. PATTERN\n\
  58.    -o, --old-archive, --portability   write a V7 format archive\n\
  59.        --posix                        write a POSIX conformant archive\n\
  60. +  -I, --bzip2, --bunzip2             filter the archive through bzip2\n\
  61.    -z, --gzip, --ungzip               filter the archive through gzip\n\
  62.    -Z, --compress, --uncompress       filter the archive through compress\n\
  63.        --use-compress-program=PROG    filter through PROG (must accept -d)\n"),
  64. @@ -416,7 +422,7 @@
  65.     Y  per-block gzip compression */
  66.  
  67.  #define OPTION_STRING \
  68. -  "-01234567ABC:F:GK:L:MN:OPRST:UV:WX:Zb:cdf:g:hiklmoprstuvwxz"
  69. +  "-01234567ABC:F:GIK:L:MN:OPRST:UV:WX:Zb:cdf:g:hiklmoprstuvwxz"
  70.  
  71.  static void
  72.  set_subcommand_option (enum subcommand subcommand)
  73. @@ -787,6 +793,10 @@
  74.      if (add_exclude_file (excluded, optarg, '\n') != 0)
  75.        FATAL_ERROR ((0, errno, "%s", optarg));
  76.      break;
  77. +
  78. +      case 'I':
  79. +    set_use_compress_program_option ("bzip2");
  80. +      break;
  81.  
  82.        case 'z':
  83.      set_use_compress_program_option ("gzip");
  84.  
  85.