]> git.cworth.org Git - tar/blob - tests/testsuite
Imported Upstream version 1.21
[tar] / tests / testsuite
1 #! /bin/sh
2 #
3 # Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software
4 # Foundation, Inc.
5 # This test suite is free software; the Free Software Foundation gives
6 # unlimited permission to copy, distribute and modify it.
7 ## --------------------- ##
8 ## M4sh Initialization.  ##
9 ## --------------------- ##
10
11 # Be more Bourne compatible
12 DUALCASE=1; export DUALCASE # for MKS sh
13 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
14   emulate sh
15   NULLCMD=:
16   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
17   # is contrary to our usage.  Disable this feature.
18   alias -g '${1+"$@"}'='"$@"'
19   setopt NO_GLOB_SUBST
20 else
21   case `(set -o) 2>/dev/null` in
22   *posix*) set -o posix ;;
23 esac
24
25 fi
26
27
28
29
30 # PATH needs CR
31 # Avoid depending upon Character Ranges.
32 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
33 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
34 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
35 as_cr_digits='0123456789'
36 as_cr_alnum=$as_cr_Letters$as_cr_digits
37
38 # The user is always right.
39 if test "${PATH_SEPARATOR+set}" != set; then
40   echo "#! /bin/sh" >conf$$.sh
41   echo  "exit 0"   >>conf$$.sh
42   chmod +x conf$$.sh
43   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
44     PATH_SEPARATOR=';'
45   else
46     PATH_SEPARATOR=:
47   fi
48   rm -f conf$$.sh
49 fi
50
51 # Support unset when possible.
52 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
53   as_unset=unset
54 else
55   as_unset=false
56 fi
57
58
59 # IFS
60 # We need space, tab and new line, in precisely that order.  Quoting is
61 # there to prevent editors from complaining about space-tab.
62 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
63 # splitting by setting IFS to empty value.)
64 as_nl='
65 '
66 IFS=" ""        $as_nl"
67
68 # Find who we are.  Look in the path if we contain no directory separator.
69 case $0 in
70   *[\\/]* ) as_myself=$0 ;;
71   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
72 for as_dir in $PATH
73 do
74   IFS=$as_save_IFS
75   test -z "$as_dir" && as_dir=.
76   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
77 done
78 IFS=$as_save_IFS
79
80      ;;
81 esac
82 # We did not find ourselves, most probably we were run as `sh COMMAND'
83 # in which case we are not to be found in the path.
84 if test "x$as_myself" = x; then
85   as_myself=$0
86 fi
87 if test ! -f "$as_myself"; then
88   echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
89   { (exit 1); exit 1; }
90 fi
91
92 # Work around bugs in pre-3.0 UWIN ksh.
93 for as_var in ENV MAIL MAILPATH
94 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
95 done
96 PS1='$ '
97 PS2='> '
98 PS4='+ '
99
100 # NLS nuisances.
101 for as_var in \
102   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
103   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
104   LC_TELEPHONE LC_TIME
105 do
106   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
107     eval $as_var=C; export $as_var
108   else
109     ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
110   fi
111 done
112
113 # Required to use basename.
114 if expr a : '\(a\)' >/dev/null 2>&1 &&
115    test "X`expr 00001 : '.*\(...\)'`" = X001; then
116   as_expr=expr
117 else
118   as_expr=false
119 fi
120
121 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
122   as_basename=basename
123 else
124   as_basename=false
125 fi
126
127
128 # Name of the executable.
129 as_me=`$as_basename -- "$0" ||
130 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
131          X"$0" : 'X\(//\)$' \| \
132          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
133 echo X/"$0" |
134     sed '/^.*\/\([^/][^/]*\)\/*$/{
135             s//\1/
136             q
137           }
138           /^X\/\(\/\/\)$/{
139             s//\1/
140             q
141           }
142           /^X\/\(\/\).*/{
143             s//\1/
144             q
145           }
146           s/.*/./; q'`
147
148 # CDPATH.
149 $as_unset CDPATH
150
151
152 if test "x$CONFIG_SHELL" = x; then
153   if (eval ":") 2>/dev/null; then
154   as_have_required=yes
155 else
156   as_have_required=no
157 fi
158
159   if test $as_have_required = yes &&     (eval ":
160 (as_func_return () {
161   (exit \$1)
162 }
163 as_func_success () {
164   as_func_return 0
165 }
166 as_func_failure () {
167   as_func_return 1
168 }
169 as_func_ret_success () {
170   return 0
171 }
172 as_func_ret_failure () {
173   return 1
174 }
175
176 exitcode=0
177 if as_func_success; then
178   :
179 else
180   exitcode=1
181   echo as_func_success failed.
182 fi
183
184 if as_func_failure; then
185   exitcode=1
186   echo as_func_failure succeeded.
187 fi
188
189 if as_func_ret_success; then
190   :
191 else
192   exitcode=1
193   echo as_func_ret_success failed.
194 fi
195
196 if as_func_ret_failure; then
197   exitcode=1
198   echo as_func_ret_failure succeeded.
199 fi
200
201 if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
202   :
203 else
204   exitcode=1
205   echo positional parameters were not saved.
206 fi
207
208 test \$exitcode = 0) || { (exit 1); exit 1; }
209
210 (
211   as_lineno_1=\$LINENO
212   as_lineno_2=\$LINENO
213   test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" &&
214   test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; }
215 ") 2> /dev/null; then
216   :
217 else
218   as_candidate_shells=
219     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
220 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
221 do
222   IFS=$as_save_IFS
223   test -z "$as_dir" && as_dir=.
224   case $as_dir in
225          /*)
226            for as_base in sh bash ksh sh5; do
227              as_candidate_shells="$as_candidate_shells $as_dir/$as_base"
228            done;;
229        esac
230 done
231 IFS=$as_save_IFS
232
233
234       for as_shell in $as_candidate_shells $SHELL; do
235          # Try only shells that exist, to save several forks.
236          if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
237                 { ("$as_shell") 2> /dev/null <<\_ASEOF
238 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
239   emulate sh
240   NULLCMD=:
241   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
242   # is contrary to our usage.  Disable this feature.
243   alias -g '${1+"$@"}'='"$@"'
244   setopt NO_GLOB_SUBST
245 else
246   case `(set -o) 2>/dev/null` in
247   *posix*) set -o posix ;;
248 esac
249
250 fi
251
252
253 :
254 _ASEOF
255 }; then
256   CONFIG_SHELL=$as_shell
257                as_have_required=yes
258                if { "$as_shell" 2> /dev/null <<\_ASEOF
259 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
260   emulate sh
261   NULLCMD=:
262   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
263   # is contrary to our usage.  Disable this feature.
264   alias -g '${1+"$@"}'='"$@"'
265   setopt NO_GLOB_SUBST
266 else
267   case `(set -o) 2>/dev/null` in
268   *posix*) set -o posix ;;
269 esac
270
271 fi
272
273
274 :
275 (as_func_return () {
276   (exit $1)
277 }
278 as_func_success () {
279   as_func_return 0
280 }
281 as_func_failure () {
282   as_func_return 1
283 }
284 as_func_ret_success () {
285   return 0
286 }
287 as_func_ret_failure () {
288   return 1
289 }
290
291 exitcode=0
292 if as_func_success; then
293   :
294 else
295   exitcode=1
296   echo as_func_success failed.
297 fi
298
299 if as_func_failure; then
300   exitcode=1
301   echo as_func_failure succeeded.
302 fi
303
304 if as_func_ret_success; then
305   :
306 else
307   exitcode=1
308   echo as_func_ret_success failed.
309 fi
310
311 if as_func_ret_failure; then
312   exitcode=1
313   echo as_func_ret_failure succeeded.
314 fi
315
316 if ( set x; as_func_ret_success y && test x = "$1" ); then
317   :
318 else
319   exitcode=1
320   echo positional parameters were not saved.
321 fi
322
323 test $exitcode = 0) || { (exit 1); exit 1; }
324
325 (
326   as_lineno_1=$LINENO
327   as_lineno_2=$LINENO
328   test "x$as_lineno_1" != "x$as_lineno_2" &&
329   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; }
330
331 _ASEOF
332 }; then
333   break
334 fi
335
336 fi
337
338       done
339
340       if test "x$CONFIG_SHELL" != x; then
341   for as_var in BASH_ENV ENV
342         do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
343         done
344         export CONFIG_SHELL
345         exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
346 fi
347
348
349     if test $as_have_required = no; then
350   echo This script requires a shell more modern than all the
351       echo shells that I found on your system.  Please install a
352       echo modern shell, or manually run the script under such a
353       echo shell if you do have one.
354       { (exit 1); exit 1; }
355 fi
356
357
358 fi
359
360 fi
361
362
363
364 (eval "as_func_return () {
365   (exit \$1)
366 }
367 as_func_success () {
368   as_func_return 0
369 }
370 as_func_failure () {
371   as_func_return 1
372 }
373 as_func_ret_success () {
374   return 0
375 }
376 as_func_ret_failure () {
377   return 1
378 }
379
380 exitcode=0
381 if as_func_success; then
382   :
383 else
384   exitcode=1
385   echo as_func_success failed.
386 fi
387
388 if as_func_failure; then
389   exitcode=1
390   echo as_func_failure succeeded.
391 fi
392
393 if as_func_ret_success; then
394   :
395 else
396   exitcode=1
397   echo as_func_ret_success failed.
398 fi
399
400 if as_func_ret_failure; then
401   exitcode=1
402   echo as_func_ret_failure succeeded.
403 fi
404
405 if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
406   :
407 else
408   exitcode=1
409   echo positional parameters were not saved.
410 fi
411
412 test \$exitcode = 0") || {
413   echo No shell found that supports shell functions.
414   echo Please tell autoconf@gnu.org about your system,
415   echo including any error possibly output before this
416   echo message
417 }
418
419
420
421   as_lineno_1=$LINENO
422   as_lineno_2=$LINENO
423   test "x$as_lineno_1" != "x$as_lineno_2" &&
424   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
425
426   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
427   # uniformly replaced by the line number.  The first 'sed' inserts a
428   # line-number line after each line using $LINENO; the second 'sed'
429   # does the real work.  The second script uses 'N' to pair each
430   # line-number line with the line containing $LINENO, and appends
431   # trailing '-' during substitution so that $LINENO is not a special
432   # case at line end.
433   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
434   # scripts with optimization help from Paolo Bonzini.  Blame Lee
435   # E. McMahon (1931-1989) for sed's syntax.  :-)
436   sed -n '
437     p
438     /[$]LINENO/=
439   ' <$as_myself |
440     sed '
441       s/[$]LINENO.*/&-/
442       t lineno
443       b
444       :lineno
445       N
446       :loop
447       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
448       t loop
449       s/-\n.*//
450     ' >$as_me.lineno &&
451   chmod +x "$as_me.lineno" ||
452     { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
453    { (exit 1); exit 1; }; }
454
455   # Don't try to exec as it changes $[0], causing all sort of problems
456   # (the dirname of $[0] is not the place where we might find the
457   # original and so on.  Autoconf is especially sensitive to this).
458   . "./$as_me.lineno"
459   # Exit status is that of the last command.
460   exit
461 }
462
463
464 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
465   as_dirname=dirname
466 else
467   as_dirname=false
468 fi
469
470 ECHO_C= ECHO_N= ECHO_T=
471 case `echo -n x` in
472 -n*)
473   case `echo 'x\c'` in
474   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
475   *)   ECHO_C='\c';;
476   esac;;
477 *)
478   ECHO_N='-n';;
479 esac
480
481 if expr a : '\(a\)' >/dev/null 2>&1 &&
482    test "X`expr 00001 : '.*\(...\)'`" = X001; then
483   as_expr=expr
484 else
485   as_expr=false
486 fi
487
488 rm -f conf$$ conf$$.exe conf$$.file
489 if test -d conf$$.dir; then
490   rm -f conf$$.dir/conf$$.file
491 else
492   rm -f conf$$.dir
493   mkdir conf$$.dir
494 fi
495 echo >conf$$.file
496 if ln -s conf$$.file conf$$ 2>/dev/null; then
497   as_ln_s='ln -s'
498   # ... but there are two gotchas:
499   # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
500   # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
501   # In both cases, we have to default to `cp -p'.
502   ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
503     as_ln_s='cp -p'
504 elif ln conf$$.file conf$$ 2>/dev/null; then
505   as_ln_s=ln
506 else
507   as_ln_s='cp -p'
508 fi
509 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
510 rmdir conf$$.dir 2>/dev/null
511
512 if mkdir -p . 2>/dev/null; then
513   as_mkdir_p=:
514 else
515   test -d ./-p && rmdir ./-p
516   as_mkdir_p=false
517 fi
518
519 if test -x / >/dev/null 2>&1; then
520   as_test_x='test -x'
521 else
522   if ls -dL / >/dev/null 2>&1; then
523     as_ls_L_option=L
524   else
525     as_ls_L_option=
526   fi
527   as_test_x='
528     eval sh -c '\''
529       if test -d "$1"; then
530         test -d "$1/.";
531       else
532         case $1 in
533         -*)set "./$1";;
534         esac;
535         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
536         ???[sx]*):;;*)false;;esac;fi
537     '\'' sh
538   '
539 fi
540 as_executable_p=$as_test_x
541
542 # Sed expression to map a string onto a valid CPP name.
543 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
544
545 # Sed expression to map a string onto a valid variable name.
546 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
547
548
549
550 SHELL=${CONFIG_SHELL-/bin/sh}
551
552 # How were we run?
553 at_cli_args="$@"
554
555 # Load the config file.
556 for at_file in atconfig atlocal
557 do
558   test -r $at_file || continue
559   . ./$at_file || { echo "$as_me: error: invalid content: $at_file" >&2
560    { (exit 1); exit 1; }; }
561 done
562
563 # Autoconf <=2.59b set at_top_builddir instead of at_top_build_prefix:
564 : ${at_top_build_prefix=$at_top_builddir}
565
566 # atconfig delivers names relative to the directory the test suite is
567 # in, but the groups themselves are run in testsuite-dir/group-dir.
568 if test -n "$at_top_srcdir"; then
569   builddir=../..
570   for at_dir in srcdir top_srcdir top_build_prefix
571   do
572     at_val=`eval echo '${'at_$at_dir'}'`
573     eval "$at_dir=\$at_val/../.."
574   done
575 fi
576
577 # Not all shells have the 'times' builtin; the subshell is needed to make
578 # sure we discard the 'times: not found' message from the shell.
579 at_times_p=false
580 (times) >/dev/null 2>&1 && at_times_p=:
581
582 # CLI Arguments to pass to the debugging scripts.
583 at_debug_args=
584 # -e sets to true
585 at_errexit_p=false
586 # Shall we be verbose?
587 at_verbose=:
588 at_quiet=echo
589
590 # Shall we keep the debug scripts?  Must be `:' when the suite is
591 # run by a debug script, so that the script doesn't remove itself.
592 at_debug_p=false
593 # Display help message?
594 at_help_p=false
595 # Display the version message?
596 at_version_p=false
597 # List test groups?
598 at_list_p=false
599 # Test groups to run
600 at_groups=
601
602 # The directory we are in.
603 at_dir=`pwd`
604 # The directory the whole suite works in.
605 # Should be absolutely to let the user `cd' at will.
606 at_suite_dir=$at_dir/$as_me.dir
607 # The file containing the suite.
608 at_suite_log=$at_dir/$as_me.log
609 # The file containing the location of the last AT_CHECK.
610 at_check_line_file=$at_suite_dir/at-check-line
611 # The file containing the exit status of the last command.
612 at_status_file=$at_suite_dir/at-status
613 # The files containing the output of the tested commands.
614 at_stdout=$at_suite_dir/at-stdout
615 at_stder1=$at_suite_dir/at-stder1
616 at_stderr=$at_suite_dir/at-stderr
617 # The file containing dates.
618 at_times_file=$at_suite_dir/at-times
619
620 # List of the tested programs.
621 at_tested='tar'
622 # List of the all the test groups.
623 at_groups_all=' 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77'
624 # As many question marks as there are digits in the last test group number.
625 # Used to normalize the test group numbers so that `ls' lists them in
626 # numerical order.
627 at_format='??'
628 # Description of all the test groups.
629 at_help_all="1;version.at:19;tar version;;
630 2;pipe.at:29;decompressing from stdin;pipe;
631 3;options.at:24;mixing options;options options00;
632 4;options02.at:26;interspersed options;options options02;
633 5;T-empty.at:26;files-from: empty entries;files-from empty;
634 6;T-null.at:21;files-from: 0-separated file without -0;files-from null T-null;
635 7;indexfile.at:26;tar --index-file=this_is_a_very_long_file_name_which_raises_issues.c --file=-;stdout indexfile;
636 8;verbose.at:26;tar cvf -;stdout verbose;
637 9;append.at:21;append;append append00;
638 10;append01.at:29;appending files with long names;append append01;
639 11;append02.at:40;append vs. create;append append02 append-gnu;
640 12;exclude.at:23;exclude;exclude;
641 13;delete01.at:23;deleting a member after a big one;delete delete01;
642 14;delete02.at:23;deleting a member from stdin archive;delete delete02;
643 15;delete03.at:21;deleting members with long names;delete delete03;
644 16;delete04.at:23;deleting a large last member;delete delete04;
645 17;delete05.at:27;deleting non-existing member;delete delete05;
646 18;extrac01.at:23;extract over an existing directory;extract extract01;
647 19;extrac02.at:23;extracting symlinks over an existing file;extract extract02 symlink;
648 20;extrac03.at:23;extraction loops;extract extract03;
649 21;extrac04.at:23;extract + fnmatch;extract extract04 fnmatch;
650 22;extrac05.at:30;extracting selected members from pax;extract extract05;
651 23;extrac06.at:33;mode of extracted directories;extract extract06 directory mode;
652 24;extrac07.at:27;extracting symlinks to a read-only dir;extract extract07 read-only symlink;
653 25;gzip.at:23;gzip;gzip;
654 26;incremental.at:23;incremental;incremental incr00;
655 27;incr01.at:27;restore broken symlinks from incremental;incremental incr01;
656 28;incr02.at:32;restoring timestamps from incremental;incremental timestamp restore incr02;
657 29;listed01.at:26;--listed for individual files;listed incremental listed01;
658 30;listed02.at:28;working --listed;listed incremental listed02;
659 31;incr03.at:28;renamed files in incrementals;incremental incr03 rename;
660 32;incr04.at:29;proper icontents initialization;incremental incr04 icontents;
661 33;rename01.at:24;renamed dirs in incrementals;incremental rename rename01;
662 34;rename02.at:24;move between hierarchies;incremental rename rename02;
663 35;rename03.at:23;cyclic renames;incremental rename rename03 cyclic-rename;
664 36;rename04.at:27;renamed directory containing subdirectories;incremental rename04 rename;
665 37;rename05.at:24;renamed subdirectories;incremental rename05 rename;
666 38;chtype.at:27;changed file types in incrementals;incremental chtype;
667 39;ignfail.at:23;ignfail;ignfail;
668 40;link01.at:33;link count gt 2;link01;
669 41;longv7.at:24;long names in V7 archives;longname longv7;
670 42;long01.at:28;long file names divisible by block size;longname long512;
671 43;lustar01.at:21;ustar: unsplittable file name;longname ustar lustar01;
672 44;lustar02.at:21;ustar: unsplittable path name;longname ustar lustar02;
673 45;lustar03.at:21;ustar: splitting long names;longname ustar lustar03;
674 46;multiv01.at:23;multivolume dumps from pipes;multivolume multiv multiv01;
675 47;multiv02.at:28;skipping a straddling member;multivolume multiv multiv02;
676 48;multiv03.at:30;MV archive & long filenames;multivolume multiv multiv03;
677 49;multiv04.at:36;split directory members in a MV archive;multivolume multiv incremental multiv04;
678 50;multiv05.at:26;Restoring after an out of sync volume;multivolume multiv multiv05 sync;
679 51;multiv06.at:27;Multivolumes with L=record_size;multivolume multiv multiv06;
680 52;old.at:23;old archives;old;
681 53;recurse.at:21;recurse;recurse;
682 54;same-order01.at:26;working -C with --same-order;same-order same-order01;
683 55;same-order02.at:25;multiple -C options;same-order same-order02;
684 56;shortrec.at:25;short records;shortrec.at;
685 57;sparse01.at:21;sparse files;sparse sparse01;
686 58;sparse02.at:21;extracting sparse file over a pipe;sparse sparse02;
687 59;sparse03.at:21;storing sparse files > 8G;sparse sparse03;
688 60;sparsemv.at:21;sparse files in MV archives;sparse multiv sparsemv;
689 61;spmvp00.at:21;sparse files in PAX MV archives, v.0.0;sparse multiv sparsemvp sparsemvp00;
690 62;spmvp01.at:21;sparse files in PAX MV archives, v.0.1;sparse multiv sparsemvp sparsemvp01;
691 63;spmvp10.at:21;sparse files in PAX MV archives, v.1.0;sparse multiv sparsemvp sparsemvp10;
692 64;update.at:27;update unchanged directories;update;
693 65;volume.at:23;volume;volume volcheck;
694 66;volsize.at:29;volume header size;volume volsize;
695 67;comprec.at:21;compressed format recognition;comprec;
696 68;shortfile.at:26;short input files;shortfile shortfile0;
697 69;shortupd.at:29;updating short archives;shortfile shortfile1 shortupd;
698 70;truncate.at:29;truncate;truncate filechange;
699 71;grow.at:24;grow;grow filechange;
700 72;gtarfail.at:21;gtarfail;star gtarfail;
701 73;gtarfail2.at:21;gtarfail2;star gtarfail2;
702 74;multi-fail.at:21;multi-fail;star multivolume multiv multi-fail;
703 75;ustar-big-2g.at:21;ustar-big-2g;star ustar-big-2g;
704 76;ustar-big-8g.at:21;ustar-big-8g;star ustar-big-8g;
705 77;pax-big-10g.at:21;pax-big-10g;star pax-big-10g;
706 "
707
708 at_prev=
709 for at_option
710 do
711   # If the previous option needs an argument, assign it.
712   if test -n "$at_prev"; then
713     at_option=$at_prev=$at_option
714     at_prev=
715   fi
716
717   case $at_option in
718   *=*) at_optarg=`expr "x$at_option" : 'x[^=]*=\(.*\)'` ;;
719   *)   at_optarg= ;;
720   esac
721
722   # Accept the important Cygnus configure options, so we can diagnose typos.
723
724   case $at_option in
725     --help | -h )
726         at_help_p=:
727         ;;
728
729     --list | -l )
730         at_list_p=:
731         ;;
732
733     --version | -V )
734         at_version_p=:
735         ;;
736
737     --clean | -c )
738         test -d "$at_suite_dir" &&
739           find "$at_suite_dir" -type d ! -perm -700 -exec chmod u+rwx \{\} \;
740         rm -f -r "$at_suite_dir" "$at_suite_log"
741         exit 0
742         ;;
743
744     --debug | -d )
745         at_debug_p=:
746         ;;
747
748     --errexit | -e )
749         at_debug_p=:
750         at_errexit_p=:
751         ;;
752
753     --verbose | -v )
754         at_verbose=echo; at_quiet=:
755         ;;
756
757     --trace | -x )
758         at_traceon='set -x'; at_traceoff='set +x'
759         ;;
760
761     [0-9] | [0-9][0-9] | [0-9][0-9][0-9] | [0-9][0-9][0-9][0-9])
762         at_groups="$at_groups$at_option "
763         ;;
764
765     # Ranges
766     [0-9]- | [0-9][0-9]- | [0-9][0-9][0-9]- | [0-9][0-9][0-9][0-9]-)
767         at_range_start=`echo $at_option |tr -d X-`
768         at_range=`echo " $at_groups_all " | \
769           sed -e 's/^.* \('$at_range_start' \)/\1/'`
770         at_groups="$at_groups$at_range "
771         ;;
772
773     -[0-9] | -[0-9][0-9] | -[0-9][0-9][0-9] | -[0-9][0-9][0-9][0-9])
774         at_range_end=`echo $at_option |tr -d X-`
775         at_range=`echo " $at_groups_all " | \
776           sed -e 's/\( '$at_range_end'\) .*$/\1/'`
777         at_groups="$at_groups$at_range "
778         ;;
779
780     [0-9]-[0-9] | [0-9]-[0-9][0-9] | [0-9]-[0-9][0-9][0-9] | \
781     [0-9]-[0-9][0-9][0-9][0-9] | [0-9][0-9]-[0-9][0-9] | \
782     [0-9][0-9]-[0-9][0-9][0-9] | [0-9][0-9]-[0-9][0-9][0-9][0-9] | \
783     [0-9][0-9][0-9]-[0-9][0-9][0-9] | \
784     [0-9][0-9][0-9]-[0-9][0-9][0-9][0-9] | \
785     [0-9][0-9][0-9][0-9]-[0-9][0-9][0-9][0-9] )
786         at_range_start=`expr $at_option : '\(.*\)-'`
787         at_range_end=`expr $at_option : '.*-\(.*\)'`
788         if test $at_range_start -gt $at_range_end; then
789           at_tmp=$at_range_end
790           at_range_end=$at_range_start
791           at_range_start=$at_tmp
792         fi
793         at_range=`echo " $at_groups_all " | \
794           sed -e 's/^.*\( '$at_range_start' \)/\1/' \
795               -e 's/\( '$at_range_end'\) .*$/\1/'`
796         at_groups="$at_groups$at_range "
797         ;;
798
799     # Keywords.
800     --keywords | -k )
801         at_prev=--keywords
802         ;;
803     --keywords=* )
804         at_groups_selected=$at_help_all
805         at_save_IFS=$IFS
806         IFS=,
807         set X $at_optarg
808         shift
809         IFS=$at_save_IFS
810         for at_keyword
811         do
812           at_invert=
813           case $at_keyword in
814           '!'*)
815             at_invert="-v"
816             at_keyword=`expr "X$at_keyword" : 'X!\(.*\)'`
817             ;;
818           esac
819           # It is on purpose that we match the test group titles too.
820           at_groups_selected=`echo "$at_groups_selected" |
821               grep -i $at_invert "^[1-9][^;]*;.*[; ]$at_keyword[ ;]"`
822         done
823         at_groups_selected=`echo "$at_groups_selected" | sed 's/;.*//'`
824         # Smash the newlines.
825         at_groups="$at_groups`echo $at_groups_selected` "
826         ;;
827
828     *=*)
829         at_envvar=`expr "x$at_option" : 'x\([^=]*\)='`
830         # Reject names that are not valid shell variable names.
831         expr "x$at_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
832           { echo "$as_me: error: invalid variable name: $at_envvar" >&2
833    { (exit 1); exit 1; }; }
834         at_value=`echo "$at_optarg" | sed "s/'/'\\\\\\\\''/g"`
835         eval "$at_envvar='$at_value'"
836         export $at_envvar
837         # Propagate to debug scripts.
838         at_debug_args="$at_debug_args $at_envvar='$at_value'"
839         ;;
840
841      *) echo "$as_me: invalid option: $at_option" >&2
842         echo "Try \`$0 --help' for more information." >&2
843         exit 1
844         ;;
845   esac
846 done
847
848 # Selected test groups.
849 if test -z "$at_groups"; then
850   at_groups=$at_groups_all
851 else
852   # Sort the tests, removing duplicates:
853   at_groups=`echo $at_groups | tr ' ' "$as_nl" | sort -nu`
854   # and add banners.  (Passing at_groups_all is tricky--see the comment
855   # starting with "Passing at_groups is tricky.")
856   at_groups=`echo "$at_groups$as_nl $at_groups_all" |
857     awk 'BEGIN { FS = "@" } # Effectively switch off field splitting.
858         /^$/ { next }  # Ignore the empty line.
859         !/ / { groups++; selected[$ 0] = 1; next }
860         # The last line, containing at_groups_all.
861         {
862                 n = split($ 0, a, " ")
863                 # If there are several tests, select their banners:
864                 if (groups > 1) {
865                         for (i = 1; i <= n; i++) {
866                                 if (a[i] ~ /^banner-/)
867                                         banner = a[i]
868                                 else if (banner != "" && selected[a[i]] == 1)
869                                         selected[banner] = 1
870                         }
871                 }
872                 for (i = 1; i <= n; i++)
873                         if (selected[a[i]] == 1)
874                                 list = list " " a[i]
875                 print list
876         }'`
877 fi
878
879 # Help message.
880 if $at_help_p; then
881   cat <<_ATEOF
882 Usage: $0 [OPTION]... [VARIABLE=VALUE]... [TESTS]
883
884 Run all the tests, or the selected TESTS, given by numeric ranges, and
885 save a detailed log file.  Upon failure, create debugging scripts.
886
887 You should not change environment variables unless explicitly passed
888 as command line arguments.  Set \`AUTOTEST_PATH' to select the executables
889 to exercise.  Each relative directory is expanded as build and source
890 directories relatively to the top level of this distribution.  E.g.,
891
892   $ $0 AUTOTEST_PATH=bin
893
894 possibly amounts into
895
896   PATH=/tmp/foo-1.0/bin:/src/foo-1.0/bin:\$PATH
897 _ATEOF
898 cat <<_ATEOF
899
900 Operation modes:
901   -h, --help     print the help message, then exit
902   -V, --version  print version number, then exit
903   -c, --clean    remove all the files this test suite might create and exit
904   -l, --list     describes all the tests, or the selected TESTS
905 _ATEOF
906 cat <<_ATEOF
907
908 Execution tuning:
909   -k, --keywords=KEYWORDS
910                  select the tests matching all the comma-separated KEYWORDS
911                  multiple \`-k' accumulate; prefixed \`!' negates a KEYWORD
912   -e, --errexit  abort as soon as a test fails; implies --debug
913   -v, --verbose  force more detailed output
914                  default for debugging scripts
915   -d, --debug    inhibit clean up and top-level logging
916                  default for debugging scripts
917   -x, --trace    enable tests shell tracing
918 _ATEOF
919 cat <<_ATEOF
920
921 Report bugs to <bug-tar@gnu.org>.
922 _ATEOF
923   exit 0
924 fi
925
926 # List of tests.
927 if $at_list_p; then
928   cat <<_ATEOF
929 GNU tar 1.21 test suite test groups:
930
931  NUM: FILE-NAME:LINE     TEST-GROUP-NAME
932       KEYWORDS
933
934 _ATEOF
935   # Passing at_groups is tricky.  We cannot use it to form a literal string
936   # or regexp because of the limitation of AIX awk.  And Solaris' awk
937   # doesn't grok more than 99 fields in a record, so we have to use `split'.
938   echo "$at_groups$as_nl$at_help_all" |
939     awk 'BEGIN { FS = ";" }
940          NR == 1 {
941            for (n = split($ 0, a, " "); n; n--) selected[a[n]] = 1
942            next
943          }
944          {
945            if (selected[$ 1]) {
946              printf " %3d: %-18s %s\n", $ 1, $ 2, $ 3
947              if ($ 4) printf "      %s\n", $ 4
948            }
949          }'
950   exit 0
951 fi
952 if $at_version_p; then
953   echo "$as_me (GNU tar 1.21)"
954   cat <<\_ACEOF
955
956 Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software
957 Foundation, Inc.
958 This test suite is free software; the Free Software Foundation gives
959 unlimited permission to copy, distribute and modify it.
960 _ACEOF
961   exit 0
962 fi
963
964 # Don't take risks: use only absolute directories in PATH.
965 #
966 # For stand-alone test suites, AUTOTEST_PATH is relative to `.'.
967 #
968 # For embedded test suites, AUTOTEST_PATH is relative to the top level
969 # of the package.  Then expand it into build/src parts, since users
970 # may create executables in both places.
971 AUTOTEST_PATH=`echo $AUTOTEST_PATH | sed "s&:&$PATH_SEPARATOR&g"`
972 at_path=
973 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
974 for as_dir in $AUTOTEST_PATH $PATH
975 do
976   IFS=$as_save_IFS
977   test -z "$as_dir" && as_dir=.
978   test -n "$at_path" && at_path=$at_path$PATH_SEPARATOR
979 case $as_dir in
980   [\\/]* | ?:[\\/]* )
981     at_path=$at_path$as_dir
982     ;;
983   * )
984     if test -z "$at_top_build_prefix"; then
985       # Stand-alone test suite.
986       at_path=$at_path$as_dir
987     else
988       # Embedded test suite.
989       at_path=$at_path$at_top_build_prefix$as_dir$PATH_SEPARATOR
990       at_path=$at_path$at_top_srcdir/$as_dir
991     fi
992     ;;
993 esac
994 done
995 IFS=$as_save_IFS
996
997
998 # Now build and simplify PATH.
999 #
1000 # There might be directories that don't exist, but don't redirect
1001 # builtins' (eg., cd) stderr directly: Ultrix's sh hates that.
1002 PATH=
1003 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1004 for as_dir in $at_path
1005 do
1006   IFS=$as_save_IFS
1007   test -z "$as_dir" && as_dir=.
1008   as_dir=`(cd "$as_dir" && pwd) 2>/dev/null`
1009 test -d "$as_dir" || continue
1010 case $PATH in
1011                   $as_dir                 | \
1012                   $as_dir$PATH_SEPARATOR* | \
1013   *$PATH_SEPARATOR$as_dir                 | \
1014   *$PATH_SEPARATOR$as_dir$PATH_SEPARATOR* ) ;;
1015
1016   '') PATH=$as_dir ;;
1017    *) PATH=$PATH$PATH_SEPARATOR$as_dir ;;
1018 esac
1019 done
1020 IFS=$as_save_IFS
1021
1022 export PATH
1023
1024 # Setting up the FDs.
1025 # 5 is the log file.  Not to be overwritten if `-d'.
1026
1027 if $at_debug_p; then
1028   at_suite_log=/dev/null
1029 else
1030   : >"$at_suite_log"
1031 fi
1032 exec 5>>"$at_suite_log"
1033
1034 # Banners and logs.
1035 cat <<\_ASBOX
1036 ## ------------------------ ##
1037 ## GNU tar 1.21 test suite. ##
1038 ## ------------------------ ##
1039 _ASBOX
1040 {
1041   cat <<\_ASBOX
1042 ## ------------------------ ##
1043 ## GNU tar 1.21 test suite. ##
1044 ## ------------------------ ##
1045 _ASBOX
1046   echo
1047
1048   echo "$as_me: command line was:"
1049   echo "  $ $0 $at_cli_args"
1050   echo
1051
1052   # Try to find a few ChangeLogs in case it might help determining the
1053   # exact version.  Use the relative dir: if the top dir is a symlink,
1054   # find will not follow it (and options to follow the links are not
1055   # portable), which would result in no output here.
1056   if test -n "$at_top_srcdir"; then
1057     cat <<\_ASBOX
1058 ## ----------- ##
1059 ## ChangeLogs. ##
1060 ## ----------- ##
1061 _ASBOX
1062     echo
1063     for at_file in `find "$at_top_srcdir" -name ChangeLog -print`
1064     do
1065       echo "$as_me: $at_file:"
1066       sed 's/^/| /;10q' $at_file
1067       echo
1068     done
1069
1070     {
1071 cat <<_ASUNAME
1072 ## --------- ##
1073 ## Platform. ##
1074 ## --------- ##
1075
1076 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1077 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1078 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1079 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1080 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1081
1082 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1083 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1084
1085 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1086 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1087 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1088 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
1089 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1090 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1091 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1092
1093 _ASUNAME
1094
1095 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1096 for as_dir in $PATH
1097 do
1098   IFS=$as_save_IFS
1099   test -z "$as_dir" && as_dir=.
1100   echo "PATH: $as_dir"
1101 done
1102 IFS=$as_save_IFS
1103
1104 }
1105     echo
1106   fi
1107
1108   # Contents of the config files.
1109   for at_file in atconfig atlocal
1110   do
1111     test -r $at_file || continue
1112     echo "$as_me: $at_file:"
1113     sed 's/^/| /' $at_file
1114     echo
1115   done
1116
1117   cat <<\_ASBOX
1118 ## ---------------- ##
1119 ## Tested programs. ##
1120 ## ---------------- ##
1121 _ASBOX
1122   echo
1123 } >&5
1124
1125 # Report what programs are being tested.
1126 for at_program in : $at_tested
1127 do
1128   test "$at_program" = : && continue
1129   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1130 for as_dir in $PATH
1131 do
1132   IFS=$as_save_IFS
1133   test -z "$as_dir" && as_dir=.
1134   test -f "$as_dir/$at_program" && break
1135 done
1136 IFS=$as_save_IFS
1137
1138   if test -f "$as_dir/$at_program"; then
1139     {
1140       echo "$at_srcdir/testsuite.at:92: $as_dir/$at_program --version"
1141       "$as_dir/$at_program" --version
1142       echo
1143     } >&5 2>&1
1144   else
1145     { { echo "$as_me:$LINENO: error: cannot find $at_program" >&5
1146 echo "$as_me: error: cannot find $at_program" >&2;}
1147    { (exit 1); exit 1; }; }
1148   fi
1149 done
1150
1151 {
1152   cat <<\_ASBOX
1153 ## ------------------ ##
1154 ## Running the tests. ##
1155 ## ------------------ ##
1156 _ASBOX
1157 } >&5
1158
1159 at_start_date=`date`
1160 at_start_time=`date +%s 2>/dev/null`
1161 echo "$as_me: starting at: $at_start_date" >&5
1162 at_xpass_list=
1163 at_xfail_list=
1164 at_pass_list=
1165 at_fail_list=
1166 at_skip_list=
1167 at_group_count=0
1168
1169 # Create the master directory if it doesn't already exist.
1170 test -d "$at_suite_dir" ||
1171   mkdir "$at_suite_dir" ||
1172   { { echo "$as_me:$LINENO: error: cannot create '$at_suite_dir'" >&5
1173 echo "$as_me: error: cannot create '$at_suite_dir'" >&2;}
1174    { (exit 1); exit 1; }; }
1175
1176 # Can we diff with `/dev/null'?  DU 5.0 refuses.
1177 if diff /dev/null /dev/null >/dev/null 2>&1; then
1178   at_devnull=/dev/null
1179 else
1180   at_devnull=$at_suite_dir/devnull
1181   >"$at_devnull"
1182 fi
1183
1184 # Use `diff -u' when possible.
1185 if at_diff=`diff -u "$at_devnull" "$at_devnull" 2>&1` && test -z "$at_diff"
1186 then
1187   at_diff='diff -u'
1188 else
1189   at_diff=diff
1190 fi
1191
1192
1193 for at_group in $at_groups
1194 do
1195   # Be sure to come back to the top test directory.
1196   cd "$at_suite_dir"
1197
1198   case $at_group in
1199     banner-*)
1200       at_group_log=$at_suite_log
1201       ;;
1202
1203     *)
1204       at_group_normalized=$at_group
1205
1206   while :; do
1207     case $at_group_normalized in #(
1208     $at_format*) break;;
1209     esac
1210     at_group_normalized=0$at_group_normalized
1211   done
1212
1213
1214       # Create a fresh directory for the next test group, and enter.
1215       at_group_dir=$at_suite_dir/$at_group_normalized
1216       at_group_log=$at_group_dir/$as_me.log
1217       if test -d "$at_group_dir"; then
1218         find "$at_group_dir" -type d ! -perm -700 -exec chmod u+rwx \{\} \;
1219         rm -fr "$at_group_dir"
1220       fi
1221       # Be tolerant if the above `rm' was not able to remove the directory.
1222       { as_dir=$at_group_dir
1223   case $as_dir in #(
1224   -*) as_dir=./$as_dir;;
1225   esac
1226   test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
1227     as_dirs=
1228     while :; do
1229       case $as_dir in #(
1230       *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #(
1231       *) as_qdir=$as_dir;;
1232       esac
1233       as_dirs="'$as_qdir' $as_dirs"
1234       as_dir=`$as_dirname -- "$as_dir" ||
1235 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1236          X"$as_dir" : 'X\(//\)[^/]' \| \
1237          X"$as_dir" : 'X\(//\)$' \| \
1238          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
1239 echo X"$as_dir" |
1240     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1241             s//\1/
1242             q
1243           }
1244           /^X\(\/\/\)[^/].*/{
1245             s//\1/
1246             q
1247           }
1248           /^X\(\/\/\)$/{
1249             s//\1/
1250             q
1251           }
1252           /^X\(\/\).*/{
1253             s//\1/
1254             q
1255           }
1256           s/.*/./; q'`
1257       test -d "$as_dir" && break
1258     done
1259     test -z "$as_dirs" || eval "mkdir $as_dirs"
1260   } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
1261 echo "$as_me: error: cannot create directory $as_dir" >&2;}
1262    { (exit 1); exit 1; }; }; }
1263       cd $at_group_dir
1264       ;;
1265   esac
1266
1267   echo 0 > "$at_status_file"
1268
1269   # Clearly separate the test groups when verbose.
1270   test $at_group_count != 0 && $at_verbose
1271
1272   # In verbose mode, append to the log file *and* show on
1273   # the standard output; in quiet mode only write to the log
1274   if test $at_verbose = echo; then
1275     at_tee_pipe='tee -a "$at_group_log"'
1276   else
1277     at_tee_pipe='cat >> "$at_group_log"'
1278   fi
1279
1280   case $at_group in
1281   1 ) # 1. version.at:19: tar version
1282     at_setup_line='version.at:19'
1283     at_desc="tar version"
1284     $at_quiet $ECHO_N "  1: tar version                                    $ECHO_C"
1285     at_xfail=no
1286     echo "#                             -*- compilation -*-" >> "$at_group_log"
1287     (
1288       echo "1. version.at:19: testing ..."
1289       $at_traceon
1290
1291
1292 $at_traceoff
1293 echo "$at_srcdir/version.at:21: tar --version | sed 1q"
1294 echo version.at:21 >"$at_check_line_file"
1295
1296 at_trace_this=
1297 if test -n "$at_traceon"; then
1298     at_trace_this=yes
1299 fi
1300
1301 if test -n "$at_trace_this"; then
1302     ( $at_traceon; tar --version | sed 1q ) >"$at_stdout" 2>"$at_stder1"
1303     at_status=$?
1304     grep '^ *+' "$at_stder1" >&2
1305     grep -v '^ *+' "$at_stder1" >"$at_stderr"
1306 else
1307     ( :; tar --version | sed 1q ) >"$at_stdout" 2>"$at_stderr"
1308     at_status=$?
1309 fi
1310
1311 at_failed=false
1312 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
1313 echo >>"$at_stdout"; echo "tar (GNU tar) 1.21
1314 " | $at_diff - "$at_stdout" || at_failed=:
1315 case $at_status in
1316    77) echo 77 > "$at_status_file"; exit 77;;
1317    0) ;;
1318    *) echo "$at_srcdir/version.at:21: exit code was $at_status, expected 0"
1319       at_failed=:;;
1320 esac
1321 if $at_failed; then
1322   cat >$XFAILFILE <<'_EOT'
1323
1324 ==============================================================
1325 WARNING: Not using the proper version, *all* checks dubious...
1326 ==============================================================
1327 _EOT
1328
1329
1330   echo 1 > "$at_status_file"
1331   exit 1
1332 else
1333   rm -f $XFAILFILE
1334 fi
1335
1336 $at_traceon
1337
1338
1339       $at_traceoff
1340       $at_times_p && times >"$at_times_file"
1341     ) 5>&1 2>&1 | eval $at_tee_pipe
1342     at_status=`cat "$at_status_file"`
1343     ;;
1344
1345   2 ) # 2. pipe.at:29: decompressing from stdin
1346     at_setup_line='pipe.at:29'
1347     at_desc="decompressing from stdin"
1348     $at_quiet $ECHO_N "  2: decompressing from stdin                       $ECHO_C"
1349     at_xfail=no
1350       test -f $XFAILFILE && at_xfail=yes
1351     echo "#                             -*- compilation -*-" >> "$at_group_log"
1352     (
1353       echo "2. pipe.at:29: testing ..."
1354       $at_traceon
1355
1356
1357
1358
1359
1360
1361   $at_traceoff
1362 echo "$at_srcdir/pipe.at:33:
1363 mkdir v7
1364 (cd v7
1365 TEST_TAR_FORMAT=v7
1366 export TEST_TAR_FORMAT
1367 TAR_OPTIONS=\"-H v7\"
1368 export TAR_OPTIONS
1369 rm -rf *
1370
1371
1372 test -z "`sort < /dev/null 2>&1`" || exit 77
1373
1374
1375 mkdir directory
1376 genfile --length 10240 --pattern zeros --file directory/file1
1377 genfile --length 13 --file directory/file2
1378 tar cf archive directory|sort
1379 mv directory orig
1380 cat archive | tar xfv - | sort
1381 echo \"separator\"
1382 cmp orig/file1 directory/file1
1383 echo \"separator\"
1384 cmp orig/file2 directory/file2)"
1385 echo pipe.at:33 >"$at_check_line_file"
1386
1387 at_trace_this=
1388 if test -n "$at_traceon"; then
1389     echo 'Not enabling shell tracing (command contains an embedded newline)'
1390 fi
1391
1392 if test -n "$at_trace_this"; then
1393     ( $at_traceon;
1394 mkdir v7
1395 (cd v7
1396 TEST_TAR_FORMAT=v7
1397 export TEST_TAR_FORMAT
1398 TAR_OPTIONS="-H v7"
1399 export TAR_OPTIONS
1400 rm -rf *
1401
1402
1403 test -z "`sort < /dev/null 2>&1`" || exit 77
1404
1405
1406 mkdir directory
1407 genfile --length 10240 --pattern zeros --file directory/file1
1408 genfile --length 13 --file directory/file2
1409 tar cf archive directory|sort
1410 mv directory orig
1411 cat archive | tar xfv - | sort
1412 echo "separator"
1413 cmp orig/file1 directory/file1
1414 echo "separator"
1415 cmp orig/file2 directory/file2) ) >"$at_stdout" 2>"$at_stder1"
1416     at_status=$?
1417     grep '^ *+' "$at_stder1" >&2
1418     grep -v '^ *+' "$at_stder1" >"$at_stderr"
1419 else
1420     ( :;
1421 mkdir v7
1422 (cd v7
1423 TEST_TAR_FORMAT=v7
1424 export TEST_TAR_FORMAT
1425 TAR_OPTIONS="-H v7"
1426 export TAR_OPTIONS
1427 rm -rf *
1428
1429
1430 test -z "`sort < /dev/null 2>&1`" || exit 77
1431
1432
1433 mkdir directory
1434 genfile --length 10240 --pattern zeros --file directory/file1
1435 genfile --length 13 --file directory/file2
1436 tar cf archive directory|sort
1437 mv directory orig
1438 cat archive | tar xfv - | sort
1439 echo "separator"
1440 cmp orig/file1 directory/file1
1441 echo "separator"
1442 cmp orig/file2 directory/file2) ) >"$at_stdout" 2>"$at_stderr"
1443     at_status=$?
1444 fi
1445
1446 at_failed=false
1447 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
1448 echo >>"$at_stdout"; echo "directory/
1449 directory/file1
1450 directory/file2
1451 separator
1452 separator
1453 " | $at_diff - "$at_stdout" || at_failed=:
1454 case $at_status in
1455    77) echo 77 > "$at_status_file"; exit 77;;
1456    0) ;;
1457    *) echo "$at_srcdir/pipe.at:33: exit code was $at_status, expected 0"
1458       at_failed=:;;
1459 esac
1460 if $at_failed; then
1461
1462
1463   echo 1 > "$at_status_file"
1464   exit 1
1465 fi
1466
1467 $at_traceon
1468 $at_traceoff
1469 echo "$at_srcdir/pipe.at:33:
1470 mkdir oldgnu
1471 (cd oldgnu
1472 TEST_TAR_FORMAT=oldgnu
1473 export TEST_TAR_FORMAT
1474 TAR_OPTIONS=\"-H oldgnu\"
1475 export TAR_OPTIONS
1476 rm -rf *
1477
1478
1479 test -z "`sort < /dev/null 2>&1`" || exit 77
1480
1481
1482 mkdir directory
1483 genfile --length 10240 --pattern zeros --file directory/file1
1484 genfile --length 13 --file directory/file2
1485 tar cf archive directory|sort
1486 mv directory orig
1487 cat archive | tar xfv - | sort
1488 echo \"separator\"
1489 cmp orig/file1 directory/file1
1490 echo \"separator\"
1491 cmp orig/file2 directory/file2)"
1492 echo pipe.at:33 >"$at_check_line_file"
1493
1494 at_trace_this=
1495 if test -n "$at_traceon"; then
1496     echo 'Not enabling shell tracing (command contains an embedded newline)'
1497 fi
1498
1499 if test -n "$at_trace_this"; then
1500     ( $at_traceon;
1501 mkdir oldgnu
1502 (cd oldgnu
1503 TEST_TAR_FORMAT=oldgnu
1504 export TEST_TAR_FORMAT
1505 TAR_OPTIONS="-H oldgnu"
1506 export TAR_OPTIONS
1507 rm -rf *
1508
1509
1510 test -z "`sort < /dev/null 2>&1`" || exit 77
1511
1512
1513 mkdir directory
1514 genfile --length 10240 --pattern zeros --file directory/file1
1515 genfile --length 13 --file directory/file2
1516 tar cf archive directory|sort
1517 mv directory orig
1518 cat archive | tar xfv - | sort
1519 echo "separator"
1520 cmp orig/file1 directory/file1
1521 echo "separator"
1522 cmp orig/file2 directory/file2) ) >"$at_stdout" 2>"$at_stder1"
1523     at_status=$?
1524     grep '^ *+' "$at_stder1" >&2
1525     grep -v '^ *+' "$at_stder1" >"$at_stderr"
1526 else
1527     ( :;
1528 mkdir oldgnu
1529 (cd oldgnu
1530 TEST_TAR_FORMAT=oldgnu
1531 export TEST_TAR_FORMAT
1532 TAR_OPTIONS="-H oldgnu"
1533 export TAR_OPTIONS
1534 rm -rf *
1535
1536
1537 test -z "`sort < /dev/null 2>&1`" || exit 77
1538
1539
1540 mkdir directory
1541 genfile --length 10240 --pattern zeros --file directory/file1
1542 genfile --length 13 --file directory/file2
1543 tar cf archive directory|sort
1544 mv directory orig
1545 cat archive | tar xfv - | sort
1546 echo "separator"
1547 cmp orig/file1 directory/file1
1548 echo "separator"
1549 cmp orig/file2 directory/file2) ) >"$at_stdout" 2>"$at_stderr"
1550     at_status=$?
1551 fi
1552
1553 at_failed=false
1554 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
1555 echo >>"$at_stdout"; echo "directory/
1556 directory/file1
1557 directory/file2
1558 separator
1559 separator
1560 " | $at_diff - "$at_stdout" || at_failed=:
1561 case $at_status in
1562    77) echo 77 > "$at_status_file"; exit 77;;
1563    0) ;;
1564    *) echo "$at_srcdir/pipe.at:33: exit code was $at_status, expected 0"
1565       at_failed=:;;
1566 esac
1567 if $at_failed; then
1568
1569
1570   echo 1 > "$at_status_file"
1571   exit 1
1572 fi
1573
1574 $at_traceon
1575 $at_traceoff
1576 echo "$at_srcdir/pipe.at:33:
1577 mkdir ustar
1578 (cd ustar
1579 TEST_TAR_FORMAT=ustar
1580 export TEST_TAR_FORMAT
1581 TAR_OPTIONS=\"-H ustar\"
1582 export TAR_OPTIONS
1583 rm -rf *
1584
1585
1586 test -z "`sort < /dev/null 2>&1`" || exit 77
1587
1588
1589 mkdir directory
1590 genfile --length 10240 --pattern zeros --file directory/file1
1591 genfile --length 13 --file directory/file2
1592 tar cf archive directory|sort
1593 mv directory orig
1594 cat archive | tar xfv - | sort
1595 echo \"separator\"
1596 cmp orig/file1 directory/file1
1597 echo \"separator\"
1598 cmp orig/file2 directory/file2)"
1599 echo pipe.at:33 >"$at_check_line_file"
1600
1601 at_trace_this=
1602 if test -n "$at_traceon"; then
1603     echo 'Not enabling shell tracing (command contains an embedded newline)'
1604 fi
1605
1606 if test -n "$at_trace_this"; then
1607     ( $at_traceon;
1608 mkdir ustar
1609 (cd ustar
1610 TEST_TAR_FORMAT=ustar
1611 export TEST_TAR_FORMAT
1612 TAR_OPTIONS="-H ustar"
1613 export TAR_OPTIONS
1614 rm -rf *
1615
1616
1617 test -z "`sort < /dev/null 2>&1`" || exit 77
1618
1619
1620 mkdir directory
1621 genfile --length 10240 --pattern zeros --file directory/file1
1622 genfile --length 13 --file directory/file2
1623 tar cf archive directory|sort
1624 mv directory orig
1625 cat archive | tar xfv - | sort
1626 echo "separator"
1627 cmp orig/file1 directory/file1
1628 echo "separator"
1629 cmp orig/file2 directory/file2) ) >"$at_stdout" 2>"$at_stder1"
1630     at_status=$?
1631     grep '^ *+' "$at_stder1" >&2
1632     grep -v '^ *+' "$at_stder1" >"$at_stderr"
1633 else
1634     ( :;
1635 mkdir ustar
1636 (cd ustar
1637 TEST_TAR_FORMAT=ustar
1638 export TEST_TAR_FORMAT
1639 TAR_OPTIONS="-H ustar"
1640 export TAR_OPTIONS
1641 rm -rf *
1642
1643
1644 test -z "`sort < /dev/null 2>&1`" || exit 77
1645
1646
1647 mkdir directory
1648 genfile --length 10240 --pattern zeros --file directory/file1
1649 genfile --length 13 --file directory/file2
1650 tar cf archive directory|sort
1651 mv directory orig
1652 cat archive | tar xfv - | sort
1653 echo "separator"
1654 cmp orig/file1 directory/file1
1655 echo "separator"
1656 cmp orig/file2 directory/file2) ) >"$at_stdout" 2>"$at_stderr"
1657     at_status=$?
1658 fi
1659
1660 at_failed=false
1661 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
1662 echo >>"$at_stdout"; echo "directory/
1663 directory/file1
1664 directory/file2
1665 separator
1666 separator
1667 " | $at_diff - "$at_stdout" || at_failed=:
1668 case $at_status in
1669    77) echo 77 > "$at_status_file"; exit 77;;
1670    0) ;;
1671    *) echo "$at_srcdir/pipe.at:33: exit code was $at_status, expected 0"
1672       at_failed=:;;
1673 esac
1674 if $at_failed; then
1675
1676
1677   echo 1 > "$at_status_file"
1678   exit 1
1679 fi
1680
1681 $at_traceon
1682 $at_traceoff
1683 echo "$at_srcdir/pipe.at:33:
1684 mkdir posix
1685 (cd posix
1686 TEST_TAR_FORMAT=posix
1687 export TEST_TAR_FORMAT
1688 TAR_OPTIONS=\"-H posix\"
1689 export TAR_OPTIONS
1690 rm -rf *
1691
1692
1693 test -z "`sort < /dev/null 2>&1`" || exit 77
1694
1695
1696 mkdir directory
1697 genfile --length 10240 --pattern zeros --file directory/file1
1698 genfile --length 13 --file directory/file2
1699 tar cf archive directory|sort
1700 mv directory orig
1701 cat archive | tar xfv - | sort
1702 echo \"separator\"
1703 cmp orig/file1 directory/file1
1704 echo \"separator\"
1705 cmp orig/file2 directory/file2)"
1706 echo pipe.at:33 >"$at_check_line_file"
1707
1708 at_trace_this=
1709 if test -n "$at_traceon"; then
1710     echo 'Not enabling shell tracing (command contains an embedded newline)'
1711 fi
1712
1713 if test -n "$at_trace_this"; then
1714     ( $at_traceon;
1715 mkdir posix
1716 (cd posix
1717 TEST_TAR_FORMAT=posix
1718 export TEST_TAR_FORMAT
1719 TAR_OPTIONS="-H posix"
1720 export TAR_OPTIONS
1721 rm -rf *
1722
1723
1724 test -z "`sort < /dev/null 2>&1`" || exit 77
1725
1726
1727 mkdir directory
1728 genfile --length 10240 --pattern zeros --file directory/file1
1729 genfile --length 13 --file directory/file2
1730 tar cf archive directory|sort
1731 mv directory orig
1732 cat archive | tar xfv - | sort
1733 echo "separator"
1734 cmp orig/file1 directory/file1
1735 echo "separator"
1736 cmp orig/file2 directory/file2) ) >"$at_stdout" 2>"$at_stder1"
1737     at_status=$?
1738     grep '^ *+' "$at_stder1" >&2
1739     grep -v '^ *+' "$at_stder1" >"$at_stderr"
1740 else
1741     ( :;
1742 mkdir posix
1743 (cd posix
1744 TEST_TAR_FORMAT=posix
1745 export TEST_TAR_FORMAT
1746 TAR_OPTIONS="-H posix"
1747 export TAR_OPTIONS
1748 rm -rf *
1749
1750
1751 test -z "`sort < /dev/null 2>&1`" || exit 77
1752
1753
1754 mkdir directory
1755 genfile --length 10240 --pattern zeros --file directory/file1
1756 genfile --length 13 --file directory/file2
1757 tar cf archive directory|sort
1758 mv directory orig
1759 cat archive | tar xfv - | sort
1760 echo "separator"
1761 cmp orig/file1 directory/file1
1762 echo "separator"
1763 cmp orig/file2 directory/file2) ) >"$at_stdout" 2>"$at_stderr"
1764     at_status=$?
1765 fi
1766
1767 at_failed=false
1768 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
1769 echo >>"$at_stdout"; echo "directory/
1770 directory/file1
1771 directory/file2
1772 separator
1773 separator
1774 " | $at_diff - "$at_stdout" || at_failed=:
1775 case $at_status in
1776    77) echo 77 > "$at_status_file"; exit 77;;
1777    0) ;;
1778    *) echo "$at_srcdir/pipe.at:33: exit code was $at_status, expected 0"
1779       at_failed=:;;
1780 esac
1781 if $at_failed; then
1782
1783
1784   echo 1 > "$at_status_file"
1785   exit 1
1786 fi
1787
1788 $at_traceon
1789 $at_traceoff
1790 echo "$at_srcdir/pipe.at:33:
1791 mkdir gnu
1792 (cd gnu
1793 TEST_TAR_FORMAT=gnu
1794 export TEST_TAR_FORMAT
1795 TAR_OPTIONS=\"-H gnu\"
1796 export TAR_OPTIONS
1797 rm -rf *
1798
1799
1800 test -z "`sort < /dev/null 2>&1`" || exit 77
1801
1802
1803 mkdir directory
1804 genfile --length 10240 --pattern zeros --file directory/file1
1805 genfile --length 13 --file directory/file2
1806 tar cf archive directory|sort
1807 mv directory orig
1808 cat archive | tar xfv - | sort
1809 echo \"separator\"
1810 cmp orig/file1 directory/file1
1811 echo \"separator\"
1812 cmp orig/file2 directory/file2)"
1813 echo pipe.at:33 >"$at_check_line_file"
1814
1815 at_trace_this=
1816 if test -n "$at_traceon"; then
1817     echo 'Not enabling shell tracing (command contains an embedded newline)'
1818 fi
1819
1820 if test -n "$at_trace_this"; then
1821     ( $at_traceon;
1822 mkdir gnu
1823 (cd gnu
1824 TEST_TAR_FORMAT=gnu
1825 export TEST_TAR_FORMAT
1826 TAR_OPTIONS="-H gnu"
1827 export TAR_OPTIONS
1828 rm -rf *
1829
1830
1831 test -z "`sort < /dev/null 2>&1`" || exit 77
1832
1833
1834 mkdir directory
1835 genfile --length 10240 --pattern zeros --file directory/file1
1836 genfile --length 13 --file directory/file2
1837 tar cf archive directory|sort
1838 mv directory orig
1839 cat archive | tar xfv - | sort
1840 echo "separator"
1841 cmp orig/file1 directory/file1
1842 echo "separator"
1843 cmp orig/file2 directory/file2) ) >"$at_stdout" 2>"$at_stder1"
1844     at_status=$?
1845     grep '^ *+' "$at_stder1" >&2
1846     grep -v '^ *+' "$at_stder1" >"$at_stderr"
1847 else
1848     ( :;
1849 mkdir gnu
1850 (cd gnu
1851 TEST_TAR_FORMAT=gnu
1852 export TEST_TAR_FORMAT
1853 TAR_OPTIONS="-H gnu"
1854 export TAR_OPTIONS
1855 rm -rf *
1856
1857
1858 test -z "`sort < /dev/null 2>&1`" || exit 77
1859
1860
1861 mkdir directory
1862 genfile --length 10240 --pattern zeros --file directory/file1
1863 genfile --length 13 --file directory/file2
1864 tar cf archive directory|sort
1865 mv directory orig
1866 cat archive | tar xfv - | sort
1867 echo "separator"
1868 cmp orig/file1 directory/file1
1869 echo "separator"
1870 cmp orig/file2 directory/file2) ) >"$at_stdout" 2>"$at_stderr"
1871     at_status=$?
1872 fi
1873
1874 at_failed=false
1875 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
1876 echo >>"$at_stdout"; echo "directory/
1877 directory/file1
1878 directory/file2
1879 separator
1880 separator
1881 " | $at_diff - "$at_stdout" || at_failed=:
1882 case $at_status in
1883    77) echo 77 > "$at_status_file"; exit 77;;
1884    0) ;;
1885    *) echo "$at_srcdir/pipe.at:33: exit code was $at_status, expected 0"
1886       at_failed=:;;
1887 esac
1888 if $at_failed; then
1889
1890
1891   echo 1 > "$at_status_file"
1892   exit 1
1893 fi
1894
1895 $at_traceon
1896
1897
1898
1899       $at_traceoff
1900       $at_times_p && times >"$at_times_file"
1901     ) 5>&1 2>&1 | eval $at_tee_pipe
1902     at_status=`cat "$at_status_file"`
1903     ;;
1904
1905   3 ) # 3. options.at:24: mixing options
1906     at_setup_line='options.at:24'
1907     at_desc="mixing options"
1908     $at_quiet $ECHO_N "  3: mixing options                                 $ECHO_C"
1909     at_xfail=no
1910     echo "#                             -*- compilation -*-" >> "$at_group_log"
1911     (
1912       echo "3. options.at:24: testing ..."
1913       $at_traceon
1914
1915
1916
1917 $at_traceoff
1918 echo "$at_srcdir/options.at:27:
1919 echo > file1
1920 TAR_OPTIONS=--numeric-owner tar chof archive file1
1921 tar tf archive
1922 "
1923 echo options.at:27 >"$at_check_line_file"
1924
1925 at_trace_this=
1926 if test -n "$at_traceon"; then
1927     echo 'Not enabling shell tracing (command contains an embedded newline)'
1928 fi
1929
1930 if test -n "$at_trace_this"; then
1931     ( $at_traceon;
1932 echo > file1
1933 TAR_OPTIONS=--numeric-owner tar chof archive file1
1934 tar tf archive
1935  ) >"$at_stdout" 2>"$at_stder1"
1936     at_status=$?
1937     grep '^ *+' "$at_stder1" >&2
1938     grep -v '^ *+' "$at_stder1" >"$at_stderr"
1939 else
1940     ( :;
1941 echo > file1
1942 TAR_OPTIONS=--numeric-owner tar chof archive file1
1943 tar tf archive
1944  ) >"$at_stdout" 2>"$at_stderr"
1945     at_status=$?
1946 fi
1947
1948 at_failed=false
1949 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
1950 echo >>"$at_stdout"; echo "file1
1951 " | $at_diff - "$at_stdout" || at_failed=:
1952 case $at_status in
1953    77) echo 77 > "$at_status_file"; exit 77;;
1954    0) ;;
1955    *) echo "$at_srcdir/options.at:27: exit code was $at_status, expected 0"
1956       at_failed=:;;
1957 esac
1958 if $at_failed; then
1959
1960
1961   echo 1 > "$at_status_file"
1962   exit 1
1963 fi
1964
1965 $at_traceon
1966
1967
1968       $at_traceoff
1969       $at_times_p && times >"$at_times_file"
1970     ) 5>&1 2>&1 | eval $at_tee_pipe
1971     at_status=`cat "$at_status_file"`
1972     ;;
1973
1974   4 ) # 4. options02.at:26: interspersed options
1975     at_setup_line='options02.at:26'
1976     at_desc="interspersed options"
1977     $at_quiet $ECHO_N "  4: interspersed options                           $ECHO_C"
1978     at_xfail=no
1979     echo "#                             -*- compilation -*-" >> "$at_group_log"
1980     (
1981       echo "4. options02.at:26: testing ..."
1982       $at_traceon
1983
1984
1985
1986 $at_traceoff
1987 echo "$at_srcdir/options02.at:29:
1988 echo > file1
1989 tar c file1 -f archive
1990 tar tf archive
1991 "
1992 echo options02.at:29 >"$at_check_line_file"
1993
1994 at_trace_this=
1995 if test -n "$at_traceon"; then
1996     echo 'Not enabling shell tracing (command contains an embedded newline)'
1997 fi
1998
1999 if test -n "$at_trace_this"; then
2000     ( $at_traceon;
2001 echo > file1
2002 tar c file1 -f archive
2003 tar tf archive
2004  ) >"$at_stdout" 2>"$at_stder1"
2005     at_status=$?
2006     grep '^ *+' "$at_stder1" >&2
2007     grep -v '^ *+' "$at_stder1" >"$at_stderr"
2008 else
2009     ( :;
2010 echo > file1
2011 tar c file1 -f archive
2012 tar tf archive
2013  ) >"$at_stdout" 2>"$at_stderr"
2014     at_status=$?
2015 fi
2016
2017 at_failed=false
2018 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
2019 echo >>"$at_stdout"; echo "file1
2020 " | $at_diff - "$at_stdout" || at_failed=:
2021 case $at_status in
2022    77) echo 77 > "$at_status_file"; exit 77;;
2023    0) ;;
2024    *) echo "$at_srcdir/options02.at:29: exit code was $at_status, expected 0"
2025       at_failed=:;;
2026 esac
2027 if $at_failed; then
2028
2029
2030   echo 1 > "$at_status_file"
2031   exit 1
2032 fi
2033
2034 $at_traceon
2035
2036
2037       $at_traceoff
2038       $at_times_p && times >"$at_times_file"
2039     ) 5>&1 2>&1 | eval $at_tee_pipe
2040     at_status=`cat "$at_status_file"`
2041     ;;
2042
2043   5 ) # 5. T-empty.at:26: files-from: empty entries
2044     at_setup_line='T-empty.at:26'
2045     at_desc="files-from: empty entries"
2046     $at_quiet $ECHO_N "  5: files-from: empty entries                      $ECHO_C"
2047     at_xfail=no
2048       test -f $XFAILFILE && at_xfail=yes
2049     echo "#                             -*- compilation -*-" >> "$at_group_log"
2050     (
2051       echo "5. T-empty.at:26: testing ..."
2052       $at_traceon
2053
2054
2055
2056 cat >file-list <<'_ATEOF'
2057 jeden
2058 dwa
2059
2060 trzy
2061 _ATEOF
2062
2063
2064
2065
2066   $at_traceoff
2067 echo "$at_srcdir/T-empty.at:36:
2068 mkdir ustar
2069 (cd ustar
2070 TEST_TAR_FORMAT=ustar
2071 export TEST_TAR_FORMAT
2072 TAR_OPTIONS=\"-H ustar\"
2073 export TAR_OPTIONS
2074 rm -rf *
2075
2076
2077 test -z "`sort < /dev/null 2>&1`" || exit 77
2078
2079
2080 genfile --file jeden
2081 genfile --file dwa
2082 genfile --file trzy
2083
2084 tar cfvT archive ../file-list | sort
2085 )"
2086 echo T-empty.at:36 >"$at_check_line_file"
2087
2088 at_trace_this=
2089 if test -n "$at_traceon"; then
2090     echo 'Not enabling shell tracing (command contains an embedded newline)'
2091 fi
2092
2093 if test -n "$at_trace_this"; then
2094     ( $at_traceon;
2095 mkdir ustar
2096 (cd ustar
2097 TEST_TAR_FORMAT=ustar
2098 export TEST_TAR_FORMAT
2099 TAR_OPTIONS="-H ustar"
2100 export TAR_OPTIONS
2101 rm -rf *
2102
2103
2104 test -z "`sort < /dev/null 2>&1`" || exit 77
2105
2106
2107 genfile --file jeden
2108 genfile --file dwa
2109 genfile --file trzy
2110
2111 tar cfvT archive ../file-list | sort
2112 ) ) >"$at_stdout" 2>"$at_stder1"
2113     at_status=$?
2114     grep '^ *+' "$at_stder1" >&2
2115     grep -v '^ *+' "$at_stder1" >"$at_stderr"
2116 else
2117     ( :;
2118 mkdir ustar
2119 (cd ustar
2120 TEST_TAR_FORMAT=ustar
2121 export TEST_TAR_FORMAT
2122 TAR_OPTIONS="-H ustar"
2123 export TAR_OPTIONS
2124 rm -rf *
2125
2126
2127 test -z "`sort < /dev/null 2>&1`" || exit 77
2128
2129
2130 genfile --file jeden
2131 genfile --file dwa
2132 genfile --file trzy
2133
2134 tar cfvT archive ../file-list | sort
2135 ) ) >"$at_stdout" 2>"$at_stderr"
2136     at_status=$?
2137 fi
2138
2139 at_failed=false
2140 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
2141 echo >>"$at_stdout"; echo "dwa
2142 jeden
2143 trzy
2144 " | $at_diff - "$at_stdout" || at_failed=:
2145 case $at_status in
2146    77) echo 77 > "$at_status_file"; exit 77;;
2147    0) ;;
2148    *) echo "$at_srcdir/T-empty.at:36: exit code was $at_status, expected 0"
2149       at_failed=:;;
2150 esac
2151 if $at_failed; then
2152
2153
2154   echo 1 > "$at_status_file"
2155   exit 1
2156 fi
2157
2158 $at_traceon
2159
2160  # Testing one format is enough
2161
2162       $at_traceoff
2163       $at_times_p && times >"$at_times_file"
2164     ) 5>&1 2>&1 | eval $at_tee_pipe
2165     at_status=`cat "$at_status_file"`
2166     ;;
2167
2168   6 ) # 6. T-null.at:21: files-from: 0-separated file without -0
2169     at_setup_line='T-null.at:21'
2170     at_desc="files-from: 0-separated file without -0"
2171     $at_quiet $ECHO_N "  6: files-from: 0-separated file without -0        $ECHO_C"
2172     at_xfail=no
2173       test -f $XFAILFILE && at_xfail=yes
2174     echo "#                             -*- compilation -*-" >> "$at_group_log"
2175     (
2176       echo "6. T-null.at:21: testing ..."
2177       $at_traceon
2178
2179
2180
2181 cat >expout <<'_ATEOF'
2182 jeden\ndwa
2183 trzy
2184 _ATEOF
2185
2186
2187
2188
2189   $at_traceoff
2190 echo "$at_srcdir/T-null.at:28:
2191 mkdir ustar
2192 (cd ustar
2193 TEST_TAR_FORMAT=ustar
2194 export TEST_TAR_FORMAT
2195 TAR_OPTIONS=\"-H ustar\"
2196 export TAR_OPTIONS
2197 rm -rf *
2198
2199
2200 test -z "`sort < /dev/null 2>&1`" || exit 77
2201
2202
2203 echo dwa > temp
2204 echo trzy >> temp
2205 cat temp | tr '\\n' '\\0' > temp1
2206 echo jeden > file-list
2207 cat temp1 >> file-list
2208
2209 genfile -f \"jeden
2210 dwa\" || exit 77
2211 genfile -f trzy
2212
2213 tar cfTv archive file-list | sort
2214 )"
2215 echo T-null.at:28 >"$at_check_line_file"
2216
2217 at_trace_this=
2218 if test -n "$at_traceon"; then
2219     echo 'Not enabling shell tracing (command contains an embedded newline)'
2220 fi
2221
2222 if test -n "$at_trace_this"; then
2223     ( $at_traceon;
2224 mkdir ustar
2225 (cd ustar
2226 TEST_TAR_FORMAT=ustar
2227 export TEST_TAR_FORMAT
2228 TAR_OPTIONS="-H ustar"
2229 export TAR_OPTIONS
2230 rm -rf *
2231
2232
2233 test -z "`sort < /dev/null 2>&1`" || exit 77
2234
2235
2236 echo dwa > temp
2237 echo trzy >> temp
2238 cat temp | tr '\n' '\0' > temp1
2239 echo jeden > file-list
2240 cat temp1 >> file-list
2241
2242 genfile -f "jeden
2243 dwa" || exit 77
2244 genfile -f trzy
2245
2246 tar cfTv archive file-list | sort
2247 ) ) >"$at_stdout" 2>"$at_stder1"
2248     at_status=$?
2249     grep '^ *+' "$at_stder1" >&2
2250     grep -v '^ *+' "$at_stder1" >"$at_stderr"
2251 else
2252     ( :;
2253 mkdir ustar
2254 (cd ustar
2255 TEST_TAR_FORMAT=ustar
2256 export TEST_TAR_FORMAT
2257 TAR_OPTIONS="-H ustar"
2258 export TAR_OPTIONS
2259 rm -rf *
2260
2261
2262 test -z "`sort < /dev/null 2>&1`" || exit 77
2263
2264
2265 echo dwa > temp
2266 echo trzy >> temp
2267 cat temp | tr '\n' '\0' > temp1
2268 echo jeden > file-list
2269 cat temp1 >> file-list
2270
2271 genfile -f "jeden
2272 dwa" || exit 77
2273 genfile -f trzy
2274
2275 tar cfTv archive file-list | sort
2276 ) ) >"$at_stdout" 2>"$at_stderr"
2277     at_status=$?
2278 fi
2279
2280 at_failed=false
2281 echo >>"$at_stderr"; echo "tar: file-list: file name read contains nul character
2282 " | $at_diff - "$at_stderr" || at_failed=:
2283 $at_diff expout "$at_stdout" || at_failed=:
2284 case $at_status in
2285    77) echo 77 > "$at_status_file"; exit 77;;
2286    0) ;;
2287    *) echo "$at_srcdir/T-null.at:28: exit code was $at_status, expected 0"
2288       at_failed=:;;
2289 esac
2290 if $at_failed; then
2291
2292
2293   echo 1 > "$at_status_file"
2294   exit 1
2295 fi
2296
2297 $at_traceon
2298
2299  # Testing one format is enough
2300
2301       $at_traceoff
2302       $at_times_p && times >"$at_times_file"
2303     ) 5>&1 2>&1 | eval $at_tee_pipe
2304     at_status=`cat "$at_status_file"`
2305     ;;
2306
2307   7 ) # 7. indexfile.at:26: tar --index-file=FILE --file=-
2308     at_setup_line='indexfile.at:26'
2309     at_desc="tar --index-file=FILE --file=-"
2310     $at_quiet $ECHO_N "  7: tar --index-file=FILE --file=-                 $ECHO_C"
2311     at_xfail=no
2312       test -f $XFAILFILE && at_xfail=yes
2313     echo "#                             -*- compilation -*-" >> "$at_group_log"
2314     (
2315       echo "7. indexfile.at:26: testing ..."
2316       $at_traceon
2317
2318
2319
2320
2321
2322   $at_traceoff
2323 echo "$at_srcdir/indexfile.at:29:
2324 mkdir v7
2325 (cd v7
2326 TEST_TAR_FORMAT=v7
2327 export TEST_TAR_FORMAT
2328 TAR_OPTIONS=\"-H v7\"
2329 export TAR_OPTIONS
2330 rm -rf *
2331
2332
2333 mkdir directory
2334 genfile --file=directory/a --length=1035
2335
2336 echo \"Creating the archive\"
2337 tar -c -v -f - --index-file=idx directory > archive
2338
2339 echo \"Testing the archive\"
2340 tar -tf archive
2341 )"
2342 echo indexfile.at:29 >"$at_check_line_file"
2343
2344 at_trace_this=
2345 if test -n "$at_traceon"; then
2346     echo 'Not enabling shell tracing (command contains an embedded newline)'
2347 fi
2348
2349 if test -n "$at_trace_this"; then
2350     ( $at_traceon;
2351 mkdir v7
2352 (cd v7
2353 TEST_TAR_FORMAT=v7
2354 export TEST_TAR_FORMAT
2355 TAR_OPTIONS="-H v7"
2356 export TAR_OPTIONS
2357 rm -rf *
2358
2359
2360 mkdir directory
2361 genfile --file=directory/a --length=1035
2362
2363 echo "Creating the archive"
2364 tar -c -v -f - --index-file=idx directory > archive
2365
2366 echo "Testing the archive"
2367 tar -tf archive
2368 ) ) >"$at_stdout" 2>"$at_stder1"
2369     at_status=$?
2370     grep '^ *+' "$at_stder1" >&2
2371     grep -v '^ *+' "$at_stder1" >"$at_stderr"
2372 else
2373     ( :;
2374 mkdir v7
2375 (cd v7
2376 TEST_TAR_FORMAT=v7
2377 export TEST_TAR_FORMAT
2378 TAR_OPTIONS="-H v7"
2379 export TAR_OPTIONS
2380 rm -rf *
2381
2382
2383 mkdir directory
2384 genfile --file=directory/a --length=1035
2385
2386 echo "Creating the archive"
2387 tar -c -v -f - --index-file=idx directory > archive
2388
2389 echo "Testing the archive"
2390 tar -tf archive
2391 ) ) >"$at_stdout" 2>"$at_stderr"
2392     at_status=$?
2393 fi
2394
2395 at_failed=false
2396 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
2397 echo >>"$at_stdout"; echo "Creating the archive
2398 Testing the archive
2399 directory/
2400 directory/a
2401 " | $at_diff - "$at_stdout" || at_failed=:
2402 case $at_status in
2403    77) echo 77 > "$at_status_file"; exit 77;;
2404    0) ;;
2405    *) echo "$at_srcdir/indexfile.at:29: exit code was $at_status, expected 0"
2406       at_failed=:;;
2407 esac
2408 if $at_failed; then
2409
2410
2411   echo 1 > "$at_status_file"
2412   exit 1
2413 fi
2414
2415 $at_traceon
2416 $at_traceoff
2417 echo "$at_srcdir/indexfile.at:29:
2418 mkdir oldgnu
2419 (cd oldgnu
2420 TEST_TAR_FORMAT=oldgnu
2421 export TEST_TAR_FORMAT
2422 TAR_OPTIONS=\"-H oldgnu\"
2423 export TAR_OPTIONS
2424 rm -rf *
2425
2426
2427 mkdir directory
2428 genfile --file=directory/a --length=1035
2429
2430 echo \"Creating the archive\"
2431 tar -c -v -f - --index-file=idx directory > archive
2432
2433 echo \"Testing the archive\"
2434 tar -tf archive
2435 )"
2436 echo indexfile.at:29 >"$at_check_line_file"
2437
2438 at_trace_this=
2439 if test -n "$at_traceon"; then
2440     echo 'Not enabling shell tracing (command contains an embedded newline)'
2441 fi
2442
2443 if test -n "$at_trace_this"; then
2444     ( $at_traceon;
2445 mkdir oldgnu
2446 (cd oldgnu
2447 TEST_TAR_FORMAT=oldgnu
2448 export TEST_TAR_FORMAT
2449 TAR_OPTIONS="-H oldgnu"
2450 export TAR_OPTIONS
2451 rm -rf *
2452
2453
2454 mkdir directory
2455 genfile --file=directory/a --length=1035
2456
2457 echo "Creating the archive"
2458 tar -c -v -f - --index-file=idx directory > archive
2459
2460 echo "Testing the archive"
2461 tar -tf archive
2462 ) ) >"$at_stdout" 2>"$at_stder1"
2463     at_status=$?
2464     grep '^ *+' "$at_stder1" >&2
2465     grep -v '^ *+' "$at_stder1" >"$at_stderr"
2466 else
2467     ( :;
2468 mkdir oldgnu
2469 (cd oldgnu
2470 TEST_TAR_FORMAT=oldgnu
2471 export TEST_TAR_FORMAT
2472 TAR_OPTIONS="-H oldgnu"
2473 export TAR_OPTIONS
2474 rm -rf *
2475
2476
2477 mkdir directory
2478 genfile --file=directory/a --length=1035
2479
2480 echo "Creating the archive"
2481 tar -c -v -f - --index-file=idx directory > archive
2482
2483 echo "Testing the archive"
2484 tar -tf archive
2485 ) ) >"$at_stdout" 2>"$at_stderr"
2486     at_status=$?
2487 fi
2488
2489 at_failed=false
2490 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
2491 echo >>"$at_stdout"; echo "Creating the archive
2492 Testing the archive
2493 directory/
2494 directory/a
2495 " | $at_diff - "$at_stdout" || at_failed=:
2496 case $at_status in
2497    77) echo 77 > "$at_status_file"; exit 77;;
2498    0) ;;
2499    *) echo "$at_srcdir/indexfile.at:29: exit code was $at_status, expected 0"
2500       at_failed=:;;
2501 esac
2502 if $at_failed; then
2503
2504
2505   echo 1 > "$at_status_file"
2506   exit 1
2507 fi
2508
2509 $at_traceon
2510 $at_traceoff
2511 echo "$at_srcdir/indexfile.at:29:
2512 mkdir ustar
2513 (cd ustar
2514 TEST_TAR_FORMAT=ustar
2515 export TEST_TAR_FORMAT
2516 TAR_OPTIONS=\"-H ustar\"
2517 export TAR_OPTIONS
2518 rm -rf *
2519
2520
2521 mkdir directory
2522 genfile --file=directory/a --length=1035
2523
2524 echo \"Creating the archive\"
2525 tar -c -v -f - --index-file=idx directory > archive
2526
2527 echo \"Testing the archive\"
2528 tar -tf archive
2529 )"
2530 echo indexfile.at:29 >"$at_check_line_file"
2531
2532 at_trace_this=
2533 if test -n "$at_traceon"; then
2534     echo 'Not enabling shell tracing (command contains an embedded newline)'
2535 fi
2536
2537 if test -n "$at_trace_this"; then
2538     ( $at_traceon;
2539 mkdir ustar
2540 (cd ustar
2541 TEST_TAR_FORMAT=ustar
2542 export TEST_TAR_FORMAT
2543 TAR_OPTIONS="-H ustar"
2544 export TAR_OPTIONS
2545 rm -rf *
2546
2547
2548 mkdir directory
2549 genfile --file=directory/a --length=1035
2550
2551 echo "Creating the archive"
2552 tar -c -v -f - --index-file=idx directory > archive
2553
2554 echo "Testing the archive"
2555 tar -tf archive
2556 ) ) >"$at_stdout" 2>"$at_stder1"
2557     at_status=$?
2558     grep '^ *+' "$at_stder1" >&2
2559     grep -v '^ *+' "$at_stder1" >"$at_stderr"
2560 else
2561     ( :;
2562 mkdir ustar
2563 (cd ustar
2564 TEST_TAR_FORMAT=ustar
2565 export TEST_TAR_FORMAT
2566 TAR_OPTIONS="-H ustar"
2567 export TAR_OPTIONS
2568 rm -rf *
2569
2570
2571 mkdir directory
2572 genfile --file=directory/a --length=1035
2573
2574 echo "Creating the archive"
2575 tar -c -v -f - --index-file=idx directory > archive
2576
2577 echo "Testing the archive"
2578 tar -tf archive
2579 ) ) >"$at_stdout" 2>"$at_stderr"
2580     at_status=$?
2581 fi
2582
2583 at_failed=false
2584 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
2585 echo >>"$at_stdout"; echo "Creating the archive
2586 Testing the archive
2587 directory/
2588 directory/a
2589 " | $at_diff - "$at_stdout" || at_failed=:
2590 case $at_status in
2591    77) echo 77 > "$at_status_file"; exit 77;;
2592    0) ;;
2593    *) echo "$at_srcdir/indexfile.at:29: exit code was $at_status, expected 0"
2594       at_failed=:;;
2595 esac
2596 if $at_failed; then
2597
2598
2599   echo 1 > "$at_status_file"
2600   exit 1
2601 fi
2602
2603 $at_traceon
2604 $at_traceoff
2605 echo "$at_srcdir/indexfile.at:29:
2606 mkdir posix
2607 (cd posix
2608 TEST_TAR_FORMAT=posix
2609 export TEST_TAR_FORMAT
2610 TAR_OPTIONS=\"-H posix\"
2611 export TAR_OPTIONS
2612 rm -rf *
2613
2614
2615 mkdir directory
2616 genfile --file=directory/a --length=1035
2617
2618 echo \"Creating the archive\"
2619 tar -c -v -f - --index-file=idx directory > archive
2620
2621 echo \"Testing the archive\"
2622 tar -tf archive
2623 )"
2624 echo indexfile.at:29 >"$at_check_line_file"
2625
2626 at_trace_this=
2627 if test -n "$at_traceon"; then
2628     echo 'Not enabling shell tracing (command contains an embedded newline)'
2629 fi
2630
2631 if test -n "$at_trace_this"; then
2632     ( $at_traceon;
2633 mkdir posix
2634 (cd posix
2635 TEST_TAR_FORMAT=posix
2636 export TEST_TAR_FORMAT
2637 TAR_OPTIONS="-H posix"
2638 export TAR_OPTIONS
2639 rm -rf *
2640
2641
2642 mkdir directory
2643 genfile --file=directory/a --length=1035
2644
2645 echo "Creating the archive"
2646 tar -c -v -f - --index-file=idx directory > archive
2647
2648 echo "Testing the archive"
2649 tar -tf archive
2650 ) ) >"$at_stdout" 2>"$at_stder1"
2651     at_status=$?
2652     grep '^ *+' "$at_stder1" >&2
2653     grep -v '^ *+' "$at_stder1" >"$at_stderr"
2654 else
2655     ( :;
2656 mkdir posix
2657 (cd posix
2658 TEST_TAR_FORMAT=posix
2659 export TEST_TAR_FORMAT
2660 TAR_OPTIONS="-H posix"
2661 export TAR_OPTIONS
2662 rm -rf *
2663
2664
2665 mkdir directory
2666 genfile --file=directory/a --length=1035
2667
2668 echo "Creating the archive"
2669 tar -c -v -f - --index-file=idx directory > archive
2670
2671 echo "Testing the archive"
2672 tar -tf archive
2673 ) ) >"$at_stdout" 2>"$at_stderr"
2674     at_status=$?
2675 fi
2676
2677 at_failed=false
2678 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
2679 echo >>"$at_stdout"; echo "Creating the archive
2680 Testing the archive
2681 directory/
2682 directory/a
2683 " | $at_diff - "$at_stdout" || at_failed=:
2684 case $at_status in
2685    77) echo 77 > "$at_status_file"; exit 77;;
2686    0) ;;
2687    *) echo "$at_srcdir/indexfile.at:29: exit code was $at_status, expected 0"
2688       at_failed=:;;
2689 esac
2690 if $at_failed; then
2691
2692
2693   echo 1 > "$at_status_file"
2694   exit 1
2695 fi
2696
2697 $at_traceon
2698 $at_traceoff
2699 echo "$at_srcdir/indexfile.at:29:
2700 mkdir gnu
2701 (cd gnu
2702 TEST_TAR_FORMAT=gnu
2703 export TEST_TAR_FORMAT
2704 TAR_OPTIONS=\"-H gnu\"
2705 export TAR_OPTIONS
2706 rm -rf *
2707
2708
2709 mkdir directory
2710 genfile --file=directory/a --length=1035
2711
2712 echo \"Creating the archive\"
2713 tar -c -v -f - --index-file=idx directory > archive
2714
2715 echo \"Testing the archive\"
2716 tar -tf archive
2717 )"
2718 echo indexfile.at:29 >"$at_check_line_file"
2719
2720 at_trace_this=
2721 if test -n "$at_traceon"; then
2722     echo 'Not enabling shell tracing (command contains an embedded newline)'
2723 fi
2724
2725 if test -n "$at_trace_this"; then
2726     ( $at_traceon;
2727 mkdir gnu
2728 (cd gnu
2729 TEST_TAR_FORMAT=gnu
2730 export TEST_TAR_FORMAT
2731 TAR_OPTIONS="-H gnu"
2732 export TAR_OPTIONS
2733 rm -rf *
2734
2735
2736 mkdir directory
2737 genfile --file=directory/a --length=1035
2738
2739 echo "Creating the archive"
2740 tar -c -v -f - --index-file=idx directory > archive
2741
2742 echo "Testing the archive"
2743 tar -tf archive
2744 ) ) >"$at_stdout" 2>"$at_stder1"
2745     at_status=$?
2746     grep '^ *+' "$at_stder1" >&2
2747     grep -v '^ *+' "$at_stder1" >"$at_stderr"
2748 else
2749     ( :;
2750 mkdir gnu
2751 (cd gnu
2752 TEST_TAR_FORMAT=gnu
2753 export TEST_TAR_FORMAT
2754 TAR_OPTIONS="-H gnu"
2755 export TAR_OPTIONS
2756 rm -rf *
2757
2758
2759 mkdir directory
2760 genfile --file=directory/a --length=1035
2761
2762 echo "Creating the archive"
2763 tar -c -v -f - --index-file=idx directory > archive
2764
2765 echo "Testing the archive"
2766 tar -tf archive
2767 ) ) >"$at_stdout" 2>"$at_stderr"
2768     at_status=$?
2769 fi
2770
2771 at_failed=false
2772 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
2773 echo >>"$at_stdout"; echo "Creating the archive
2774 Testing the archive
2775 directory/
2776 directory/a
2777 " | $at_diff - "$at_stdout" || at_failed=:
2778 case $at_status in
2779    77) echo 77 > "$at_status_file"; exit 77;;
2780    0) ;;
2781    *) echo "$at_srcdir/indexfile.at:29: exit code was $at_status, expected 0"
2782       at_failed=:;;
2783 esac
2784 if $at_failed; then
2785
2786
2787   echo 1 > "$at_status_file"
2788   exit 1
2789 fi
2790
2791 $at_traceon
2792
2793
2794
2795       $at_traceoff
2796       $at_times_p && times >"$at_times_file"
2797     ) 5>&1 2>&1 | eval $at_tee_pipe
2798     at_status=`cat "$at_status_file"`
2799     ;;
2800
2801   8 ) # 8. verbose.at:26: tar cvf -
2802     at_setup_line='verbose.at:26'
2803     at_desc="tar cvf -"
2804     $at_quiet $ECHO_N "  8: tar cvf -                                      $ECHO_C"
2805     at_xfail=no
2806       test -f $XFAILFILE && at_xfail=yes
2807     echo "#                             -*- compilation -*-" >> "$at_group_log"
2808     (
2809       echo "8. verbose.at:26: testing ..."
2810       $at_traceon
2811
2812
2813
2814
2815
2816   $at_traceoff
2817 echo "$at_srcdir/verbose.at:29:
2818 mkdir v7
2819 (cd v7
2820 TEST_TAR_FORMAT=v7
2821 export TEST_TAR_FORMAT
2822 TAR_OPTIONS=\"-H v7\"
2823 export TAR_OPTIONS
2824 rm -rf *
2825
2826 genfile --file file --length 10240
2827 echo Creating the archive
2828 tar cvf - file > archive
2829 echo Testing the archive
2830 tar tf archive
2831 )"
2832 echo verbose.at:29 >"$at_check_line_file"
2833
2834 at_trace_this=
2835 if test -n "$at_traceon"; then
2836     echo 'Not enabling shell tracing (command contains an embedded newline)'
2837 fi
2838
2839 if test -n "$at_trace_this"; then
2840     ( $at_traceon;
2841 mkdir v7
2842 (cd v7
2843 TEST_TAR_FORMAT=v7
2844 export TEST_TAR_FORMAT
2845 TAR_OPTIONS="-H v7"
2846 export TAR_OPTIONS
2847 rm -rf *
2848
2849 genfile --file file --length 10240
2850 echo Creating the archive
2851 tar cvf - file > archive
2852 echo Testing the archive
2853 tar tf archive
2854 ) ) >"$at_stdout" 2>"$at_stder1"
2855     at_status=$?
2856     grep '^ *+' "$at_stder1" >&2
2857     grep -v '^ *+' "$at_stder1" >"$at_stderr"
2858 else
2859     ( :;
2860 mkdir v7
2861 (cd v7
2862 TEST_TAR_FORMAT=v7
2863 export TEST_TAR_FORMAT
2864 TAR_OPTIONS="-H v7"
2865 export TAR_OPTIONS
2866 rm -rf *
2867
2868 genfile --file file --length 10240
2869 echo Creating the archive
2870 tar cvf - file > archive
2871 echo Testing the archive
2872 tar tf archive
2873 ) ) >"$at_stdout" 2>"$at_stderr"
2874     at_status=$?
2875 fi
2876
2877 at_failed=false
2878 echo >>"$at_stderr"; echo "file
2879 " | $at_diff - "$at_stderr" || at_failed=:
2880 echo >>"$at_stdout"; echo "Creating the archive
2881 Testing the archive
2882 file
2883 " | $at_diff - "$at_stdout" || at_failed=:
2884 case $at_status in
2885    77) echo 77 > "$at_status_file"; exit 77;;
2886    0) ;;
2887    *) echo "$at_srcdir/verbose.at:29: exit code was $at_status, expected 0"
2888       at_failed=:;;
2889 esac
2890 if $at_failed; then
2891
2892
2893   echo 1 > "$at_status_file"
2894   exit 1
2895 fi
2896
2897 $at_traceon
2898 $at_traceoff
2899 echo "$at_srcdir/verbose.at:29:
2900 mkdir oldgnu
2901 (cd oldgnu
2902 TEST_TAR_FORMAT=oldgnu
2903 export TEST_TAR_FORMAT
2904 TAR_OPTIONS=\"-H oldgnu\"
2905 export TAR_OPTIONS
2906 rm -rf *
2907
2908 genfile --file file --length 10240
2909 echo Creating the archive
2910 tar cvf - file > archive
2911 echo Testing the archive
2912 tar tf archive
2913 )"
2914 echo verbose.at:29 >"$at_check_line_file"
2915
2916 at_trace_this=
2917 if test -n "$at_traceon"; then
2918     echo 'Not enabling shell tracing (command contains an embedded newline)'
2919 fi
2920
2921 if test -n "$at_trace_this"; then
2922     ( $at_traceon;
2923 mkdir oldgnu
2924 (cd oldgnu
2925 TEST_TAR_FORMAT=oldgnu
2926 export TEST_TAR_FORMAT
2927 TAR_OPTIONS="-H oldgnu"
2928 export TAR_OPTIONS
2929 rm -rf *
2930
2931 genfile --file file --length 10240
2932 echo Creating the archive
2933 tar cvf - file > archive
2934 echo Testing the archive
2935 tar tf archive
2936 ) ) >"$at_stdout" 2>"$at_stder1"
2937     at_status=$?
2938     grep '^ *+' "$at_stder1" >&2
2939     grep -v '^ *+' "$at_stder1" >"$at_stderr"
2940 else
2941     ( :;
2942 mkdir oldgnu
2943 (cd oldgnu
2944 TEST_TAR_FORMAT=oldgnu
2945 export TEST_TAR_FORMAT
2946 TAR_OPTIONS="-H oldgnu"
2947 export TAR_OPTIONS
2948 rm -rf *
2949
2950 genfile --file file --length 10240
2951 echo Creating the archive
2952 tar cvf - file > archive
2953 echo Testing the archive
2954 tar tf archive
2955 ) ) >"$at_stdout" 2>"$at_stderr"
2956     at_status=$?
2957 fi
2958
2959 at_failed=false
2960 echo >>"$at_stderr"; echo "file
2961 " | $at_diff - "$at_stderr" || at_failed=:
2962 echo >>"$at_stdout"; echo "Creating the archive
2963 Testing the archive
2964 file
2965 " | $at_diff - "$at_stdout" || at_failed=:
2966 case $at_status in
2967    77) echo 77 > "$at_status_file"; exit 77;;
2968    0) ;;
2969    *) echo "$at_srcdir/verbose.at:29: exit code was $at_status, expected 0"
2970       at_failed=:;;
2971 esac
2972 if $at_failed; then
2973
2974
2975   echo 1 > "$at_status_file"
2976   exit 1
2977 fi
2978
2979 $at_traceon
2980 $at_traceoff
2981 echo "$at_srcdir/verbose.at:29:
2982 mkdir ustar
2983 (cd ustar
2984 TEST_TAR_FORMAT=ustar
2985 export TEST_TAR_FORMAT
2986 TAR_OPTIONS=\"-H ustar\"
2987 export TAR_OPTIONS
2988 rm -rf *
2989
2990 genfile --file file --length 10240
2991 echo Creating the archive
2992 tar cvf - file > archive
2993 echo Testing the archive
2994 tar tf archive
2995 )"
2996 echo verbose.at:29 >"$at_check_line_file"
2997
2998 at_trace_this=
2999 if test -n "$at_traceon"; then
3000     echo 'Not enabling shell tracing (command contains an embedded newline)'
3001 fi
3002
3003 if test -n "$at_trace_this"; then
3004     ( $at_traceon;
3005 mkdir ustar
3006 (cd ustar
3007 TEST_TAR_FORMAT=ustar
3008 export TEST_TAR_FORMAT
3009 TAR_OPTIONS="-H ustar"
3010 export TAR_OPTIONS
3011 rm -rf *
3012
3013 genfile --file file --length 10240
3014 echo Creating the archive
3015 tar cvf - file > archive
3016 echo Testing the archive
3017 tar tf archive
3018 ) ) >"$at_stdout" 2>"$at_stder1"
3019     at_status=$?
3020     grep '^ *+' "$at_stder1" >&2
3021     grep -v '^ *+' "$at_stder1" >"$at_stderr"
3022 else
3023     ( :;
3024 mkdir ustar
3025 (cd ustar
3026 TEST_TAR_FORMAT=ustar
3027 export TEST_TAR_FORMAT
3028 TAR_OPTIONS="-H ustar"
3029 export TAR_OPTIONS
3030 rm -rf *
3031
3032 genfile --file file --length 10240
3033 echo Creating the archive
3034 tar cvf - file > archive
3035 echo Testing the archive
3036 tar tf archive
3037 ) ) >"$at_stdout" 2>"$at_stderr"
3038     at_status=$?
3039 fi
3040
3041 at_failed=false
3042 echo >>"$at_stderr"; echo "file
3043 " | $at_diff - "$at_stderr" || at_failed=:
3044 echo >>"$at_stdout"; echo "Creating the archive
3045 Testing the archive
3046 file
3047 " | $at_diff - "$at_stdout" || at_failed=:
3048 case $at_status in
3049    77) echo 77 > "$at_status_file"; exit 77;;
3050    0) ;;
3051    *) echo "$at_srcdir/verbose.at:29: exit code was $at_status, expected 0"
3052       at_failed=:;;
3053 esac
3054 if $at_failed; then
3055
3056
3057   echo 1 > "$at_status_file"
3058   exit 1
3059 fi
3060
3061 $at_traceon
3062 $at_traceoff
3063 echo "$at_srcdir/verbose.at:29:
3064 mkdir posix
3065 (cd posix
3066 TEST_TAR_FORMAT=posix
3067 export TEST_TAR_FORMAT
3068 TAR_OPTIONS=\"-H posix\"
3069 export TAR_OPTIONS
3070 rm -rf *
3071
3072 genfile --file file --length 10240
3073 echo Creating the archive
3074 tar cvf - file > archive
3075 echo Testing the archive
3076 tar tf archive
3077 )"
3078 echo verbose.at:29 >"$at_check_line_file"
3079
3080 at_trace_this=
3081 if test -n "$at_traceon"; then
3082     echo 'Not enabling shell tracing (command contains an embedded newline)'
3083 fi
3084
3085 if test -n "$at_trace_this"; then
3086     ( $at_traceon;
3087 mkdir posix
3088 (cd posix
3089 TEST_TAR_FORMAT=posix
3090 export TEST_TAR_FORMAT
3091 TAR_OPTIONS="-H posix"
3092 export TAR_OPTIONS
3093 rm -rf *
3094
3095 genfile --file file --length 10240
3096 echo Creating the archive
3097 tar cvf - file > archive
3098 echo Testing the archive
3099 tar tf archive
3100 ) ) >"$at_stdout" 2>"$at_stder1"
3101     at_status=$?
3102     grep '^ *+' "$at_stder1" >&2
3103     grep -v '^ *+' "$at_stder1" >"$at_stderr"
3104 else
3105     ( :;
3106 mkdir posix
3107 (cd posix
3108 TEST_TAR_FORMAT=posix
3109 export TEST_TAR_FORMAT
3110 TAR_OPTIONS="-H posix"
3111 export TAR_OPTIONS
3112 rm -rf *
3113
3114 genfile --file file --length 10240
3115 echo Creating the archive
3116 tar cvf - file > archive
3117 echo Testing the archive
3118 tar tf archive
3119 ) ) >"$at_stdout" 2>"$at_stderr"
3120     at_status=$?
3121 fi
3122
3123 at_failed=false
3124 echo >>"$at_stderr"; echo "file
3125 " | $at_diff - "$at_stderr" || at_failed=:
3126 echo >>"$at_stdout"; echo "Creating the archive
3127 Testing the archive
3128 file
3129 " | $at_diff - "$at_stdout" || at_failed=:
3130 case $at_status in
3131    77) echo 77 > "$at_status_file"; exit 77;;
3132    0) ;;
3133    *) echo "$at_srcdir/verbose.at:29: exit code was $at_status, expected 0"
3134       at_failed=:;;
3135 esac
3136 if $at_failed; then
3137
3138
3139   echo 1 > "$at_status_file"
3140   exit 1
3141 fi
3142
3143 $at_traceon
3144 $at_traceoff
3145 echo "$at_srcdir/verbose.at:29:
3146 mkdir gnu
3147 (cd gnu
3148 TEST_TAR_FORMAT=gnu
3149 export TEST_TAR_FORMAT
3150 TAR_OPTIONS=\"-H gnu\"
3151 export TAR_OPTIONS
3152 rm -rf *
3153
3154 genfile --file file --length 10240
3155 echo Creating the archive
3156 tar cvf - file > archive
3157 echo Testing the archive
3158 tar tf archive
3159 )"
3160 echo verbose.at:29 >"$at_check_line_file"
3161
3162 at_trace_this=
3163 if test -n "$at_traceon"; then
3164     echo 'Not enabling shell tracing (command contains an embedded newline)'
3165 fi
3166
3167 if test -n "$at_trace_this"; then
3168     ( $at_traceon;
3169 mkdir gnu
3170 (cd gnu
3171 TEST_TAR_FORMAT=gnu
3172 export TEST_TAR_FORMAT
3173 TAR_OPTIONS="-H gnu"
3174 export TAR_OPTIONS
3175 rm -rf *
3176
3177 genfile --file file --length 10240
3178 echo Creating the archive
3179 tar cvf - file > archive
3180 echo Testing the archive
3181 tar tf archive
3182 ) ) >"$at_stdout" 2>"$at_stder1"
3183     at_status=$?
3184     grep '^ *+' "$at_stder1" >&2
3185     grep -v '^ *+' "$at_stder1" >"$at_stderr"
3186 else
3187     ( :;
3188 mkdir gnu
3189 (cd gnu
3190 TEST_TAR_FORMAT=gnu
3191 export TEST_TAR_FORMAT
3192 TAR_OPTIONS="-H gnu"
3193 export TAR_OPTIONS
3194 rm -rf *
3195
3196 genfile --file file --length 10240
3197 echo Creating the archive
3198 tar cvf - file > archive
3199 echo Testing the archive
3200 tar tf archive
3201 ) ) >"$at_stdout" 2>"$at_stderr"
3202     at_status=$?
3203 fi
3204
3205 at_failed=false
3206 echo >>"$at_stderr"; echo "file
3207 " | $at_diff - "$at_stderr" || at_failed=:
3208 echo >>"$at_stdout"; echo "Creating the archive
3209 Testing the archive
3210 file
3211 " | $at_diff - "$at_stdout" || at_failed=:
3212 case $at_status in
3213    77) echo 77 > "$at_status_file"; exit 77;;
3214    0) ;;
3215    *) echo "$at_srcdir/verbose.at:29: exit code was $at_status, expected 0"
3216       at_failed=:;;
3217 esac
3218 if $at_failed; then
3219
3220
3221   echo 1 > "$at_status_file"
3222   exit 1
3223 fi
3224
3225 $at_traceon
3226
3227
3228
3229       $at_traceoff
3230       $at_times_p && times >"$at_times_file"
3231     ) 5>&1 2>&1 | eval $at_tee_pipe
3232     at_status=`cat "$at_status_file"`
3233     ;;
3234
3235   9 ) # 9. append.at:21: append
3236     at_setup_line='append.at:21'
3237     at_desc="append"
3238     $at_quiet $ECHO_N "  9: append                                         $ECHO_C"
3239     at_xfail=no
3240       test -f $XFAILFILE && at_xfail=yes
3241     echo "#                             -*- compilation -*-" >> "$at_group_log"
3242     (
3243       echo "9. append.at:21: testing ..."
3244       $at_traceon
3245
3246
3247
3248
3249
3250   $at_traceoff
3251 echo "$at_srcdir/append.at:24:
3252 mkdir v7
3253 (cd v7
3254 TEST_TAR_FORMAT=v7
3255 export TEST_TAR_FORMAT
3256 TAR_OPTIONS=\"-H v7\"
3257 export TAR_OPTIONS
3258 rm -rf *
3259 touch file1
3260           touch file2
3261           tar cf archive file1
3262           tar rf archive file2
3263           tar tf archive)"
3264 echo append.at:24 >"$at_check_line_file"
3265
3266 at_trace_this=
3267 if test -n "$at_traceon"; then
3268     echo 'Not enabling shell tracing (command contains an embedded newline)'
3269 fi
3270
3271 if test -n "$at_trace_this"; then
3272     ( $at_traceon;
3273 mkdir v7
3274 (cd v7
3275 TEST_TAR_FORMAT=v7
3276 export TEST_TAR_FORMAT
3277 TAR_OPTIONS="-H v7"
3278 export TAR_OPTIONS
3279 rm -rf *
3280 touch file1
3281           touch file2
3282           tar cf archive file1
3283           tar rf archive file2
3284           tar tf archive) ) >"$at_stdout" 2>"$at_stder1"
3285     at_status=$?
3286     grep '^ *+' "$at_stder1" >&2
3287     grep -v '^ *+' "$at_stder1" >"$at_stderr"
3288 else
3289     ( :;
3290 mkdir v7
3291 (cd v7
3292 TEST_TAR_FORMAT=v7
3293 export TEST_TAR_FORMAT
3294 TAR_OPTIONS="-H v7"
3295 export TAR_OPTIONS
3296 rm -rf *
3297 touch file1
3298           touch file2
3299           tar cf archive file1
3300           tar rf archive file2
3301           tar tf archive) ) >"$at_stdout" 2>"$at_stderr"
3302     at_status=$?
3303 fi
3304
3305 at_failed=false
3306 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
3307 echo >>"$at_stdout"; echo "file1
3308 file2
3309 " | $at_diff - "$at_stdout" || at_failed=:
3310 case $at_status in
3311    77) echo 77 > "$at_status_file"; exit 77;;
3312    0) ;;
3313    *) echo "$at_srcdir/append.at:24: exit code was $at_status, expected 0"
3314       at_failed=:;;
3315 esac
3316 if $at_failed; then
3317
3318
3319   echo 1 > "$at_status_file"
3320   exit 1
3321 fi
3322
3323 $at_traceon
3324 $at_traceoff
3325 echo "$at_srcdir/append.at:24:
3326 mkdir oldgnu
3327 (cd oldgnu
3328 TEST_TAR_FORMAT=oldgnu
3329 export TEST_TAR_FORMAT
3330 TAR_OPTIONS=\"-H oldgnu\"
3331 export TAR_OPTIONS
3332 rm -rf *
3333 touch file1
3334           touch file2
3335           tar cf archive file1
3336           tar rf archive file2
3337           tar tf archive)"
3338 echo append.at:24 >"$at_check_line_file"
3339
3340 at_trace_this=
3341 if test -n "$at_traceon"; then
3342     echo 'Not enabling shell tracing (command contains an embedded newline)'
3343 fi
3344
3345 if test -n "$at_trace_this"; then
3346     ( $at_traceon;
3347 mkdir oldgnu
3348 (cd oldgnu
3349 TEST_TAR_FORMAT=oldgnu
3350 export TEST_TAR_FORMAT
3351 TAR_OPTIONS="-H oldgnu"
3352 export TAR_OPTIONS
3353 rm -rf *
3354 touch file1
3355           touch file2
3356           tar cf archive file1
3357           tar rf archive file2
3358           tar tf archive) ) >"$at_stdout" 2>"$at_stder1"
3359     at_status=$?
3360     grep '^ *+' "$at_stder1" >&2
3361     grep -v '^ *+' "$at_stder1" >"$at_stderr"
3362 else
3363     ( :;
3364 mkdir oldgnu
3365 (cd oldgnu
3366 TEST_TAR_FORMAT=oldgnu
3367 export TEST_TAR_FORMAT
3368 TAR_OPTIONS="-H oldgnu"
3369 export TAR_OPTIONS
3370 rm -rf *
3371 touch file1
3372           touch file2
3373           tar cf archive file1
3374           tar rf archive file2
3375           tar tf archive) ) >"$at_stdout" 2>"$at_stderr"
3376     at_status=$?
3377 fi
3378
3379 at_failed=false
3380 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
3381 echo >>"$at_stdout"; echo "file1
3382 file2
3383 " | $at_diff - "$at_stdout" || at_failed=:
3384 case $at_status in
3385    77) echo 77 > "$at_status_file"; exit 77;;
3386    0) ;;
3387    *) echo "$at_srcdir/append.at:24: exit code was $at_status, expected 0"
3388       at_failed=:;;
3389 esac
3390 if $at_failed; then
3391
3392
3393   echo 1 > "$at_status_file"
3394   exit 1
3395 fi
3396
3397 $at_traceon
3398 $at_traceoff
3399 echo "$at_srcdir/append.at:24:
3400 mkdir ustar
3401 (cd ustar
3402 TEST_TAR_FORMAT=ustar
3403 export TEST_TAR_FORMAT
3404 TAR_OPTIONS=\"-H ustar\"
3405 export TAR_OPTIONS
3406 rm -rf *
3407 touch file1
3408           touch file2
3409           tar cf archive file1
3410           tar rf archive file2
3411           tar tf archive)"
3412 echo append.at:24 >"$at_check_line_file"
3413
3414 at_trace_this=
3415 if test -n "$at_traceon"; then
3416     echo 'Not enabling shell tracing (command contains an embedded newline)'
3417 fi
3418
3419 if test -n "$at_trace_this"; then
3420     ( $at_traceon;
3421 mkdir ustar
3422 (cd ustar
3423 TEST_TAR_FORMAT=ustar
3424 export TEST_TAR_FORMAT
3425 TAR_OPTIONS="-H ustar"
3426 export TAR_OPTIONS
3427 rm -rf *
3428 touch file1
3429           touch file2
3430           tar cf archive file1
3431           tar rf archive file2
3432           tar tf archive) ) >"$at_stdout" 2>"$at_stder1"
3433     at_status=$?
3434     grep '^ *+' "$at_stder1" >&2
3435     grep -v '^ *+' "$at_stder1" >"$at_stderr"
3436 else
3437     ( :;
3438 mkdir ustar
3439 (cd ustar
3440 TEST_TAR_FORMAT=ustar
3441 export TEST_TAR_FORMAT
3442 TAR_OPTIONS="-H ustar"
3443 export TAR_OPTIONS
3444 rm -rf *
3445 touch file1
3446           touch file2
3447           tar cf archive file1
3448           tar rf archive file2
3449           tar tf archive) ) >"$at_stdout" 2>"$at_stderr"
3450     at_status=$?
3451 fi
3452
3453 at_failed=false
3454 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
3455 echo >>"$at_stdout"; echo "file1
3456 file2
3457 " | $at_diff - "$at_stdout" || at_failed=:
3458 case $at_status in
3459    77) echo 77 > "$at_status_file"; exit 77;;
3460    0) ;;
3461    *) echo "$at_srcdir/append.at:24: exit code was $at_status, expected 0"
3462       at_failed=:;;
3463 esac
3464 if $at_failed; then
3465
3466
3467   echo 1 > "$at_status_file"
3468   exit 1
3469 fi
3470
3471 $at_traceon
3472 $at_traceoff
3473 echo "$at_srcdir/append.at:24:
3474 mkdir posix
3475 (cd posix
3476 TEST_TAR_FORMAT=posix
3477 export TEST_TAR_FORMAT
3478 TAR_OPTIONS=\"-H posix\"
3479 export TAR_OPTIONS
3480 rm -rf *
3481 touch file1
3482           touch file2
3483           tar cf archive file1
3484           tar rf archive file2
3485           tar tf archive)"
3486 echo append.at:24 >"$at_check_line_file"
3487
3488 at_trace_this=
3489 if test -n "$at_traceon"; then
3490     echo 'Not enabling shell tracing (command contains an embedded newline)'
3491 fi
3492
3493 if test -n "$at_trace_this"; then
3494     ( $at_traceon;
3495 mkdir posix
3496 (cd posix
3497 TEST_TAR_FORMAT=posix
3498 export TEST_TAR_FORMAT
3499 TAR_OPTIONS="-H posix"
3500 export TAR_OPTIONS
3501 rm -rf *
3502 touch file1
3503           touch file2
3504           tar cf archive file1
3505           tar rf archive file2
3506           tar tf archive) ) >"$at_stdout" 2>"$at_stder1"
3507     at_status=$?
3508     grep '^ *+' "$at_stder1" >&2
3509     grep -v '^ *+' "$at_stder1" >"$at_stderr"
3510 else
3511     ( :;
3512 mkdir posix
3513 (cd posix
3514 TEST_TAR_FORMAT=posix
3515 export TEST_TAR_FORMAT
3516 TAR_OPTIONS="-H posix"
3517 export TAR_OPTIONS
3518 rm -rf *
3519 touch file1
3520           touch file2
3521           tar cf archive file1
3522           tar rf archive file2
3523           tar tf archive) ) >"$at_stdout" 2>"$at_stderr"
3524     at_status=$?
3525 fi
3526
3527 at_failed=false
3528 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
3529 echo >>"$at_stdout"; echo "file1
3530 file2
3531 " | $at_diff - "$at_stdout" || at_failed=:
3532 case $at_status in
3533    77) echo 77 > "$at_status_file"; exit 77;;
3534    0) ;;
3535    *) echo "$at_srcdir/append.at:24: exit code was $at_status, expected 0"
3536       at_failed=:;;
3537 esac
3538 if $at_failed; then
3539
3540
3541   echo 1 > "$at_status_file"
3542   exit 1
3543 fi
3544
3545 $at_traceon
3546 $at_traceoff
3547 echo "$at_srcdir/append.at:24:
3548 mkdir gnu
3549 (cd gnu
3550 TEST_TAR_FORMAT=gnu
3551 export TEST_TAR_FORMAT
3552 TAR_OPTIONS=\"-H gnu\"
3553 export TAR_OPTIONS
3554 rm -rf *
3555 touch file1
3556           touch file2
3557           tar cf archive file1
3558           tar rf archive file2
3559           tar tf archive)"
3560 echo append.at:24 >"$at_check_line_file"
3561
3562 at_trace_this=
3563 if test -n "$at_traceon"; then
3564     echo 'Not enabling shell tracing (command contains an embedded newline)'
3565 fi
3566
3567 if test -n "$at_trace_this"; then
3568     ( $at_traceon;
3569 mkdir gnu
3570 (cd gnu
3571 TEST_TAR_FORMAT=gnu
3572 export TEST_TAR_FORMAT
3573 TAR_OPTIONS="-H gnu"
3574 export TAR_OPTIONS
3575 rm -rf *
3576 touch file1
3577           touch file2
3578           tar cf archive file1
3579           tar rf archive file2
3580           tar tf archive) ) >"$at_stdout" 2>"$at_stder1"
3581     at_status=$?
3582     grep '^ *+' "$at_stder1" >&2
3583     grep -v '^ *+' "$at_stder1" >"$at_stderr"
3584 else
3585     ( :;
3586 mkdir gnu
3587 (cd gnu
3588 TEST_TAR_FORMAT=gnu
3589 export TEST_TAR_FORMAT
3590 TAR_OPTIONS="-H gnu"
3591 export TAR_OPTIONS
3592 rm -rf *
3593 touch file1
3594           touch file2
3595           tar cf archive file1
3596           tar rf archive file2
3597           tar tf archive) ) >"$at_stdout" 2>"$at_stderr"
3598     at_status=$?
3599 fi
3600
3601 at_failed=false
3602 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
3603 echo >>"$at_stdout"; echo "file1
3604 file2
3605 " | $at_diff - "$at_stdout" || at_failed=:
3606 case $at_status in
3607    77) echo 77 > "$at_status_file"; exit 77;;
3608    0) ;;
3609    *) echo "$at_srcdir/append.at:24: exit code was $at_status, expected 0"
3610       at_failed=:;;
3611 esac
3612 if $at_failed; then
3613
3614
3615   echo 1 > "$at_status_file"
3616   exit 1
3617 fi
3618
3619 $at_traceon
3620
3621
3622
3623       $at_traceoff
3624       $at_times_p && times >"$at_times_file"
3625     ) 5>&1 2>&1 | eval $at_tee_pipe
3626     at_status=`cat "$at_status_file"`
3627     ;;
3628
3629   10 ) # 10. append01.at:29: appending files with long names
3630     at_setup_line='append01.at:29'
3631     at_desc="appending files with long names"
3632     $at_quiet $ECHO_N " 10: appending files with long names                $ECHO_C"
3633     at_xfail=no
3634       test -f $XFAILFILE && at_xfail=yes
3635     echo "#                             -*- compilation -*-" >> "$at_group_log"
3636     (
3637       echo "10. append01.at:29: testing ..."
3638       $at_traceon
3639
3640
3641
3642
3643
3644
3645
3646   $at_traceoff
3647 echo "$at_srcdir/append01.at:34:
3648 mkdir oldgnu
3649 (cd oldgnu
3650 TEST_TAR_FORMAT=oldgnu
3651 export TEST_TAR_FORMAT
3652 TAR_OPTIONS=\"-H oldgnu\"
3653 export TAR_OPTIONS
3654 rm -rf *
3655
3656 mkdir This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX
3657 touch This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1 This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3658 tar cf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1
3659 tar rf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3660 tar tf archive
3661 )"
3662 echo append01.at:34 >"$at_check_line_file"
3663
3664 at_trace_this=
3665 if test -n "$at_traceon"; then
3666     echo 'Not enabling shell tracing (command contains an embedded newline)'
3667 fi
3668
3669 if test -n "$at_trace_this"; then
3670     ( $at_traceon;
3671 mkdir oldgnu
3672 (cd oldgnu
3673 TEST_TAR_FORMAT=oldgnu
3674 export TEST_TAR_FORMAT
3675 TAR_OPTIONS="-H oldgnu"
3676 export TAR_OPTIONS
3677 rm -rf *
3678
3679 mkdir This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX
3680 touch This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1 This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3681 tar cf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1
3682 tar rf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3683 tar tf archive
3684 ) ) >"$at_stdout" 2>"$at_stder1"
3685     at_status=$?
3686     grep '^ *+' "$at_stder1" >&2
3687     grep -v '^ *+' "$at_stder1" >"$at_stderr"
3688 else
3689     ( :;
3690 mkdir oldgnu
3691 (cd oldgnu
3692 TEST_TAR_FORMAT=oldgnu
3693 export TEST_TAR_FORMAT
3694 TAR_OPTIONS="-H oldgnu"
3695 export TAR_OPTIONS
3696 rm -rf *
3697
3698 mkdir This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX
3699 touch This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1 This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3700 tar cf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1
3701 tar rf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3702 tar tf archive
3703 ) ) >"$at_stdout" 2>"$at_stderr"
3704     at_status=$?
3705 fi
3706
3707 at_failed=false
3708 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
3709 echo >>"$at_stdout"; echo "This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1
3710 This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3711 " | $at_diff - "$at_stdout" || at_failed=:
3712 case $at_status in
3713    77) echo 77 > "$at_status_file"; exit 77;;
3714    0) ;;
3715    *) echo "$at_srcdir/append01.at:34: exit code was $at_status, expected 0"
3716       at_failed=:;;
3717 esac
3718 if $at_failed; then
3719
3720
3721   echo 1 > "$at_status_file"
3722   exit 1
3723 fi
3724
3725 $at_traceon
3726 $at_traceoff
3727 echo "$at_srcdir/append01.at:34:
3728 mkdir ustar
3729 (cd ustar
3730 TEST_TAR_FORMAT=ustar
3731 export TEST_TAR_FORMAT
3732 TAR_OPTIONS=\"-H ustar\"
3733 export TAR_OPTIONS
3734 rm -rf *
3735
3736 mkdir This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX
3737 touch This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1 This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3738 tar cf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1
3739 tar rf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3740 tar tf archive
3741 )"
3742 echo append01.at:34 >"$at_check_line_file"
3743
3744 at_trace_this=
3745 if test -n "$at_traceon"; then
3746     echo 'Not enabling shell tracing (command contains an embedded newline)'
3747 fi
3748
3749 if test -n "$at_trace_this"; then
3750     ( $at_traceon;
3751 mkdir ustar
3752 (cd ustar
3753 TEST_TAR_FORMAT=ustar
3754 export TEST_TAR_FORMAT
3755 TAR_OPTIONS="-H ustar"
3756 export TAR_OPTIONS
3757 rm -rf *
3758
3759 mkdir This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX
3760 touch This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1 This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3761 tar cf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1
3762 tar rf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3763 tar tf archive
3764 ) ) >"$at_stdout" 2>"$at_stder1"
3765     at_status=$?
3766     grep '^ *+' "$at_stder1" >&2
3767     grep -v '^ *+' "$at_stder1" >"$at_stderr"
3768 else
3769     ( :;
3770 mkdir ustar
3771 (cd ustar
3772 TEST_TAR_FORMAT=ustar
3773 export TEST_TAR_FORMAT
3774 TAR_OPTIONS="-H ustar"
3775 export TAR_OPTIONS
3776 rm -rf *
3777
3778 mkdir This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX
3779 touch This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1 This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3780 tar cf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1
3781 tar rf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3782 tar tf archive
3783 ) ) >"$at_stdout" 2>"$at_stderr"
3784     at_status=$?
3785 fi
3786
3787 at_failed=false
3788 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
3789 echo >>"$at_stdout"; echo "This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1
3790 This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3791 " | $at_diff - "$at_stdout" || at_failed=:
3792 case $at_status in
3793    77) echo 77 > "$at_status_file"; exit 77;;
3794    0) ;;
3795    *) echo "$at_srcdir/append01.at:34: exit code was $at_status, expected 0"
3796       at_failed=:;;
3797 esac
3798 if $at_failed; then
3799
3800
3801   echo 1 > "$at_status_file"
3802   exit 1
3803 fi
3804
3805 $at_traceon
3806 $at_traceoff
3807 echo "$at_srcdir/append01.at:34:
3808 mkdir posix
3809 (cd posix
3810 TEST_TAR_FORMAT=posix
3811 export TEST_TAR_FORMAT
3812 TAR_OPTIONS=\"-H posix\"
3813 export TAR_OPTIONS
3814 rm -rf *
3815
3816 mkdir This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX
3817 touch This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1 This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3818 tar cf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1
3819 tar rf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3820 tar tf archive
3821 )"
3822 echo append01.at:34 >"$at_check_line_file"
3823
3824 at_trace_this=
3825 if test -n "$at_traceon"; then
3826     echo 'Not enabling shell tracing (command contains an embedded newline)'
3827 fi
3828
3829 if test -n "$at_trace_this"; then
3830     ( $at_traceon;
3831 mkdir posix
3832 (cd posix
3833 TEST_TAR_FORMAT=posix
3834 export TEST_TAR_FORMAT
3835 TAR_OPTIONS="-H posix"
3836 export TAR_OPTIONS
3837 rm -rf *
3838
3839 mkdir This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX
3840 touch This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1 This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3841 tar cf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1
3842 tar rf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3843 tar tf archive
3844 ) ) >"$at_stdout" 2>"$at_stder1"
3845     at_status=$?
3846     grep '^ *+' "$at_stder1" >&2
3847     grep -v '^ *+' "$at_stder1" >"$at_stderr"
3848 else
3849     ( :;
3850 mkdir posix
3851 (cd posix
3852 TEST_TAR_FORMAT=posix
3853 export TEST_TAR_FORMAT
3854 TAR_OPTIONS="-H posix"
3855 export TAR_OPTIONS
3856 rm -rf *
3857
3858 mkdir This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX
3859 touch This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1 This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3860 tar cf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1
3861 tar rf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3862 tar tf archive
3863 ) ) >"$at_stdout" 2>"$at_stderr"
3864     at_status=$?
3865 fi
3866
3867 at_failed=false
3868 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
3869 echo >>"$at_stdout"; echo "This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1
3870 This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3871 " | $at_diff - "$at_stdout" || at_failed=:
3872 case $at_status in
3873    77) echo 77 > "$at_status_file"; exit 77;;
3874    0) ;;
3875    *) echo "$at_srcdir/append01.at:34: exit code was $at_status, expected 0"
3876       at_failed=:;;
3877 esac
3878 if $at_failed; then
3879
3880
3881   echo 1 > "$at_status_file"
3882   exit 1
3883 fi
3884
3885 $at_traceon
3886 $at_traceoff
3887 echo "$at_srcdir/append01.at:34:
3888 mkdir gnu
3889 (cd gnu
3890 TEST_TAR_FORMAT=gnu
3891 export TEST_TAR_FORMAT
3892 TAR_OPTIONS=\"-H gnu\"
3893 export TAR_OPTIONS
3894 rm -rf *
3895
3896 mkdir This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX
3897 touch This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1 This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3898 tar cf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1
3899 tar rf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3900 tar tf archive
3901 )"
3902 echo append01.at:34 >"$at_check_line_file"
3903
3904 at_trace_this=
3905 if test -n "$at_traceon"; then
3906     echo 'Not enabling shell tracing (command contains an embedded newline)'
3907 fi
3908
3909 if test -n "$at_trace_this"; then
3910     ( $at_traceon;
3911 mkdir gnu
3912 (cd gnu
3913 TEST_TAR_FORMAT=gnu
3914 export TEST_TAR_FORMAT
3915 TAR_OPTIONS="-H gnu"
3916 export TAR_OPTIONS
3917 rm -rf *
3918
3919 mkdir This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX
3920 touch This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1 This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3921 tar cf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1
3922 tar rf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3923 tar tf archive
3924 ) ) >"$at_stdout" 2>"$at_stder1"
3925     at_status=$?
3926     grep '^ *+' "$at_stder1" >&2
3927     grep -v '^ *+' "$at_stder1" >"$at_stderr"
3928 else
3929     ( :;
3930 mkdir gnu
3931 (cd gnu
3932 TEST_TAR_FORMAT=gnu
3933 export TEST_TAR_FORMAT
3934 TAR_OPTIONS="-H gnu"
3935 export TAR_OPTIONS
3936 rm -rf *
3937
3938 mkdir This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX
3939 touch This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1 This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3940 tar cf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1
3941 tar rf archive This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3942 tar tf archive
3943 ) ) >"$at_stdout" 2>"$at_stderr"
3944     at_status=$?
3945 fi
3946
3947 at_failed=false
3948 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
3949 echo >>"$at_stdout"; echo "This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file1
3950 This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_appending_long_file_names_that_run_into_a_limit_of_the_ustar_tarX/file2
3951 " | $at_diff - "$at_stdout" || at_failed=:
3952 case $at_status in
3953    77) echo 77 > "$at_status_file"; exit 77;;
3954    0) ;;
3955    *) echo "$at_srcdir/append01.at:34: exit code was $at_status, expected 0"
3956       at_failed=:;;
3957 esac
3958 if $at_failed; then
3959
3960
3961   echo 1 > "$at_status_file"
3962   exit 1
3963 fi
3964
3965 $at_traceon
3966
3967
3968
3969       $at_traceoff
3970       $at_times_p && times >"$at_times_file"
3971     ) 5>&1 2>&1 | eval $at_tee_pipe
3972     at_status=`cat "$at_status_file"`
3973     ;;
3974
3975   11 ) # 11. append02.at:40: append vs. create
3976     at_setup_line='append02.at:40'
3977     at_desc="append vs. create"
3978     $at_quiet $ECHO_N " 11: append vs. create                              $ECHO_C"
3979     at_xfail=no
3980       test -f $XFAILFILE && at_xfail=yes
3981     echo "#                             -*- compilation -*-" >> "$at_group_log"
3982     (
3983       echo "11. append02.at:40: testing ..."
3984       $at_traceon
3985
3986
3987
3988
3989
3990   $at_traceoff
3991 echo "$at_srcdir/append02.at:43:
3992 mkdir v7
3993 (cd v7
3994 TEST_TAR_FORMAT=v7
3995 export TEST_TAR_FORMAT
3996 TAR_OPTIONS=\"-H v7\"
3997 export TAR_OPTIONS
3998 rm -rf *
3999
4000 genfile --file file1
4001 genfile --file file2
4002
4003 # Make sure file timestamps in the archive will not differ
4004 MTIME=\"--mtime=@0\"
4005
4006 # For PAX archives, we need to make sure extended header names are
4007 # reproducible and that their contents won't change with time
4008 if test \$TEST_TAR_FORMAT = posix; then
4009   TAR_OPTIONS=\"\$TAR_OPTIONS --pax-option=exthdr.name=%d/PaxHeaders/%f,delete=mtime,delete=atime,delete=ctime\"
4010 fi
4011
4012 echo Creating archive.1
4013 tar \$MTIME -cf archive.1 file1 file2
4014
4015 echo Creating archive.2
4016 tar \$MTIME -cf archive.2 -T /dev/null
4017 tar \$MTIME -rf archive.2 file1
4018 tar \$MTIME -rf archive.2 file2
4019
4020 echo Comparing archives
4021 cmp archive.1 archive.2
4022 )"
4023 echo append02.at:43 >"$at_check_line_file"
4024
4025 at_trace_this=
4026 if test -n "$at_traceon"; then
4027     echo 'Not enabling shell tracing (command contains an embedded newline)'
4028 fi
4029
4030 if test -n "$at_trace_this"; then
4031     ( $at_traceon;
4032 mkdir v7
4033 (cd v7
4034 TEST_TAR_FORMAT=v7
4035 export TEST_TAR_FORMAT
4036 TAR_OPTIONS="-H v7"
4037 export TAR_OPTIONS
4038 rm -rf *
4039
4040 genfile --file file1
4041 genfile --file file2
4042
4043 # Make sure file timestamps in the archive will not differ
4044 MTIME="--mtime=@0"
4045
4046 # For PAX archives, we need to make sure extended header names are
4047 # reproducible and that their contents won't change with time
4048 if test $TEST_TAR_FORMAT = posix; then
4049   TAR_OPTIONS="$TAR_OPTIONS --pax-option=exthdr.name=%d/PaxHeaders/%f,delete=mtime,delete=atime,delete=ctime"
4050 fi
4051
4052 echo Creating archive.1
4053 tar $MTIME -cf archive.1 file1 file2
4054
4055 echo Creating archive.2
4056 tar $MTIME -cf archive.2 -T /dev/null
4057 tar $MTIME -rf archive.2 file1
4058 tar $MTIME -rf archive.2 file2
4059
4060 echo Comparing archives
4061 cmp archive.1 archive.2
4062 ) ) >"$at_stdout" 2>"$at_stder1"
4063     at_status=$?
4064     grep '^ *+' "$at_stder1" >&2
4065     grep -v '^ *+' "$at_stder1" >"$at_stderr"
4066 else
4067     ( :;
4068 mkdir v7
4069 (cd v7
4070 TEST_TAR_FORMAT=v7
4071 export TEST_TAR_FORMAT
4072 TAR_OPTIONS="-H v7"
4073 export TAR_OPTIONS
4074 rm -rf *
4075
4076 genfile --file file1
4077 genfile --file file2
4078
4079 # Make sure file timestamps in the archive will not differ
4080 MTIME="--mtime=@0"
4081
4082 # For PAX archives, we need to make sure extended header names are
4083 # reproducible and that their contents won't change with time
4084 if test $TEST_TAR_FORMAT = posix; then
4085   TAR_OPTIONS="$TAR_OPTIONS --pax-option=exthdr.name=%d/PaxHeaders/%f,delete=mtime,delete=atime,delete=ctime"
4086 fi
4087
4088 echo Creating archive.1
4089 tar $MTIME -cf archive.1 file1 file2
4090
4091 echo Creating archive.2
4092 tar $MTIME -cf archive.2 -T /dev/null
4093 tar $MTIME -rf archive.2 file1
4094 tar $MTIME -rf archive.2 file2
4095
4096 echo Comparing archives
4097 cmp archive.1 archive.2
4098 ) ) >"$at_stdout" 2>"$at_stderr"
4099     at_status=$?
4100 fi
4101
4102 at_failed=false
4103 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
4104 echo >>"$at_stdout"; echo "Creating archive.1
4105 Creating archive.2
4106 Comparing archives
4107 " | $at_diff - "$at_stdout" || at_failed=:
4108 case $at_status in
4109    77) echo 77 > "$at_status_file"; exit 77;;
4110    0) ;;
4111    *) echo "$at_srcdir/append02.at:43: exit code was $at_status, expected 0"
4112       at_failed=:;;
4113 esac
4114 if $at_failed; then
4115
4116
4117   echo 1 > "$at_status_file"
4118   exit 1
4119 fi
4120
4121 $at_traceon
4122 $at_traceoff
4123 echo "$at_srcdir/append02.at:43:
4124 mkdir oldgnu
4125 (cd oldgnu
4126 TEST_TAR_FORMAT=oldgnu
4127 export TEST_TAR_FORMAT
4128 TAR_OPTIONS=\"-H oldgnu\"
4129 export TAR_OPTIONS
4130 rm -rf *
4131
4132 genfile --file file1
4133 genfile --file file2
4134
4135 # Make sure file timestamps in the archive will not differ
4136 MTIME=\"--mtime=@0\"
4137
4138 # For PAX archives, we need to make sure extended header names are
4139 # reproducible and that their contents won't change with time
4140 if test \$TEST_TAR_FORMAT = posix; then
4141   TAR_OPTIONS=\"\$TAR_OPTIONS --pax-option=exthdr.name=%d/PaxHeaders/%f,delete=mtime,delete=atime,delete=ctime\"
4142 fi
4143
4144 echo Creating archive.1
4145 tar \$MTIME -cf archive.1 file1 file2
4146
4147 echo Creating archive.2
4148 tar \$MTIME -cf archive.2 -T /dev/null
4149 tar \$MTIME -rf archive.2 file1
4150 tar \$MTIME -rf archive.2 file2
4151
4152 echo Comparing archives
4153 cmp archive.1 archive.2
4154 )"
4155 echo append02.at:43 >"$at_check_line_file"
4156
4157 at_trace_this=
4158 if test -n "$at_traceon"; then
4159     echo 'Not enabling shell tracing (command contains an embedded newline)'
4160 fi
4161
4162 if test -n "$at_trace_this"; then
4163     ( $at_traceon;
4164 mkdir oldgnu
4165 (cd oldgnu
4166 TEST_TAR_FORMAT=oldgnu
4167 export TEST_TAR_FORMAT
4168 TAR_OPTIONS="-H oldgnu"
4169 export TAR_OPTIONS
4170 rm -rf *
4171
4172 genfile --file file1
4173 genfile --file file2
4174
4175 # Make sure file timestamps in the archive will not differ
4176 MTIME="--mtime=@0"
4177
4178 # For PAX archives, we need to make sure extended header names are
4179 # reproducible and that their contents won't change with time
4180 if test $TEST_TAR_FORMAT = posix; then
4181   TAR_OPTIONS="$TAR_OPTIONS --pax-option=exthdr.name=%d/PaxHeaders/%f,delete=mtime,delete=atime,delete=ctime"
4182 fi
4183
4184 echo Creating archive.1
4185 tar $MTIME -cf archive.1 file1 file2
4186
4187 echo Creating archive.2
4188 tar $MTIME -cf archive.2 -T /dev/null
4189 tar $MTIME -rf archive.2 file1
4190 tar $MTIME -rf archive.2 file2
4191
4192 echo Comparing archives
4193 cmp archive.1 archive.2
4194 ) ) >"$at_stdout" 2>"$at_stder1"
4195     at_status=$?
4196     grep '^ *+' "$at_stder1" >&2
4197     grep -v '^ *+' "$at_stder1" >"$at_stderr"
4198 else
4199     ( :;
4200 mkdir oldgnu
4201 (cd oldgnu
4202 TEST_TAR_FORMAT=oldgnu
4203 export TEST_TAR_FORMAT
4204 TAR_OPTIONS="-H oldgnu"
4205 export TAR_OPTIONS
4206 rm -rf *
4207
4208 genfile --file file1
4209 genfile --file file2
4210
4211 # Make sure file timestamps in the archive will not differ
4212 MTIME="--mtime=@0"
4213
4214 # For PAX archives, we need to make sure extended header names are
4215 # reproducible and that their contents won't change with time
4216 if test $TEST_TAR_FORMAT = posix; then
4217   TAR_OPTIONS="$TAR_OPTIONS --pax-option=exthdr.name=%d/PaxHeaders/%f,delete=mtime,delete=atime,delete=ctime"
4218 fi
4219
4220 echo Creating archive.1
4221 tar $MTIME -cf archive.1 file1 file2
4222
4223 echo Creating archive.2
4224 tar $MTIME -cf archive.2 -T /dev/null
4225 tar $MTIME -rf archive.2 file1
4226 tar $MTIME -rf archive.2 file2
4227
4228 echo Comparing archives
4229 cmp archive.1 archive.2
4230 ) ) >"$at_stdout" 2>"$at_stderr"
4231     at_status=$?
4232 fi
4233
4234 at_failed=false
4235 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
4236 echo >>"$at_stdout"; echo "Creating archive.1
4237 Creating archive.2
4238 Comparing archives
4239 " | $at_diff - "$at_stdout" || at_failed=:
4240 case $at_status in
4241    77) echo 77 > "$at_status_file"; exit 77;;
4242    0) ;;
4243    *) echo "$at_srcdir/append02.at:43: exit code was $at_status, expected 0"
4244       at_failed=:;;
4245 esac
4246 if $at_failed; then
4247
4248
4249   echo 1 > "$at_status_file"
4250   exit 1
4251 fi
4252
4253 $at_traceon
4254 $at_traceoff
4255 echo "$at_srcdir/append02.at:43:
4256 mkdir ustar
4257 (cd ustar
4258 TEST_TAR_FORMAT=ustar
4259 export TEST_TAR_FORMAT
4260 TAR_OPTIONS=\"-H ustar\"
4261 export TAR_OPTIONS
4262 rm -rf *
4263
4264 genfile --file file1
4265 genfile --file file2
4266
4267 # Make sure file timestamps in the archive will not differ
4268 MTIME=\"--mtime=@0\"
4269
4270 # For PAX archives, we need to make sure extended header names are
4271 # reproducible and that their contents won't change with time
4272 if test \$TEST_TAR_FORMAT = posix; then
4273   TAR_OPTIONS=\"\$TAR_OPTIONS --pax-option=exthdr.name=%d/PaxHeaders/%f,delete=mtime,delete=atime,delete=ctime\"
4274 fi
4275
4276 echo Creating archive.1
4277 tar \$MTIME -cf archive.1 file1 file2
4278
4279 echo Creating archive.2
4280 tar \$MTIME -cf archive.2 -T /dev/null
4281 tar \$MTIME -rf archive.2 file1
4282 tar \$MTIME -rf archive.2 file2
4283
4284 echo Comparing archives
4285 cmp archive.1 archive.2
4286 )"
4287 echo append02.at:43 >"$at_check_line_file"
4288
4289 at_trace_this=
4290 if test -n "$at_traceon"; then
4291     echo 'Not enabling shell tracing (command contains an embedded newline)'
4292 fi
4293
4294 if test -n "$at_trace_this"; then
4295     ( $at_traceon;
4296 mkdir ustar
4297 (cd ustar
4298 TEST_TAR_FORMAT=ustar
4299 export TEST_TAR_FORMAT
4300 TAR_OPTIONS="-H ustar"
4301 export TAR_OPTIONS
4302 rm -rf *
4303
4304 genfile --file file1
4305 genfile --file file2
4306
4307 # Make sure file timestamps in the archive will not differ
4308 MTIME="--mtime=@0"
4309
4310 # For PAX archives, we need to make sure extended header names are
4311 # reproducible and that their contents won't change with time
4312 if test $TEST_TAR_FORMAT = posix; then
4313   TAR_OPTIONS="$TAR_OPTIONS --pax-option=exthdr.name=%d/PaxHeaders/%f,delete=mtime,delete=atime,delete=ctime"
4314 fi
4315
4316 echo Creating archive.1
4317 tar $MTIME -cf archive.1 file1 file2
4318
4319 echo Creating archive.2
4320 tar $MTIME -cf archive.2 -T /dev/null
4321 tar $MTIME -rf archive.2 file1
4322 tar $MTIME -rf archive.2 file2
4323
4324 echo Comparing archives
4325 cmp archive.1 archive.2
4326 ) ) >"$at_stdout" 2>"$at_stder1"
4327     at_status=$?
4328     grep '^ *+' "$at_stder1" >&2
4329     grep -v '^ *+' "$at_stder1" >"$at_stderr"
4330 else
4331     ( :;
4332 mkdir ustar
4333 (cd ustar
4334 TEST_TAR_FORMAT=ustar
4335 export TEST_TAR_FORMAT
4336 TAR_OPTIONS="-H ustar"
4337 export TAR_OPTIONS
4338 rm -rf *
4339
4340 genfile --file file1
4341 genfile --file file2
4342
4343 # Make sure file timestamps in the archive will not differ
4344 MTIME="--mtime=@0"
4345
4346 # For PAX archives, we need to make sure extended header names are
4347 # reproducible and that their contents won't change with time
4348 if test $TEST_TAR_FORMAT = posix; then
4349   TAR_OPTIONS="$TAR_OPTIONS --pax-option=exthdr.name=%d/PaxHeaders/%f,delete=mtime,delete=atime,delete=ctime"
4350 fi
4351
4352 echo Creating archive.1
4353 tar $MTIME -cf archive.1 file1 file2
4354
4355 echo Creating archive.2
4356 tar $MTIME -cf archive.2 -T /dev/null
4357 tar $MTIME -rf archive.2 file1
4358 tar $MTIME -rf archive.2 file2
4359
4360 echo Comparing archives
4361 cmp archive.1 archive.2
4362 ) ) >"$at_stdout" 2>"$at_stderr"
4363     at_status=$?
4364 fi
4365
4366 at_failed=false
4367 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
4368 echo >>"$at_stdout"; echo "Creating archive.1
4369 Creating archive.2
4370 Comparing archives
4371 " | $at_diff - "$at_stdout" || at_failed=:
4372 case $at_status in
4373    77) echo 77 > "$at_status_file"; exit 77;;
4374    0) ;;
4375    *) echo "$at_srcdir/append02.at:43: exit code was $at_status, expected 0"
4376       at_failed=:;;
4377 esac
4378 if $at_failed; then
4379
4380
4381   echo 1 > "$at_status_file"
4382   exit 1
4383 fi
4384
4385 $at_traceon
4386 $at_traceoff
4387 echo "$at_srcdir/append02.at:43:
4388 mkdir posix
4389 (cd posix
4390 TEST_TAR_FORMAT=posix
4391 export TEST_TAR_FORMAT
4392 TAR_OPTIONS=\"-H posix\"
4393 export TAR_OPTIONS
4394 rm -rf *
4395
4396 genfile --file file1
4397 genfile --file file2
4398
4399 # Make sure file timestamps in the archive will not differ
4400 MTIME=\"--mtime=@0\"
4401
4402 # For PAX archives, we need to make sure extended header names are
4403 # reproducible and that their contents won't change with time
4404 if test \$TEST_TAR_FORMAT = posix; then
4405   TAR_OPTIONS=\"\$TAR_OPTIONS --pax-option=exthdr.name=%d/PaxHeaders/%f,delete=mtime,delete=atime,delete=ctime\"
4406 fi
4407
4408 echo Creating archive.1
4409 tar \$MTIME -cf archive.1 file1 file2
4410
4411 echo Creating archive.2
4412 tar \$MTIME -cf archive.2 -T /dev/null
4413 tar \$MTIME -rf archive.2 file1
4414 tar \$MTIME -rf archive.2 file2
4415
4416 echo Comparing archives
4417 cmp archive.1 archive.2
4418 )"
4419 echo append02.at:43 >"$at_check_line_file"
4420
4421 at_trace_this=
4422 if test -n "$at_traceon"; then
4423     echo 'Not enabling shell tracing (command contains an embedded newline)'
4424 fi
4425
4426 if test -n "$at_trace_this"; then
4427     ( $at_traceon;
4428 mkdir posix
4429 (cd posix
4430 TEST_TAR_FORMAT=posix
4431 export TEST_TAR_FORMAT
4432 TAR_OPTIONS="-H posix"
4433 export TAR_OPTIONS
4434 rm -rf *
4435
4436 genfile --file file1
4437 genfile --file file2
4438
4439 # Make sure file timestamps in the archive will not differ
4440 MTIME="--mtime=@0"
4441
4442 # For PAX archives, we need to make sure extended header names are
4443 # reproducible and that their contents won't change with time
4444 if test $TEST_TAR_FORMAT = posix; then
4445   TAR_OPTIONS="$TAR_OPTIONS --pax-option=exthdr.name=%d/PaxHeaders/%f,delete=mtime,delete=atime,delete=ctime"
4446 fi
4447
4448 echo Creating archive.1
4449 tar $MTIME -cf archive.1 file1 file2
4450
4451 echo Creating archive.2
4452 tar $MTIME -cf archive.2 -T /dev/null
4453 tar $MTIME -rf archive.2 file1
4454 tar $MTIME -rf archive.2 file2
4455
4456 echo Comparing archives
4457 cmp archive.1 archive.2
4458 ) ) >"$at_stdout" 2>"$at_stder1"
4459     at_status=$?
4460     grep '^ *+' "$at_stder1" >&2
4461     grep -v '^ *+' "$at_stder1" >"$at_stderr"
4462 else
4463     ( :;
4464 mkdir posix
4465 (cd posix
4466 TEST_TAR_FORMAT=posix
4467 export TEST_TAR_FORMAT
4468 TAR_OPTIONS="-H posix"
4469 export TAR_OPTIONS
4470 rm -rf *
4471
4472 genfile --file file1
4473 genfile --file file2
4474
4475 # Make sure file timestamps in the archive will not differ
4476 MTIME="--mtime=@0"
4477
4478 # For PAX archives, we need to make sure extended header names are
4479 # reproducible and that their contents won't change with time
4480 if test $TEST_TAR_FORMAT = posix; then
4481   TAR_OPTIONS="$TAR_OPTIONS --pax-option=exthdr.name=%d/PaxHeaders/%f,delete=mtime,delete=atime,delete=ctime"
4482 fi
4483
4484 echo Creating archive.1
4485 tar $MTIME -cf archive.1 file1 file2
4486
4487 echo Creating archive.2
4488 tar $MTIME -cf archive.2 -T /dev/null
4489 tar $MTIME -rf archive.2 file1
4490 tar $MTIME -rf archive.2 file2
4491
4492 echo Comparing archives
4493 cmp archive.1 archive.2
4494 ) ) >"$at_stdout" 2>"$at_stderr"
4495     at_status=$?
4496 fi
4497
4498 at_failed=false
4499 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
4500 echo >>"$at_stdout"; echo "Creating archive.1
4501 Creating archive.2
4502 Comparing archives
4503 " | $at_diff - "$at_stdout" || at_failed=:
4504 case $at_status in
4505    77) echo 77 > "$at_status_file"; exit 77;;
4506    0) ;;
4507    *) echo "$at_srcdir/append02.at:43: exit code was $at_status, expected 0"
4508       at_failed=:;;
4509 esac
4510 if $at_failed; then
4511
4512
4513   echo 1 > "$at_status_file"
4514   exit 1
4515 fi
4516
4517 $at_traceon
4518 $at_traceoff
4519 echo "$at_srcdir/append02.at:43:
4520 mkdir gnu
4521 (cd gnu
4522 TEST_TAR_FORMAT=gnu
4523 export TEST_TAR_FORMAT
4524 TAR_OPTIONS=\"-H gnu\"
4525 export TAR_OPTIONS
4526 rm -rf *
4527
4528 genfile --file file1
4529 genfile --file file2
4530
4531 # Make sure file timestamps in the archive will not differ
4532 MTIME=\"--mtime=@0\"
4533
4534 # For PAX archives, we need to make sure extended header names are
4535 # reproducible and that their contents won't change with time
4536 if test \$TEST_TAR_FORMAT = posix; then
4537   TAR_OPTIONS=\"\$TAR_OPTIONS --pax-option=exthdr.name=%d/PaxHeaders/%f,delete=mtime,delete=atime,delete=ctime\"
4538 fi
4539
4540 echo Creating archive.1
4541 tar \$MTIME -cf archive.1 file1 file2
4542
4543 echo Creating archive.2
4544 tar \$MTIME -cf archive.2 -T /dev/null
4545 tar \$MTIME -rf archive.2 file1
4546 tar \$MTIME -rf archive.2 file2
4547
4548 echo Comparing archives
4549 cmp archive.1 archive.2
4550 )"
4551 echo append02.at:43 >"$at_check_line_file"
4552
4553 at_trace_this=
4554 if test -n "$at_traceon"; then
4555     echo 'Not enabling shell tracing (command contains an embedded newline)'
4556 fi
4557
4558 if test -n "$at_trace_this"; then
4559     ( $at_traceon;
4560 mkdir gnu
4561 (cd gnu
4562 TEST_TAR_FORMAT=gnu
4563 export TEST_TAR_FORMAT
4564 TAR_OPTIONS="-H gnu"
4565 export TAR_OPTIONS
4566 rm -rf *
4567
4568 genfile --file file1
4569 genfile --file file2
4570
4571 # Make sure file timestamps in the archive will not differ
4572 MTIME="--mtime=@0"
4573
4574 # For PAX archives, we need to make sure extended header names are
4575 # reproducible and that their contents won't change with time
4576 if test $TEST_TAR_FORMAT = posix; then
4577   TAR_OPTIONS="$TAR_OPTIONS --pax-option=exthdr.name=%d/PaxHeaders/%f,delete=mtime,delete=atime,delete=ctime"
4578 fi
4579
4580 echo Creating archive.1
4581 tar $MTIME -cf archive.1 file1 file2
4582
4583 echo Creating archive.2
4584 tar $MTIME -cf archive.2 -T /dev/null
4585 tar $MTIME -rf archive.2 file1
4586 tar $MTIME -rf archive.2 file2
4587
4588 echo Comparing archives
4589 cmp archive.1 archive.2
4590 ) ) >"$at_stdout" 2>"$at_stder1"
4591     at_status=$?
4592     grep '^ *+' "$at_stder1" >&2
4593     grep -v '^ *+' "$at_stder1" >"$at_stderr"
4594 else
4595     ( :;
4596 mkdir gnu
4597 (cd gnu
4598 TEST_TAR_FORMAT=gnu
4599 export TEST_TAR_FORMAT
4600 TAR_OPTIONS="-H gnu"
4601 export TAR_OPTIONS
4602 rm -rf *
4603
4604 genfile --file file1
4605 genfile --file file2
4606
4607 # Make sure file timestamps in the archive will not differ
4608 MTIME="--mtime=@0"
4609
4610 # For PAX archives, we need to make sure extended header names are
4611 # reproducible and that their contents won't change with time
4612 if test $TEST_TAR_FORMAT = posix; then
4613   TAR_OPTIONS="$TAR_OPTIONS --pax-option=exthdr.name=%d/PaxHeaders/%f,delete=mtime,delete=atime,delete=ctime"
4614 fi
4615
4616 echo Creating archive.1
4617 tar $MTIME -cf archive.1 file1 file2
4618
4619 echo Creating archive.2
4620 tar $MTIME -cf archive.2 -T /dev/null
4621 tar $MTIME -rf archive.2 file1
4622 tar $MTIME -rf archive.2 file2
4623
4624 echo Comparing archives
4625 cmp archive.1 archive.2
4626 ) ) >"$at_stdout" 2>"$at_stderr"
4627     at_status=$?
4628 fi
4629
4630 at_failed=false
4631 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
4632 echo >>"$at_stdout"; echo "Creating archive.1
4633 Creating archive.2
4634 Comparing archives
4635 " | $at_diff - "$at_stdout" || at_failed=:
4636 case $at_status in
4637    77) echo 77 > "$at_status_file"; exit 77;;
4638    0) ;;
4639    *) echo "$at_srcdir/append02.at:43: exit code was $at_status, expected 0"
4640       at_failed=:;;
4641 esac
4642 if $at_failed; then
4643
4644
4645   echo 1 > "$at_status_file"
4646   exit 1
4647 fi
4648
4649 $at_traceon
4650
4651
4652
4653       $at_traceoff
4654       $at_times_p && times >"$at_times_file"
4655     ) 5>&1 2>&1 | eval $at_tee_pipe
4656     at_status=`cat "$at_status_file"`
4657     ;;
4658
4659   12 ) # 12. exclude.at:23: exclude
4660     at_setup_line='exclude.at:23'
4661     at_desc="exclude"
4662     $at_quiet $ECHO_N " 12: exclude                                        $ECHO_C"
4663     at_xfail=no
4664       test -f $XFAILFILE && at_xfail=yes
4665     echo "#                             -*- compilation -*-" >> "$at_group_log"
4666     (
4667       echo "12. exclude.at:23: testing ..."
4668       $at_traceon
4669
4670
4671
4672
4673
4674   $at_traceoff
4675 echo "$at_srcdir/exclude.at:26:
4676 mkdir ustar
4677 (cd ustar
4678 TEST_TAR_FORMAT=ustar
4679 export TEST_TAR_FORMAT
4680 TAR_OPTIONS=\"-H ustar\"
4681 export TAR_OPTIONS
4682 rm -rf *
4683
4684
4685 test -z "`sort < /dev/null 2>&1`" || exit 77
4686
4687
4688 mkdir dir
4689 echo blues > dir/blues
4690 echo jazz > dir/jazz
4691 mkdir dir/folk
4692 echo tagfile > dir/folk/tagfile
4693 echo sanjuan > dir/folk/sanjuan
4694 mkdir dir/rock
4695 echo \"Signature: 8a477f597d28d172789f06886806bc55\" > dir/rock/CACHEDIR.TAG
4696 echo \"test\" > dir/rock/file
4697
4698 for option in exclude-caches exclude-caches-under exclude-caches-all
4699 do
4700   echo OPTION \$option
4701   tar -cf archive.tar --\$option -v dir 2>err | sort
4702   cat err
4703   echo ARCHIVE
4704   tar tf archive.tar | sort
4705 done
4706
4707 for option in exclude-tag exclude-tag-under exclude-tag-all
4708 do
4709   echo OPTION \$option
4710   tar -cf archive.tar --\${option}=tagfile -v dir 2>err | sort
4711   cat err
4712   echo ARCHIVE
4713   tar tf archive.tar | sort
4714 done
4715 )"
4716 echo exclude.at:26 >"$at_check_line_file"
4717
4718 at_trace_this=
4719 if test -n "$at_traceon"; then
4720     echo 'Not enabling shell tracing (command contains a ${...} parameter expansion)'
4721 fi
4722
4723 if test -n "$at_trace_this"; then
4724     ( $at_traceon;
4725 mkdir ustar
4726 (cd ustar
4727 TEST_TAR_FORMAT=ustar
4728 export TEST_TAR_FORMAT
4729 TAR_OPTIONS="-H ustar"
4730 export TAR_OPTIONS
4731 rm -rf *
4732
4733
4734 test -z "`sort < /dev/null 2>&1`" || exit 77
4735
4736
4737 mkdir dir
4738 echo blues > dir/blues
4739 echo jazz > dir/jazz
4740 mkdir dir/folk
4741 echo tagfile > dir/folk/tagfile
4742 echo sanjuan > dir/folk/sanjuan
4743 mkdir dir/rock
4744 echo "Signature: 8a477f597d28d172789f06886806bc55" > dir/rock/CACHEDIR.TAG
4745 echo "test" > dir/rock/file
4746
4747 for option in exclude-caches exclude-caches-under exclude-caches-all
4748 do
4749   echo OPTION $option
4750   tar -cf archive.tar --$option -v dir 2>err | sort
4751   cat err
4752   echo ARCHIVE
4753   tar tf archive.tar | sort
4754 done
4755
4756 for option in exclude-tag exclude-tag-under exclude-tag-all
4757 do
4758   echo OPTION $option
4759   tar -cf archive.tar --${option}=tagfile -v dir 2>err | sort
4760   cat err
4761   echo ARCHIVE
4762   tar tf archive.tar | sort
4763 done
4764 ) ) >"$at_stdout" 2>"$at_stder1"
4765     at_status=$?
4766     grep '^ *+' "$at_stder1" >&2
4767     grep -v '^ *+' "$at_stder1" >"$at_stderr"
4768 else
4769     ( :;
4770 mkdir ustar
4771 (cd ustar
4772 TEST_TAR_FORMAT=ustar
4773 export TEST_TAR_FORMAT
4774 TAR_OPTIONS="-H ustar"
4775 export TAR_OPTIONS
4776 rm -rf *
4777
4778
4779 test -z "`sort < /dev/null 2>&1`" || exit 77
4780
4781
4782 mkdir dir
4783 echo blues > dir/blues
4784 echo jazz > dir/jazz
4785 mkdir dir/folk
4786 echo tagfile > dir/folk/tagfile
4787 echo sanjuan > dir/folk/sanjuan
4788 mkdir dir/rock
4789 echo "Signature: 8a477f597d28d172789f06886806bc55" > dir/rock/CACHEDIR.TAG
4790 echo "test" > dir/rock/file
4791
4792 for option in exclude-caches exclude-caches-under exclude-caches-all
4793 do
4794   echo OPTION $option
4795   tar -cf archive.tar --$option -v dir 2>err | sort
4796   cat err
4797   echo ARCHIVE
4798   tar tf archive.tar | sort
4799 done
4800
4801 for option in exclude-tag exclude-tag-under exclude-tag-all
4802 do
4803   echo OPTION $option
4804   tar -cf archive.tar --${option}=tagfile -v dir 2>err | sort
4805   cat err
4806   echo ARCHIVE
4807   tar tf archive.tar | sort
4808 done
4809 ) ) >"$at_stdout" 2>"$at_stderr"
4810     at_status=$?
4811 fi
4812
4813 at_failed=false
4814 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
4815 echo >>"$at_stdout"; echo "OPTION exclude-caches
4816 dir/
4817 dir/blues
4818 dir/folk/
4819 dir/folk/sanjuan
4820 dir/folk/tagfile
4821 dir/jazz
4822 dir/rock/
4823 dir/rock/CACHEDIR.TAG
4824 tar: dir/rock/: contains a cache directory tag CACHEDIR.TAG; contents not dumped
4825 ARCHIVE
4826 dir/
4827 dir/blues
4828 dir/folk/
4829 dir/folk/sanjuan
4830 dir/folk/tagfile
4831 dir/jazz
4832 dir/rock/
4833 dir/rock/CACHEDIR.TAG
4834 OPTION exclude-caches-under
4835 dir/
4836 dir/blues
4837 dir/folk/
4838 dir/folk/sanjuan
4839 dir/folk/tagfile
4840 dir/jazz
4841 dir/rock/
4842 tar: dir/rock/: contains a cache directory tag CACHEDIR.TAG; contents not dumped
4843 ARCHIVE
4844 dir/
4845 dir/blues
4846 dir/folk/
4847 dir/folk/sanjuan
4848 dir/folk/tagfile
4849 dir/jazz
4850 dir/rock/
4851 OPTION exclude-caches-all
4852 dir/
4853 dir/blues
4854 dir/folk/
4855 dir/folk/sanjuan
4856 dir/folk/tagfile
4857 dir/jazz
4858 tar: dir/rock/: contains a cache directory tag CACHEDIR.TAG; directory not dumped
4859 ARCHIVE
4860 dir/
4861 dir/blues
4862 dir/folk/
4863 dir/folk/sanjuan
4864 dir/folk/tagfile
4865 dir/jazz
4866 OPTION exclude-tag
4867 dir/
4868 dir/blues
4869 dir/folk/
4870 dir/folk/tagfile
4871 dir/jazz
4872 dir/rock/
4873 dir/rock/CACHEDIR.TAG
4874 dir/rock/file
4875 tar: dir/folk/: contains a cache directory tag tagfile; contents not dumped
4876 ARCHIVE
4877 dir/
4878 dir/blues
4879 dir/folk/
4880 dir/folk/tagfile
4881 dir/jazz
4882 dir/rock/
4883 dir/rock/CACHEDIR.TAG
4884 dir/rock/file
4885 OPTION exclude-tag-under
4886 dir/
4887 dir/blues
4888 dir/folk/
4889 dir/jazz
4890 dir/rock/
4891 dir/rock/CACHEDIR.TAG
4892 dir/rock/file
4893 tar: dir/folk/: contains a cache directory tag tagfile; contents not dumped
4894 ARCHIVE
4895 dir/
4896 dir/blues
4897 dir/folk/
4898 dir/jazz
4899 dir/rock/
4900 dir/rock/CACHEDIR.TAG
4901 dir/rock/file
4902 OPTION exclude-tag-all
4903 dir/
4904 dir/blues
4905 dir/jazz
4906 dir/rock/
4907 dir/rock/CACHEDIR.TAG
4908 dir/rock/file
4909 tar: dir/folk/: contains a cache directory tag tagfile; directory not dumped
4910 ARCHIVE
4911 dir/
4912 dir/blues
4913 dir/jazz
4914 dir/rock/
4915 dir/rock/CACHEDIR.TAG
4916 dir/rock/file
4917 " | $at_diff - "$at_stdout" || at_failed=:
4918 case $at_status in
4919    77) echo 77 > "$at_status_file"; exit 77;;
4920    0) ;;
4921    *) echo "$at_srcdir/exclude.at:26: exit code was $at_status, expected 0"
4922       at_failed=:;;
4923 esac
4924 if $at_failed; then
4925
4926
4927   echo 1 > "$at_status_file"
4928   exit 1
4929 fi
4930
4931 $at_traceon
4932
4933
4934
4935       $at_traceoff
4936       $at_times_p && times >"$at_times_file"
4937     ) 5>&1 2>&1 | eval $at_tee_pipe
4938     at_status=`cat "$at_status_file"`
4939     ;;
4940
4941   13 ) # 13. delete01.at:23: deleting a member after a big one
4942     at_setup_line='delete01.at:23'
4943     at_desc="deleting a member after a big one"
4944     $at_quiet $ECHO_N " 13: deleting a member after a big one              $ECHO_C"
4945     at_xfail=no
4946       test -f $XFAILFILE && at_xfail=yes
4947     echo "#                             -*- compilation -*-" >> "$at_group_log"
4948     (
4949       echo "13. delete01.at:23: testing ..."
4950       $at_traceon
4951
4952
4953
4954
4955
4956   $at_traceoff
4957 echo "$at_srcdir/delete01.at:26:
4958 mkdir v7
4959 (cd v7
4960 TEST_TAR_FORMAT=v7
4961 export TEST_TAR_FORMAT
4962 TAR_OPTIONS=\"-H v7\"
4963 export TAR_OPTIONS
4964 rm -rf *
4965
4966 genfile -l 50000 --file file1
4967 genfile -l 1024 --file file2
4968 tar cf archive file1 file2
4969 tar f archive --delete file2
4970 tar tf archive)"
4971 echo delete01.at:26 >"$at_check_line_file"
4972
4973 at_trace_this=
4974 if test -n "$at_traceon"; then
4975     echo 'Not enabling shell tracing (command contains an embedded newline)'
4976 fi
4977
4978 if test -n "$at_trace_this"; then
4979     ( $at_traceon;
4980 mkdir v7
4981 (cd v7
4982 TEST_TAR_FORMAT=v7
4983 export TEST_TAR_FORMAT
4984 TAR_OPTIONS="-H v7"
4985 export TAR_OPTIONS
4986 rm -rf *
4987
4988 genfile -l 50000 --file file1
4989 genfile -l 1024 --file file2
4990 tar cf archive file1 file2
4991 tar f archive --delete file2
4992 tar tf archive) ) >"$at_stdout" 2>"$at_stder1"
4993     at_status=$?
4994     grep '^ *+' "$at_stder1" >&2
4995     grep -v '^ *+' "$at_stder1" >"$at_stderr"
4996 else
4997     ( :;
4998 mkdir v7
4999 (cd v7
5000 TEST_TAR_FORMAT=v7
5001 export TEST_TAR_FORMAT
5002 TAR_OPTIONS="-H v7"
5003 export TAR_OPTIONS
5004 rm -rf *
5005
5006 genfile -l 50000 --file file1
5007 genfile -l 1024 --file file2
5008 tar cf archive file1 file2
5009 tar f archive --delete file2
5010 tar tf archive) ) >"$at_stdout" 2>"$at_stderr"
5011     at_status=$?
5012 fi
5013
5014 at_failed=false
5015 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
5016 echo >>"$at_stdout"; echo "file1
5017 " | $at_diff - "$at_stdout" || at_failed=:
5018 case $at_status in
5019    77) echo 77 > "$at_status_file"; exit 77;;
5020    0) ;;
5021    *) echo "$at_srcdir/delete01.at:26: exit code was $at_status, expected 0"
5022       at_failed=:;;
5023 esac
5024 if $at_failed; then
5025
5026
5027   echo 1 > "$at_status_file"
5028   exit 1
5029 fi
5030
5031 $at_traceon
5032 $at_traceoff
5033 echo "$at_srcdir/delete01.at:26:
5034 mkdir oldgnu
5035 (cd oldgnu
5036 TEST_TAR_FORMAT=oldgnu
5037 export TEST_TAR_FORMAT
5038 TAR_OPTIONS=\"-H oldgnu\"
5039 export TAR_OPTIONS
5040 rm -rf *
5041
5042 genfile -l 50000 --file file1
5043 genfile -l 1024 --file file2
5044 tar cf archive file1 file2
5045 tar f archive --delete file2
5046 tar tf archive)"
5047 echo delete01.at:26 >"$at_check_line_file"
5048
5049 at_trace_this=
5050 if test -n "$at_traceon"; then
5051     echo 'Not enabling shell tracing (command contains an embedded newline)'
5052 fi
5053
5054 if test -n "$at_trace_this"; then
5055     ( $at_traceon;
5056 mkdir oldgnu
5057 (cd oldgnu
5058 TEST_TAR_FORMAT=oldgnu
5059 export TEST_TAR_FORMAT
5060 TAR_OPTIONS="-H oldgnu"
5061 export TAR_OPTIONS
5062 rm -rf *
5063
5064 genfile -l 50000 --file file1
5065 genfile -l 1024 --file file2
5066 tar cf archive file1 file2
5067 tar f archive --delete file2
5068 tar tf archive) ) >"$at_stdout" 2>"$at_stder1"
5069     at_status=$?
5070     grep '^ *+' "$at_stder1" >&2
5071     grep -v '^ *+' "$at_stder1" >"$at_stderr"
5072 else
5073     ( :;
5074 mkdir oldgnu
5075 (cd oldgnu
5076 TEST_TAR_FORMAT=oldgnu
5077 export TEST_TAR_FORMAT
5078 TAR_OPTIONS="-H oldgnu"
5079 export TAR_OPTIONS
5080 rm -rf *
5081
5082 genfile -l 50000 --file file1
5083 genfile -l 1024 --file file2
5084 tar cf archive file1 file2
5085 tar f archive --delete file2
5086 tar tf archive) ) >"$at_stdout" 2>"$at_stderr"
5087     at_status=$?
5088 fi
5089
5090 at_failed=false
5091 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
5092 echo >>"$at_stdout"; echo "file1
5093 " | $at_diff - "$at_stdout" || at_failed=:
5094 case $at_status in
5095    77) echo 77 > "$at_status_file"; exit 77;;
5096    0) ;;
5097    *) echo "$at_srcdir/delete01.at:26: exit code was $at_status, expected 0"
5098       at_failed=:;;
5099 esac
5100 if $at_failed; then
5101
5102
5103   echo 1 > "$at_status_file"
5104   exit 1
5105 fi
5106
5107 $at_traceon
5108 $at_traceoff
5109 echo "$at_srcdir/delete01.at:26:
5110 mkdir ustar
5111 (cd ustar
5112 TEST_TAR_FORMAT=ustar
5113 export TEST_TAR_FORMAT
5114 TAR_OPTIONS=\"-H ustar\"
5115 export TAR_OPTIONS
5116 rm -rf *
5117
5118 genfile -l 50000 --file file1
5119 genfile -l 1024 --file file2
5120 tar cf archive file1 file2
5121 tar f archive --delete file2
5122 tar tf archive)"
5123 echo delete01.at:26 >"$at_check_line_file"
5124
5125 at_trace_this=
5126 if test -n "$at_traceon"; then
5127     echo 'Not enabling shell tracing (command contains an embedded newline)'
5128 fi
5129
5130 if test -n "$at_trace_this"; then
5131     ( $at_traceon;
5132 mkdir ustar
5133 (cd ustar
5134 TEST_TAR_FORMAT=ustar
5135 export TEST_TAR_FORMAT
5136 TAR_OPTIONS="-H ustar"
5137 export TAR_OPTIONS
5138 rm -rf *
5139
5140 genfile -l 50000 --file file1
5141 genfile -l 1024 --file file2
5142 tar cf archive file1 file2
5143 tar f archive --delete file2
5144 tar tf archive) ) >"$at_stdout" 2>"$at_stder1"
5145     at_status=$?
5146     grep '^ *+' "$at_stder1" >&2
5147     grep -v '^ *+' "$at_stder1" >"$at_stderr"
5148 else
5149     ( :;
5150 mkdir ustar
5151 (cd ustar
5152 TEST_TAR_FORMAT=ustar
5153 export TEST_TAR_FORMAT
5154 TAR_OPTIONS="-H ustar"
5155 export TAR_OPTIONS
5156 rm -rf *
5157
5158 genfile -l 50000 --file file1
5159 genfile -l 1024 --file file2
5160 tar cf archive file1 file2
5161 tar f archive --delete file2
5162 tar tf archive) ) >"$at_stdout" 2>"$at_stderr"
5163     at_status=$?
5164 fi
5165
5166 at_failed=false
5167 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
5168 echo >>"$at_stdout"; echo "file1
5169 " | $at_diff - "$at_stdout" || at_failed=:
5170 case $at_status in
5171    77) echo 77 > "$at_status_file"; exit 77;;
5172    0) ;;
5173    *) echo "$at_srcdir/delete01.at:26: exit code was $at_status, expected 0"
5174       at_failed=:;;
5175 esac
5176 if $at_failed; then
5177
5178
5179   echo 1 > "$at_status_file"
5180   exit 1
5181 fi
5182
5183 $at_traceon
5184 $at_traceoff
5185 echo "$at_srcdir/delete01.at:26:
5186 mkdir posix
5187 (cd posix
5188 TEST_TAR_FORMAT=posix
5189 export TEST_TAR_FORMAT
5190 TAR_OPTIONS=\"-H posix\"
5191 export TAR_OPTIONS
5192 rm -rf *
5193
5194 genfile -l 50000 --file file1
5195 genfile -l 1024 --file file2
5196 tar cf archive file1 file2
5197 tar f archive --delete file2
5198 tar tf archive)"
5199 echo delete01.at:26 >"$at_check_line_file"
5200
5201 at_trace_this=
5202 if test -n "$at_traceon"; then
5203     echo 'Not enabling shell tracing (command contains an embedded newline)'
5204 fi
5205
5206 if test -n "$at_trace_this"; then
5207     ( $at_traceon;
5208 mkdir posix
5209 (cd posix
5210 TEST_TAR_FORMAT=posix
5211 export TEST_TAR_FORMAT
5212 TAR_OPTIONS="-H posix"
5213 export TAR_OPTIONS
5214 rm -rf *
5215
5216 genfile -l 50000 --file file1
5217 genfile -l 1024 --file file2
5218 tar cf archive file1 file2
5219 tar f archive --delete file2
5220 tar tf archive) ) >"$at_stdout" 2>"$at_stder1"
5221     at_status=$?
5222     grep '^ *+' "$at_stder1" >&2
5223     grep -v '^ *+' "$at_stder1" >"$at_stderr"
5224 else
5225     ( :;
5226 mkdir posix
5227 (cd posix
5228 TEST_TAR_FORMAT=posix
5229 export TEST_TAR_FORMAT
5230 TAR_OPTIONS="-H posix"
5231 export TAR_OPTIONS
5232 rm -rf *
5233
5234 genfile -l 50000 --file file1
5235 genfile -l 1024 --file file2
5236 tar cf archive file1 file2
5237 tar f archive --delete file2
5238 tar tf archive) ) >"$at_stdout" 2>"$at_stderr"
5239     at_status=$?
5240 fi
5241
5242 at_failed=false
5243 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
5244 echo >>"$at_stdout"; echo "file1
5245 " | $at_diff - "$at_stdout" || at_failed=:
5246 case $at_status in
5247    77) echo 77 > "$at_status_file"; exit 77;;
5248    0) ;;
5249    *) echo "$at_srcdir/delete01.at:26: exit code was $at_status, expected 0"
5250       at_failed=:;;
5251 esac
5252 if $at_failed; then
5253
5254
5255   echo 1 > "$at_status_file"
5256   exit 1
5257 fi
5258
5259 $at_traceon
5260 $at_traceoff
5261 echo "$at_srcdir/delete01.at:26:
5262 mkdir gnu
5263 (cd gnu
5264 TEST_TAR_FORMAT=gnu
5265 export TEST_TAR_FORMAT
5266 TAR_OPTIONS=\"-H gnu\"
5267 export TAR_OPTIONS
5268 rm -rf *
5269
5270 genfile -l 50000 --file file1
5271 genfile -l 1024 --file file2
5272 tar cf archive file1 file2
5273 tar f archive --delete file2
5274 tar tf archive)"
5275 echo delete01.at:26 >"$at_check_line_file"
5276
5277 at_trace_this=
5278 if test -n "$at_traceon"; then
5279     echo 'Not enabling shell tracing (command contains an embedded newline)'
5280 fi
5281
5282 if test -n "$at_trace_this"; then
5283     ( $at_traceon;
5284 mkdir gnu
5285 (cd gnu
5286 TEST_TAR_FORMAT=gnu
5287 export TEST_TAR_FORMAT
5288 TAR_OPTIONS="-H gnu"
5289 export TAR_OPTIONS
5290 rm -rf *
5291
5292 genfile -l 50000 --file file1
5293 genfile -l 1024 --file file2
5294 tar cf archive file1 file2
5295 tar f archive --delete file2
5296 tar tf archive) ) >"$at_stdout" 2>"$at_stder1"
5297     at_status=$?
5298     grep '^ *+' "$at_stder1" >&2
5299     grep -v '^ *+' "$at_stder1" >"$at_stderr"
5300 else
5301     ( :;
5302 mkdir gnu
5303 (cd gnu
5304 TEST_TAR_FORMAT=gnu
5305 export TEST_TAR_FORMAT
5306 TAR_OPTIONS="-H gnu"
5307 export TAR_OPTIONS
5308 rm -rf *
5309
5310 genfile -l 50000 --file file1
5311 genfile -l 1024 --file file2
5312 tar cf archive file1 file2
5313 tar f archive --delete file2
5314 tar tf archive) ) >"$at_stdout" 2>"$at_stderr"
5315     at_status=$?
5316 fi
5317
5318 at_failed=false
5319 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
5320 echo >>"$at_stdout"; echo "file1
5321 " | $at_diff - "$at_stdout" || at_failed=:
5322 case $at_status in
5323    77) echo 77 > "$at_status_file"; exit 77;;
5324    0) ;;
5325    *) echo "$at_srcdir/delete01.at:26: exit code was $at_status, expected 0"
5326       at_failed=:;;
5327 esac
5328 if $at_failed; then
5329
5330
5331   echo 1 > "$at_status_file"
5332   exit 1
5333 fi
5334
5335 $at_traceon
5336
5337
5338
5339       $at_traceoff
5340       $at_times_p && times >"$at_times_file"
5341     ) 5>&1 2>&1 | eval $at_tee_pipe
5342     at_status=`cat "$at_status_file"`
5343     ;;
5344
5345   14 ) # 14. delete02.at:23: deleting a member from stdin archive
5346     at_setup_line='delete02.at:23'
5347     at_desc="deleting a member from stdin archive"
5348     $at_quiet $ECHO_N " 14: deleting a member from stdin archive           $ECHO_C"
5349     at_xfail=no
5350       test -f $XFAILFILE && at_xfail=yes
5351     echo "#                             -*- compilation -*-" >> "$at_group_log"
5352     (
5353       echo "14. delete02.at:23: testing ..."
5354       $at_traceon
5355
5356
5357
5358
5359
5360   $at_traceoff
5361 echo "$at_srcdir/delete02.at:26:
5362 mkdir v7
5363 (cd v7
5364 TEST_TAR_FORMAT=v7
5365 export TEST_TAR_FORMAT
5366 TAR_OPTIONS=\"-H v7\"
5367 export TAR_OPTIONS
5368 rm -rf *
5369
5370 genfile -l 3073 -p zeros --file 1
5371 cp 1 2
5372 cp 2 3
5373 tar cf archive 1 2 3
5374 tar tf archive
5375 cat archive | tar f - --delete 2 > archive2
5376 echo separator
5377 tar tf archive2)"
5378 echo delete02.at:26 >"$at_check_line_file"
5379
5380 at_trace_this=
5381 if test -n "$at_traceon"; then
5382     echo 'Not enabling shell tracing (command contains an embedded newline)'
5383 fi
5384
5385 if test -n "$at_trace_this"; then
5386     ( $at_traceon;
5387 mkdir v7
5388 (cd v7
5389 TEST_TAR_FORMAT=v7
5390 export TEST_TAR_FORMAT
5391 TAR_OPTIONS="-H v7"
5392 export TAR_OPTIONS
5393 rm -rf *
5394
5395 genfile -l 3073 -p zeros --file 1
5396 cp 1 2
5397 cp 2 3
5398 tar cf archive 1 2 3
5399 tar tf archive
5400 cat archive | tar f - --delete 2 > archive2
5401 echo separator
5402 tar tf archive2) ) >"$at_stdout" 2>"$at_stder1"
5403     at_status=$?
5404     grep '^ *+' "$at_stder1" >&2
5405     grep -v '^ *+' "$at_stder1" >"$at_stderr"
5406 else
5407     ( :;
5408 mkdir v7
5409 (cd v7
5410 TEST_TAR_FORMAT=v7
5411 export TEST_TAR_FORMAT
5412 TAR_OPTIONS="-H v7"
5413 export TAR_OPTIONS
5414 rm -rf *
5415
5416 genfile -l 3073 -p zeros --file 1
5417 cp 1 2
5418 cp 2 3
5419 tar cf archive 1 2 3
5420 tar tf archive
5421 cat archive | tar f - --delete 2 > archive2
5422 echo separator
5423 tar tf archive2) ) >"$at_stdout" 2>"$at_stderr"
5424     at_status=$?
5425 fi
5426
5427 at_failed=false
5428 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
5429 echo >>"$at_stdout"; echo "1
5430 2
5431 3
5432 separator
5433 1
5434 3
5435 " | $at_diff - "$at_stdout" || at_failed=:
5436 case $at_status in
5437    77) echo 77 > "$at_status_file"; exit 77;;
5438    0) ;;
5439    *) echo "$at_srcdir/delete02.at:26: exit code was $at_status, expected 0"
5440       at_failed=:;;
5441 esac
5442 if $at_failed; then
5443
5444
5445   echo 1 > "$at_status_file"
5446   exit 1
5447 fi
5448
5449 $at_traceon
5450 $at_traceoff
5451 echo "$at_srcdir/delete02.at:26:
5452 mkdir oldgnu
5453 (cd oldgnu
5454 TEST_TAR_FORMAT=oldgnu
5455 export TEST_TAR_FORMAT
5456 TAR_OPTIONS=\"-H oldgnu\"
5457 export TAR_OPTIONS
5458 rm -rf *
5459
5460 genfile -l 3073 -p zeros --file 1
5461 cp 1 2
5462 cp 2 3
5463 tar cf archive 1 2 3
5464 tar tf archive
5465 cat archive | tar f - --delete 2 > archive2
5466 echo separator
5467 tar tf archive2)"
5468 echo delete02.at:26 >"$at_check_line_file"
5469
5470 at_trace_this=
5471 if test -n "$at_traceon"; then
5472     echo 'Not enabling shell tracing (command contains an embedded newline)'
5473 fi
5474
5475 if test -n "$at_trace_this"; then
5476     ( $at_traceon;
5477 mkdir oldgnu
5478 (cd oldgnu
5479 TEST_TAR_FORMAT=oldgnu
5480 export TEST_TAR_FORMAT
5481 TAR_OPTIONS="-H oldgnu"
5482 export TAR_OPTIONS
5483 rm -rf *
5484
5485 genfile -l 3073 -p zeros --file 1
5486 cp 1 2
5487 cp 2 3
5488 tar cf archive 1 2 3
5489 tar tf archive
5490 cat archive | tar f - --delete 2 > archive2
5491 echo separator
5492 tar tf archive2) ) >"$at_stdout" 2>"$at_stder1"
5493     at_status=$?
5494     grep '^ *+' "$at_stder1" >&2
5495     grep -v '^ *+' "$at_stder1" >"$at_stderr"
5496 else
5497     ( :;
5498 mkdir oldgnu
5499 (cd oldgnu
5500 TEST_TAR_FORMAT=oldgnu
5501 export TEST_TAR_FORMAT
5502 TAR_OPTIONS="-H oldgnu"
5503 export TAR_OPTIONS
5504 rm -rf *
5505
5506 genfile -l 3073 -p zeros --file 1
5507 cp 1 2
5508 cp 2 3
5509 tar cf archive 1 2 3
5510 tar tf archive
5511 cat archive | tar f - --delete 2 > archive2
5512 echo separator
5513 tar tf archive2) ) >"$at_stdout" 2>"$at_stderr"
5514     at_status=$?
5515 fi
5516
5517 at_failed=false
5518 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
5519 echo >>"$at_stdout"; echo "1
5520 2
5521 3
5522 separator
5523 1
5524 3
5525 " | $at_diff - "$at_stdout" || at_failed=:
5526 case $at_status in
5527    77) echo 77 > "$at_status_file"; exit 77;;
5528    0) ;;
5529    *) echo "$at_srcdir/delete02.at:26: exit code was $at_status, expected 0"
5530       at_failed=:;;
5531 esac
5532 if $at_failed; then
5533
5534
5535   echo 1 > "$at_status_file"
5536   exit 1
5537 fi
5538
5539 $at_traceon
5540 $at_traceoff
5541 echo "$at_srcdir/delete02.at:26:
5542 mkdir ustar
5543 (cd ustar
5544 TEST_TAR_FORMAT=ustar
5545 export TEST_TAR_FORMAT
5546 TAR_OPTIONS=\"-H ustar\"
5547 export TAR_OPTIONS
5548 rm -rf *
5549
5550 genfile -l 3073 -p zeros --file 1
5551 cp 1 2
5552 cp 2 3
5553 tar cf archive 1 2 3
5554 tar tf archive
5555 cat archive | tar f - --delete 2 > archive2
5556 echo separator
5557 tar tf archive2)"
5558 echo delete02.at:26 >"$at_check_line_file"
5559
5560 at_trace_this=
5561 if test -n "$at_traceon"; then
5562     echo 'Not enabling shell tracing (command contains an embedded newline)'
5563 fi
5564
5565 if test -n "$at_trace_this"; then
5566     ( $at_traceon;
5567 mkdir ustar
5568 (cd ustar
5569 TEST_TAR_FORMAT=ustar
5570 export TEST_TAR_FORMAT
5571 TAR_OPTIONS="-H ustar"
5572 export TAR_OPTIONS
5573 rm -rf *
5574
5575 genfile -l 3073 -p zeros --file 1
5576 cp 1 2
5577 cp 2 3
5578 tar cf archive 1 2 3
5579 tar tf archive
5580 cat archive | tar f - --delete 2 > archive2
5581 echo separator
5582 tar tf archive2) ) >"$at_stdout" 2>"$at_stder1"
5583     at_status=$?
5584     grep '^ *+' "$at_stder1" >&2
5585     grep -v '^ *+' "$at_stder1" >"$at_stderr"
5586 else
5587     ( :;
5588 mkdir ustar
5589 (cd ustar
5590 TEST_TAR_FORMAT=ustar
5591 export TEST_TAR_FORMAT
5592 TAR_OPTIONS="-H ustar"
5593 export TAR_OPTIONS
5594 rm -rf *
5595
5596 genfile -l 3073 -p zeros --file 1
5597 cp 1 2
5598 cp 2 3
5599 tar cf archive 1 2 3
5600 tar tf archive
5601 cat archive | tar f - --delete 2 > archive2
5602 echo separator
5603 tar tf archive2) ) >"$at_stdout" 2>"$at_stderr"
5604     at_status=$?
5605 fi
5606
5607 at_failed=false
5608 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
5609 echo >>"$at_stdout"; echo "1
5610 2
5611 3
5612 separator
5613 1
5614 3
5615 " | $at_diff - "$at_stdout" || at_failed=:
5616 case $at_status in
5617    77) echo 77 > "$at_status_file"; exit 77;;
5618    0) ;;
5619    *) echo "$at_srcdir/delete02.at:26: exit code was $at_status, expected 0"
5620       at_failed=:;;
5621 esac
5622 if $at_failed; then
5623
5624
5625   echo 1 > "$at_status_file"
5626   exit 1
5627 fi
5628
5629 $at_traceon
5630 $at_traceoff
5631 echo "$at_srcdir/delete02.at:26:
5632 mkdir posix
5633 (cd posix
5634 TEST_TAR_FORMAT=posix
5635 export TEST_TAR_FORMAT
5636 TAR_OPTIONS=\"-H posix\"
5637 export TAR_OPTIONS
5638 rm -rf *
5639
5640 genfile -l 3073 -p zeros --file 1
5641 cp 1 2
5642 cp 2 3
5643 tar cf archive 1 2 3
5644 tar tf archive
5645 cat archive | tar f - --delete 2 > archive2
5646 echo separator
5647 tar tf archive2)"
5648 echo delete02.at:26 >"$at_check_line_file"
5649
5650 at_trace_this=
5651 if test -n "$at_traceon"; then
5652     echo 'Not enabling shell tracing (command contains an embedded newline)'
5653 fi
5654
5655 if test -n "$at_trace_this"; then
5656     ( $at_traceon;
5657 mkdir posix
5658 (cd posix
5659 TEST_TAR_FORMAT=posix
5660 export TEST_TAR_FORMAT
5661 TAR_OPTIONS="-H posix"
5662 export TAR_OPTIONS
5663 rm -rf *
5664
5665 genfile -l 3073 -p zeros --file 1
5666 cp 1 2
5667 cp 2 3
5668 tar cf archive 1 2 3
5669 tar tf archive
5670 cat archive | tar f - --delete 2 > archive2
5671 echo separator
5672 tar tf archive2) ) >"$at_stdout" 2>"$at_stder1"
5673     at_status=$?
5674     grep '^ *+' "$at_stder1" >&2
5675     grep -v '^ *+' "$at_stder1" >"$at_stderr"
5676 else
5677     ( :;
5678 mkdir posix
5679 (cd posix
5680 TEST_TAR_FORMAT=posix
5681 export TEST_TAR_FORMAT
5682 TAR_OPTIONS="-H posix"
5683 export TAR_OPTIONS
5684 rm -rf *
5685
5686 genfile -l 3073 -p zeros --file 1
5687 cp 1 2
5688 cp 2 3
5689 tar cf archive 1 2 3
5690 tar tf archive
5691 cat archive | tar f - --delete 2 > archive2
5692 echo separator
5693 tar tf archive2) ) >"$at_stdout" 2>"$at_stderr"
5694     at_status=$?
5695 fi
5696
5697 at_failed=false
5698 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
5699 echo >>"$at_stdout"; echo "1
5700 2
5701 3
5702 separator
5703 1
5704 3
5705 " | $at_diff - "$at_stdout" || at_failed=:
5706 case $at_status in
5707    77) echo 77 > "$at_status_file"; exit 77;;
5708    0) ;;
5709    *) echo "$at_srcdir/delete02.at:26: exit code was $at_status, expected 0"
5710       at_failed=:;;
5711 esac
5712 if $at_failed; then
5713
5714
5715   echo 1 > "$at_status_file"
5716   exit 1
5717 fi
5718
5719 $at_traceon
5720 $at_traceoff
5721 echo "$at_srcdir/delete02.at:26:
5722 mkdir gnu
5723 (cd gnu
5724 TEST_TAR_FORMAT=gnu
5725 export TEST_TAR_FORMAT
5726 TAR_OPTIONS=\"-H gnu\"
5727 export TAR_OPTIONS
5728 rm -rf *
5729
5730 genfile -l 3073 -p zeros --file 1
5731 cp 1 2
5732 cp 2 3
5733 tar cf archive 1 2 3
5734 tar tf archive
5735 cat archive | tar f - --delete 2 > archive2
5736 echo separator
5737 tar tf archive2)"
5738 echo delete02.at:26 >"$at_check_line_file"
5739
5740 at_trace_this=
5741 if test -n "$at_traceon"; then
5742     echo 'Not enabling shell tracing (command contains an embedded newline)'
5743 fi
5744
5745 if test -n "$at_trace_this"; then
5746     ( $at_traceon;
5747 mkdir gnu
5748 (cd gnu
5749 TEST_TAR_FORMAT=gnu
5750 export TEST_TAR_FORMAT
5751 TAR_OPTIONS="-H gnu"
5752 export TAR_OPTIONS
5753 rm -rf *
5754
5755 genfile -l 3073 -p zeros --file 1
5756 cp 1 2
5757 cp 2 3
5758 tar cf archive 1 2 3
5759 tar tf archive
5760 cat archive | tar f - --delete 2 > archive2
5761 echo separator
5762 tar tf archive2) ) >"$at_stdout" 2>"$at_stder1"
5763     at_status=$?
5764     grep '^ *+' "$at_stder1" >&2
5765     grep -v '^ *+' "$at_stder1" >"$at_stderr"
5766 else
5767     ( :;
5768 mkdir gnu
5769 (cd gnu
5770 TEST_TAR_FORMAT=gnu
5771 export TEST_TAR_FORMAT
5772 TAR_OPTIONS="-H gnu"
5773 export TAR_OPTIONS
5774 rm -rf *
5775
5776 genfile -l 3073 -p zeros --file 1
5777 cp 1 2
5778 cp 2 3
5779 tar cf archive 1 2 3
5780 tar tf archive
5781 cat archive | tar f - --delete 2 > archive2
5782 echo separator
5783 tar tf archive2) ) >"$at_stdout" 2>"$at_stderr"
5784     at_status=$?
5785 fi
5786
5787 at_failed=false
5788 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
5789 echo >>"$at_stdout"; echo "1
5790 2
5791 3
5792 separator
5793 1
5794 3
5795 " | $at_diff - "$at_stdout" || at_failed=:
5796 case $at_status in
5797    77) echo 77 > "$at_status_file"; exit 77;;
5798    0) ;;
5799    *) echo "$at_srcdir/delete02.at:26: exit code was $at_status, expected 0"
5800       at_failed=:;;
5801 esac
5802 if $at_failed; then
5803
5804
5805   echo 1 > "$at_status_file"
5806   exit 1
5807 fi
5808
5809 $at_traceon
5810
5811
5812
5813       $at_traceoff
5814       $at_times_p && times >"$at_times_file"
5815     ) 5>&1 2>&1 | eval $at_tee_pipe
5816     at_status=`cat "$at_status_file"`
5817     ;;
5818
5819   15 ) # 15. delete03.at:21: deleting members with long names
5820     at_setup_line='delete03.at:21'
5821     at_desc="deleting members with long names"
5822     $at_quiet $ECHO_N " 15: deleting members with long names               $ECHO_C"
5823     at_xfail=no
5824       test -f $XFAILFILE && at_xfail=yes
5825     echo "#                             -*- compilation -*-" >> "$at_group_log"
5826     (
5827       echo "15. delete03.at:21: testing ..."
5828       $at_traceon
5829
5830
5831
5832
5833
5834
5835
5836   $at_traceoff
5837 echo "$at_srcdir/delete03.at:26:
5838 mkdir gnu
5839 (cd gnu
5840 TEST_TAR_FORMAT=gnu
5841 export TEST_TAR_FORMAT
5842 TAR_OPTIONS=\"-H gnu\"
5843 export TAR_OPTIONS
5844 rm -rf *
5845
5846
5847 prefix=This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX
5848 rm -f \$prefix*
5849 for i in 1 2 3 4 5 6 7 8 9
5850 do touch \$prefix\$i
5851 done
5852 tar -cf archive ./\$prefix* &&
5853  tar --delete -f archive ./\${prefix}5 &&
5854  tar -tf archive
5855 )"
5856 echo delete03.at:26 >"$at_check_line_file"
5857
5858 at_trace_this=
5859 if test -n "$at_traceon"; then
5860     echo 'Not enabling shell tracing (command contains a ${...} parameter expansion)'
5861 fi
5862
5863 if test -n "$at_trace_this"; then
5864     ( $at_traceon;
5865 mkdir gnu
5866 (cd gnu
5867 TEST_TAR_FORMAT=gnu
5868 export TEST_TAR_FORMAT
5869 TAR_OPTIONS="-H gnu"
5870 export TAR_OPTIONS
5871 rm -rf *
5872
5873
5874 prefix=This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX
5875 rm -f $prefix*
5876 for i in 1 2 3 4 5 6 7 8 9
5877 do touch $prefix$i
5878 done
5879 tar -cf archive ./$prefix* &&
5880  tar --delete -f archive ./${prefix}5 &&
5881  tar -tf archive
5882 ) ) >"$at_stdout" 2>"$at_stder1"
5883     at_status=$?
5884     grep '^ *+' "$at_stder1" >&2
5885     grep -v '^ *+' "$at_stder1" >"$at_stderr"
5886 else
5887     ( :;
5888 mkdir gnu
5889 (cd gnu
5890 TEST_TAR_FORMAT=gnu
5891 export TEST_TAR_FORMAT
5892 TAR_OPTIONS="-H gnu"
5893 export TAR_OPTIONS
5894 rm -rf *
5895
5896
5897 prefix=This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX
5898 rm -f $prefix*
5899 for i in 1 2 3 4 5 6 7 8 9
5900 do touch $prefix$i
5901 done
5902 tar -cf archive ./$prefix* &&
5903  tar --delete -f archive ./${prefix}5 &&
5904  tar -tf archive
5905 ) ) >"$at_stdout" 2>"$at_stderr"
5906     at_status=$?
5907 fi
5908
5909 at_failed=false
5910 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
5911 echo >>"$at_stdout"; echo "./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX1
5912 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX2
5913 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX3
5914 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX4
5915 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX6
5916 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX7
5917 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX8
5918 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX9
5919 " | $at_diff - "$at_stdout" || at_failed=:
5920 case $at_status in
5921    77) echo 77 > "$at_status_file"; exit 77;;
5922    0) ;;
5923    *) echo "$at_srcdir/delete03.at:26: exit code was $at_status, expected 0"
5924       at_failed=:;;
5925 esac
5926 if $at_failed; then
5927
5928
5929   echo 1 > "$at_status_file"
5930   exit 1
5931 fi
5932
5933 $at_traceon
5934 $at_traceoff
5935 echo "$at_srcdir/delete03.at:26:
5936 mkdir oldgnu
5937 (cd oldgnu
5938 TEST_TAR_FORMAT=oldgnu
5939 export TEST_TAR_FORMAT
5940 TAR_OPTIONS=\"-H oldgnu\"
5941 export TAR_OPTIONS
5942 rm -rf *
5943
5944
5945 prefix=This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX
5946 rm -f \$prefix*
5947 for i in 1 2 3 4 5 6 7 8 9
5948 do touch \$prefix\$i
5949 done
5950 tar -cf archive ./\$prefix* &&
5951  tar --delete -f archive ./\${prefix}5 &&
5952  tar -tf archive
5953 )"
5954 echo delete03.at:26 >"$at_check_line_file"
5955
5956 at_trace_this=
5957 if test -n "$at_traceon"; then
5958     echo 'Not enabling shell tracing (command contains a ${...} parameter expansion)'
5959 fi
5960
5961 if test -n "$at_trace_this"; then
5962     ( $at_traceon;
5963 mkdir oldgnu
5964 (cd oldgnu
5965 TEST_TAR_FORMAT=oldgnu
5966 export TEST_TAR_FORMAT
5967 TAR_OPTIONS="-H oldgnu"
5968 export TAR_OPTIONS
5969 rm -rf *
5970
5971
5972 prefix=This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX
5973 rm -f $prefix*
5974 for i in 1 2 3 4 5 6 7 8 9
5975 do touch $prefix$i
5976 done
5977 tar -cf archive ./$prefix* &&
5978  tar --delete -f archive ./${prefix}5 &&
5979  tar -tf archive
5980 ) ) >"$at_stdout" 2>"$at_stder1"
5981     at_status=$?
5982     grep '^ *+' "$at_stder1" >&2
5983     grep -v '^ *+' "$at_stder1" >"$at_stderr"
5984 else
5985     ( :;
5986 mkdir oldgnu
5987 (cd oldgnu
5988 TEST_TAR_FORMAT=oldgnu
5989 export TEST_TAR_FORMAT
5990 TAR_OPTIONS="-H oldgnu"
5991 export TAR_OPTIONS
5992 rm -rf *
5993
5994
5995 prefix=This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX
5996 rm -f $prefix*
5997 for i in 1 2 3 4 5 6 7 8 9
5998 do touch $prefix$i
5999 done
6000 tar -cf archive ./$prefix* &&
6001  tar --delete -f archive ./${prefix}5 &&
6002  tar -tf archive
6003 ) ) >"$at_stdout" 2>"$at_stderr"
6004     at_status=$?
6005 fi
6006
6007 at_failed=false
6008 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
6009 echo >>"$at_stdout"; echo "./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX1
6010 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX2
6011 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX3
6012 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX4
6013 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX6
6014 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX7
6015 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX8
6016 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX9
6017 " | $at_diff - "$at_stdout" || at_failed=:
6018 case $at_status in
6019    77) echo 77 > "$at_status_file"; exit 77;;
6020    0) ;;
6021    *) echo "$at_srcdir/delete03.at:26: exit code was $at_status, expected 0"
6022       at_failed=:;;
6023 esac
6024 if $at_failed; then
6025
6026
6027   echo 1 > "$at_status_file"
6028   exit 1
6029 fi
6030
6031 $at_traceon
6032 $at_traceoff
6033 echo "$at_srcdir/delete03.at:26:
6034 mkdir posix
6035 (cd posix
6036 TEST_TAR_FORMAT=posix
6037 export TEST_TAR_FORMAT
6038 TAR_OPTIONS=\"-H posix\"
6039 export TAR_OPTIONS
6040 rm -rf *
6041
6042
6043 prefix=This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX
6044 rm -f \$prefix*
6045 for i in 1 2 3 4 5 6 7 8 9
6046 do touch \$prefix\$i
6047 done
6048 tar -cf archive ./\$prefix* &&
6049  tar --delete -f archive ./\${prefix}5 &&
6050  tar -tf archive
6051 )"
6052 echo delete03.at:26 >"$at_check_line_file"
6053
6054 at_trace_this=
6055 if test -n "$at_traceon"; then
6056     echo 'Not enabling shell tracing (command contains a ${...} parameter expansion)'
6057 fi
6058
6059 if test -n "$at_trace_this"; then
6060     ( $at_traceon;
6061 mkdir posix
6062 (cd posix
6063 TEST_TAR_FORMAT=posix
6064 export TEST_TAR_FORMAT
6065 TAR_OPTIONS="-H posix"
6066 export TAR_OPTIONS
6067 rm -rf *
6068
6069
6070 prefix=This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX
6071 rm -f $prefix*
6072 for i in 1 2 3 4 5 6 7 8 9
6073 do touch $prefix$i
6074 done
6075 tar -cf archive ./$prefix* &&
6076  tar --delete -f archive ./${prefix}5 &&
6077  tar -tf archive
6078 ) ) >"$at_stdout" 2>"$at_stder1"
6079     at_status=$?
6080     grep '^ *+' "$at_stder1" >&2
6081     grep -v '^ *+' "$at_stder1" >"$at_stderr"
6082 else
6083     ( :;
6084 mkdir posix
6085 (cd posix
6086 TEST_TAR_FORMAT=posix
6087 export TEST_TAR_FORMAT
6088 TAR_OPTIONS="-H posix"
6089 export TAR_OPTIONS
6090 rm -rf *
6091
6092
6093 prefix=This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX
6094 rm -f $prefix*
6095 for i in 1 2 3 4 5 6 7 8 9
6096 do touch $prefix$i
6097 done
6098 tar -cf archive ./$prefix* &&
6099  tar --delete -f archive ./${prefix}5 &&
6100  tar -tf archive
6101 ) ) >"$at_stdout" 2>"$at_stderr"
6102     at_status=$?
6103 fi
6104
6105 at_failed=false
6106 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
6107 echo >>"$at_stdout"; echo "./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX1
6108 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX2
6109 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX3
6110 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX4
6111 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX6
6112 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX7
6113 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX8
6114 ./This_is_a_very_long_file_name_prefix_that_is_designed_to_cause_problems_with_file_names_that_run_into_a_limit_of_the_posix_tar_formatXX9
6115 " | $at_diff - "$at_stdout" || at_failed=:
6116 case $at_status in
6117    77) echo 77 > "$at_status_file"; exit 77;;
6118    0) ;;
6119    *) echo "$at_srcdir/delete03.at:26: exit code was $at_status, expected 0"
6120       at_failed=:;;
6121 esac
6122 if $at_failed; then
6123
6124
6125   echo 1 > "$at_status_file"
6126   exit 1
6127 fi
6128
6129 $at_traceon
6130
6131
6132
6133       $at_traceoff
6134       $at_times_p && times >"$at_times_file"
6135     ) 5>&1 2>&1 | eval $at_tee_pipe
6136     at_status=`cat "$at_status_file"`
6137     ;;
6138
6139   16 ) # 16. delete04.at:23: deleting a large last member
6140     at_setup_line='delete04.at:23'
6141     at_desc="deleting a large last member"
6142     $at_quiet $ECHO_N " 16: deleting a large last member                   $ECHO_C"
6143     at_xfail=no
6144       test -f $XFAILFILE && at_xfail=yes
6145     echo "#                             -*- compilation -*-" >> "$at_group_log"
6146     (
6147       echo "16. delete04.at:23: testing ..."
6148       $at_traceon
6149
6150
6151
6152
6153
6154   $at_traceoff
6155 echo "$at_srcdir/delete04.at:26:
6156 mkdir v7
6157 (cd v7
6158 TEST_TAR_FORMAT=v7
6159 export TEST_TAR_FORMAT
6160 TAR_OPTIONS=\"-H v7\"
6161 export TAR_OPTIONS
6162 rm -rf *
6163
6164 genfile -l      3 -f file1
6165 genfile -l      5 -f file2
6166 genfile -l      3 -f file3
6167 genfile -l      6 -f file4
6168 genfile -l     24 -f file5
6169 genfile -l     13 -f file6
6170 genfile -l   1385 -f file7
6171 genfile -l     30 -f file8
6172 genfile -l     10 -f file9
6173 genfile -l 256000 -f file10
6174 tar cf archive file1 file2 file3 file4 file5 file6 file7 file8 file9 file10
6175 tar f archive --delete file10
6176 tar tf archive
6177 )"
6178 echo delete04.at:26 >"$at_check_line_file"
6179
6180 at_trace_this=
6181 if test -n "$at_traceon"; then
6182     echo 'Not enabling shell tracing (command contains an embedded newline)'
6183 fi
6184
6185 if test -n "$at_trace_this"; then
6186     ( $at_traceon;
6187 mkdir v7
6188 (cd v7
6189 TEST_TAR_FORMAT=v7
6190 export TEST_TAR_FORMAT
6191 TAR_OPTIONS="-H v7"
6192 export TAR_OPTIONS
6193 rm -rf *
6194
6195 genfile -l      3 -f file1
6196 genfile -l      5 -f file2
6197 genfile -l      3 -f file3
6198 genfile -l      6 -f file4
6199 genfile -l     24 -f file5
6200 genfile -l     13 -f file6
6201 genfile -l   1385 -f file7
6202 genfile -l     30 -f file8
6203 genfile -l     10 -f file9
6204 genfile -l 256000 -f file10
6205 tar cf archive file1 file2 file3 file4 file5 file6 file7 file8 file9 file10
6206 tar f archive --delete file10
6207 tar tf archive
6208 ) ) >"$at_stdout" 2>"$at_stder1"
6209     at_status=$?
6210     grep '^ *+' "$at_stder1" >&2
6211     grep -v '^ *+' "$at_stder1" >"$at_stderr"
6212 else
6213     ( :;
6214 mkdir v7
6215 (cd v7
6216 TEST_TAR_FORMAT=v7
6217 export TEST_TAR_FORMAT
6218 TAR_OPTIONS="-H v7"
6219 export TAR_OPTIONS
6220 rm -rf *
6221
6222 genfile -l      3 -f file1
6223 genfile -l      5 -f file2
6224 genfile -l      3 -f file3
6225 genfile -l      6 -f file4
6226 genfile -l     24 -f file5
6227 genfile -l     13 -f file6
6228 genfile -l   1385 -f file7
6229 genfile -l     30 -f file8
6230 genfile -l     10 -f file9
6231 genfile -l 256000 -f file10
6232 tar cf archive file1 file2 file3 file4 file5 file6 file7 file8 file9 file10
6233 tar f archive --delete file10
6234 tar tf archive
6235 ) ) >"$at_stdout" 2>"$at_stderr"
6236     at_status=$?
6237 fi
6238
6239 at_failed=false
6240 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
6241 echo >>"$at_stdout"; echo "file1
6242 file2
6243 file3
6244 file4
6245 file5
6246 file6
6247 file7
6248 file8
6249 file9
6250 " | $at_diff - "$at_stdout" || at_failed=:
6251 case $at_status in
6252    77) echo 77 > "$at_status_file"; exit 77;;
6253    0) ;;
6254    *) echo "$at_srcdir/delete04.at:26: exit code was $at_status, expected 0"
6255       at_failed=:;;
6256 esac
6257 if $at_failed; then
6258
6259
6260   echo 1 > "$at_status_file"
6261   exit 1
6262 fi
6263
6264 $at_traceon
6265 $at_traceoff
6266 echo "$at_srcdir/delete04.at:26:
6267 mkdir oldgnu
6268 (cd oldgnu
6269 TEST_TAR_FORMAT=oldgnu
6270 export TEST_TAR_FORMAT
6271 TAR_OPTIONS=\"-H oldgnu\"
6272 export TAR_OPTIONS
6273 rm -rf *
6274
6275 genfile -l      3 -f file1
6276 genfile -l      5 -f file2
6277 genfile -l      3 -f file3
6278 genfile -l      6 -f file4
6279 genfile -l     24 -f file5
6280 genfile -l     13 -f file6
6281 genfile -l   1385 -f file7
6282 genfile -l     30 -f file8
6283 genfile -l     10 -f file9
6284 genfile -l 256000 -f file10
6285 tar cf archive file1 file2 file3 file4 file5 file6 file7 file8 file9 file10
6286 tar f archive --delete file10
6287 tar tf archive
6288 )"
6289 echo delete04.at:26 >"$at_check_line_file"
6290
6291 at_trace_this=
6292 if test -n "$at_traceon"; then
6293     echo 'Not enabling shell tracing (command contains an embedded newline)'
6294 fi
6295
6296 if test -n "$at_trace_this"; then
6297     ( $at_traceon;
6298 mkdir oldgnu
6299 (cd oldgnu
6300 TEST_TAR_FORMAT=oldgnu
6301 export TEST_TAR_FORMAT
6302 TAR_OPTIONS="-H oldgnu"
6303 export TAR_OPTIONS
6304 rm -rf *
6305
6306 genfile -l      3 -f file1
6307 genfile -l      5 -f file2
6308 genfile -l      3 -f file3
6309 genfile -l      6 -f file4
6310 genfile -l     24 -f file5
6311 genfile -l     13 -f file6
6312 genfile -l   1385 -f file7
6313 genfile -l     30 -f file8
6314 genfile -l     10 -f file9
6315 genfile -l 256000 -f file10
6316 tar cf archive file1 file2 file3 file4 file5 file6 file7 file8 file9 file10
6317 tar f archive --delete file10
6318 tar tf archive
6319 ) ) >"$at_stdout" 2>"$at_stder1"
6320     at_status=$?
6321     grep '^ *+' "$at_stder1" >&2
6322     grep -v '^ *+' "$at_stder1" >"$at_stderr"
6323 else
6324     ( :;
6325 mkdir oldgnu
6326 (cd oldgnu
6327 TEST_TAR_FORMAT=oldgnu
6328 export TEST_TAR_FORMAT
6329 TAR_OPTIONS="-H oldgnu"
6330 export TAR_OPTIONS
6331 rm -rf *
6332
6333 genfile -l      3 -f file1
6334 genfile -l      5 -f file2
6335 genfile -l      3 -f file3
6336 genfile -l      6 -f file4
6337 genfile -l     24 -f file5
6338 genfile -l     13 -f file6
6339 genfile -l   1385 -f file7
6340 genfile -l     30 -f file8
6341 genfile -l     10 -f file9
6342 genfile -l 256000 -f file10
6343 tar cf archive file1 file2 file3 file4 file5 file6 file7 file8 file9 file10
6344 tar f archive --delete file10
6345 tar tf archive
6346 ) ) >"$at_stdout" 2>"$at_stderr"
6347     at_status=$?
6348 fi
6349
6350 at_failed=false
6351 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
6352 echo >>"$at_stdout"; echo "file1
6353 file2
6354 file3
6355 file4
6356 file5
6357 file6
6358 file7
6359 file8
6360 file9
6361 " | $at_diff - "$at_stdout" || at_failed=:
6362 case $at_status in
6363    77) echo 77 > "$at_status_file"; exit 77;;
6364    0) ;;
6365    *) echo "$at_srcdir/delete04.at:26: exit code was $at_status, expected 0"
6366       at_failed=:;;
6367 esac
6368 if $at_failed; then
6369
6370
6371   echo 1 > "$at_status_file"
6372   exit 1
6373 fi
6374
6375 $at_traceon
6376 $at_traceoff
6377 echo "$at_srcdir/delete04.at:26:
6378 mkdir ustar
6379 (cd ustar
6380 TEST_TAR_FORMAT=ustar
6381 export TEST_TAR_FORMAT
6382 TAR_OPTIONS=\"-H ustar\"
6383 export TAR_OPTIONS
6384 rm -rf *
6385
6386 genfile -l      3 -f file1
6387 genfile -l      5 -f file2
6388 genfile -l      3 -f file3
6389 genfile -l      6 -f file4
6390 genfile -l     24 -f file5
6391 genfile -l     13 -f file6
6392 genfile -l   1385 -f file7
6393 genfile -l     30 -f file8
6394 genfile -l     10 -f file9
6395 genfile -l 256000 -f file10
6396 tar cf archive file1 file2 file3 file4 file5 file6 file7 file8 file9 file10
6397 tar f archive --delete file10
6398 tar tf archive
6399 )"
6400 echo delete04.at:26 >"$at_check_line_file"
6401
6402 at_trace_this=
6403 if test -n "$at_traceon"; then
6404     echo 'Not enabling shell tracing (command contains an embedded newline)'
6405 fi
6406
6407 if test -n "$at_trace_this"; then
6408     ( $at_traceon;
6409 mkdir ustar
6410 (cd ustar
6411 TEST_TAR_FORMAT=ustar
6412 export TEST_TAR_FORMAT
6413 TAR_OPTIONS="-H ustar"
6414 export TAR_OPTIONS
6415 rm -rf *
6416
6417 genfile -l      3 -f file1
6418 genfile -l      5 -f file2
6419 genfile -l      3 -f file3
6420 genfile -l      6 -f file4
6421 genfile -l     24 -f file5
6422 genfile -l     13 -f file6
6423 genfile -l   1385 -f file7
6424 genfile -l     30 -f file8
6425 genfile -l     10 -f file9
6426 genfile -l 256000 -f file10
6427 tar cf archive file1 file2 file3 file4 file5 file6 file7 file8 file9 file10
6428 tar f archive --delete file10
6429 tar tf archive
6430 ) ) >"$at_stdout" 2>"$at_stder1"
6431     at_status=$?
6432     grep '^ *+' "$at_stder1" >&2
6433     grep -v '^ *+' "$at_stder1" >"$at_stderr"
6434 else
6435     ( :;
6436 mkdir ustar
6437 (cd ustar
6438 TEST_TAR_FORMAT=ustar
6439 export TEST_TAR_FORMAT
6440 TAR_OPTIONS="-H ustar"
6441 export TAR_OPTIONS
6442 rm -rf *
6443
6444 genfile -l      3 -f file1
6445 genfile -l      5 -f file2
6446 genfile -l      3 -f file3
6447 genfile -l      6 -f file4
6448 genfile -l     24 -f file5
6449 genfile -l     13 -f file6
6450 genfile -l   1385 -f file7
6451 genfile -l     30 -f file8
6452 genfile -l     10 -f file9
6453 genfile -l 256000 -f file10
6454 tar cf archive file1 file2 file3 file4 file5 file6 file7 file8 file9 file10
6455 tar f archive --delete file10
6456 tar tf archive
6457 ) ) >"$at_stdout" 2>"$at_stderr"
6458     at_status=$?
6459 fi
6460
6461 at_failed=false
6462 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
6463 echo >>"$at_stdout"; echo "file1
6464 file2
6465 file3
6466 file4
6467 file5
6468 file6
6469 file7
6470 file8
6471 file9
6472 " | $at_diff - "$at_stdout" || at_failed=:
6473 case $at_status in
6474    77) echo 77 > "$at_status_file"; exit 77;;
6475    0) ;;
6476    *) echo "$at_srcdir/delete04.at:26: exit code was $at_status, expected 0"
6477       at_failed=:;;
6478 esac
6479 if $at_failed; then
6480
6481
6482   echo 1 > "$at_status_file"
6483   exit 1
6484 fi
6485
6486 $at_traceon
6487 $at_traceoff
6488 echo "$at_srcdir/delete04.at:26:
6489 mkdir posix
6490 (cd posix
6491 TEST_TAR_FORMAT=posix
6492 export TEST_TAR_FORMAT
6493 TAR_OPTIONS=\"-H posix\"
6494 export TAR_OPTIONS
6495 rm -rf *
6496
6497 genfile -l      3 -f file1
6498 genfile -l      5 -f file2
6499 genfile -l      3 -f file3
6500 genfile -l      6 -f file4
6501 genfile -l     24 -f file5
6502 genfile -l     13 -f file6
6503 genfile -l   1385 -f file7
6504 genfile -l     30 -f file8
6505 genfile -l     10 -f file9
6506 genfile -l 256000 -f file10
6507 tar cf archive file1 file2 file3 file4 file5 file6 file7 file8 file9 file10
6508 tar f archive --delete file10
6509 tar tf archive
6510 )"
6511 echo delete04.at:26 >"$at_check_line_file"
6512
6513 at_trace_this=
6514 if test -n "$at_traceon"; then
6515     echo 'Not enabling shell tracing (command contains an embedded newline)'
6516 fi
6517
6518 if test -n "$at_trace_this"; then
6519     ( $at_traceon;
6520 mkdir posix
6521 (cd posix
6522 TEST_TAR_FORMAT=posix
6523 export TEST_TAR_FORMAT
6524 TAR_OPTIONS="-H posix"
6525 export TAR_OPTIONS
6526 rm -rf *
6527
6528 genfile -l      3 -f file1
6529 genfile -l      5 -f file2
6530 genfile -l      3 -f file3
6531 genfile -l      6 -f file4
6532 genfile -l     24 -f file5
6533 genfile -l     13 -f file6
6534 genfile -l   1385 -f file7
6535 genfile -l     30 -f file8
6536 genfile -l     10 -f file9
6537 genfile -l 256000 -f file10
6538 tar cf archive file1 file2 file3 file4 file5 file6 file7 file8 file9 file10
6539 tar f archive --delete file10
6540 tar tf archive
6541 ) ) >"$at_stdout" 2>"$at_stder1"
6542     at_status=$?
6543     grep '^ *+' "$at_stder1" >&2
6544     grep -v '^ *+' "$at_stder1" >"$at_stderr"
6545 else
6546     ( :;
6547 mkdir posix
6548 (cd posix
6549 TEST_TAR_FORMAT=posix
6550 export TEST_TAR_FORMAT
6551 TAR_OPTIONS="-H posix"
6552 export TAR_OPTIONS
6553 rm -rf *
6554
6555 genfile -l      3 -f file1
6556 genfile -l      5 -f file2
6557 genfile -l      3 -f file3
6558 genfile -l      6 -f file4
6559 genfile -l     24 -f file5
6560 genfile -l     13 -f file6
6561 genfile -l   1385 -f file7
6562 genfile -l     30 -f file8
6563 genfile -l     10 -f file9
6564 genfile -l 256000 -f file10
6565 tar cf archive file1 file2 file3 file4 file5 file6 file7 file8 file9 file10
6566 tar f archive --delete file10
6567 tar tf archive
6568 ) ) >"$at_stdout" 2>"$at_stderr"
6569     at_status=$?
6570 fi
6571
6572 at_failed=false
6573 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
6574 echo >>"$at_stdout"; echo "file1
6575 file2
6576 file3
6577 file4
6578 file5
6579 file6
6580 file7
6581 file8
6582 file9
6583 " | $at_diff - "$at_stdout" || at_failed=:
6584 case $at_status in
6585    77) echo 77 > "$at_status_file"; exit 77;;
6586    0) ;;
6587    *) echo "$at_srcdir/delete04.at:26: exit code was $at_status, expected 0"
6588       at_failed=:;;
6589 esac
6590 if $at_failed; then
6591
6592
6593   echo 1 > "$at_status_file"
6594   exit 1
6595 fi
6596
6597 $at_traceon
6598 $at_traceoff
6599 echo "$at_srcdir/delete04.at:26:
6600 mkdir gnu
6601 (cd gnu
6602 TEST_TAR_FORMAT=gnu
6603 export TEST_TAR_FORMAT
6604 TAR_OPTIONS=\"-H gnu\"
6605 export TAR_OPTIONS
6606 rm -rf *
6607
6608 genfile -l      3 -f file1
6609 genfile -l      5 -f file2
6610 genfile -l      3 -f file3
6611 genfile -l      6 -f file4
6612 genfile -l     24 -f file5
6613 genfile -l     13 -f file6
6614 genfile -l   1385 -f file7
6615 genfile -l     30 -f file8
6616 genfile -l     10 -f file9
6617 genfile -l 256000 -f file10
6618 tar cf archive file1 file2 file3 file4 file5 file6 file7 file8 file9 file10
6619 tar f archive --delete file10
6620 tar tf archive
6621 )"
6622 echo delete04.at:26 >"$at_check_line_file"
6623
6624 at_trace_this=
6625 if test -n "$at_traceon"; then
6626     echo 'Not enabling shell tracing (command contains an embedded newline)'
6627 fi
6628
6629 if test -n "$at_trace_this"; then
6630     ( $at_traceon;
6631 mkdir gnu
6632 (cd gnu
6633 TEST_TAR_FORMAT=gnu
6634 export TEST_TAR_FORMAT
6635 TAR_OPTIONS="-H gnu"
6636 export TAR_OPTIONS
6637 rm -rf *
6638
6639 genfile -l      3 -f file1
6640 genfile -l      5 -f file2
6641 genfile -l      3 -f file3
6642 genfile -l      6 -f file4
6643 genfile -l     24 -f file5
6644 genfile -l     13 -f file6
6645 genfile -l   1385 -f file7
6646 genfile -l     30 -f file8
6647 genfile -l     10 -f file9
6648 genfile -l 256000 -f file10
6649 tar cf archive file1 file2 file3 file4 file5 file6 file7 file8 file9 file10
6650 tar f archive --delete file10
6651 tar tf archive
6652 ) ) >"$at_stdout" 2>"$at_stder1"
6653     at_status=$?
6654     grep '^ *+' "$at_stder1" >&2
6655     grep -v '^ *+' "$at_stder1" >"$at_stderr"
6656 else
6657     ( :;
6658 mkdir gnu
6659 (cd gnu
6660 TEST_TAR_FORMAT=gnu
6661 export TEST_TAR_FORMAT
6662 TAR_OPTIONS="-H gnu"
6663 export TAR_OPTIONS
6664 rm -rf *
6665
6666 genfile -l      3 -f file1
6667 genfile -l      5 -f file2
6668 genfile -l      3 -f file3
6669 genfile -l      6 -f file4
6670 genfile -l     24 -f file5
6671 genfile -l     13 -f file6
6672 genfile -l   1385 -f file7
6673 genfile -l     30 -f file8
6674 genfile -l     10 -f file9
6675 genfile -l 256000 -f file10
6676 tar cf archive file1 file2 file3 file4 file5 file6 file7 file8 file9 file10
6677 tar f archive --delete file10
6678 tar tf archive
6679 ) ) >"$at_stdout" 2>"$at_stderr"
6680     at_status=$?
6681 fi
6682
6683 at_failed=false
6684 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
6685 echo >>"$at_stdout"; echo "file1
6686 file2
6687 file3
6688 file4
6689 file5
6690 file6
6691 file7
6692 file8
6693 file9
6694 " | $at_diff - "$at_stdout" || at_failed=:
6695 case $at_status in
6696    77) echo 77 > "$at_status_file"; exit 77;;
6697    0) ;;
6698    *) echo "$at_srcdir/delete04.at:26: exit code was $at_status, expected 0"
6699       at_failed=:;;
6700 esac
6701 if $at_failed; then
6702
6703
6704   echo 1 > "$at_status_file"
6705   exit 1
6706 fi
6707
6708 $at_traceon
6709
6710
6711
6712       $at_traceoff
6713       $at_times_p && times >"$at_times_file"
6714     ) 5>&1 2>&1 | eval $at_tee_pipe
6715     at_status=`cat "$at_status_file"`
6716     ;;
6717
6718   17 ) # 17. delete05.at:27: deleting non-existing member
6719     at_setup_line='delete05.at:27'
6720     at_desc="deleting non-existing member"
6721     $at_quiet $ECHO_N " 17: deleting non-existing member                   $ECHO_C"
6722     at_xfail=no
6723       test -f $XFAILFILE && at_xfail=yes
6724     echo "#                             -*- compilation -*-" >> "$at_group_log"
6725     (
6726       echo "17. delete05.at:27: testing ..."
6727       $at_traceon
6728
6729
6730
6731
6732
6733   $at_traceoff
6734 echo "$at_srcdir/delete05.at:30:
6735 mkdir v7
6736 (cd v7
6737 TEST_TAR_FORMAT=v7
6738 export TEST_TAR_FORMAT
6739 TAR_OPTIONS=\"-H v7\"
6740 export TAR_OPTIONS
6741 rm -rf *
6742
6743 genfile -l 1024 -f en
6744 genfile -l 1024 -f to
6745
6746 tar cf archive en to
6747 # Make sure we don't use bogus blocking factor.
6748 # GNU tar up to and including 1.14.91 produced an empty archive this way:
6749 tar --file archive --blocking-factor=20 --delete tre
6750 tar tf archive
6751 )"
6752 echo delete05.at:30 >"$at_check_line_file"
6753
6754 at_trace_this=
6755 if test -n "$at_traceon"; then
6756     echo 'Not enabling shell tracing (command contains an embedded newline)'
6757 fi
6758
6759 if test -n "$at_trace_this"; then
6760     ( $at_traceon;
6761 mkdir v7
6762 (cd v7
6763 TEST_TAR_FORMAT=v7
6764 export TEST_TAR_FORMAT
6765 TAR_OPTIONS="-H v7"
6766 export TAR_OPTIONS
6767 rm -rf *
6768
6769 genfile -l 1024 -f en
6770 genfile -l 1024 -f to
6771
6772 tar cf archive en to
6773 # Make sure we don't use bogus blocking factor.
6774 # GNU tar up to and including 1.14.91 produced an empty archive this way:
6775 tar --file archive --blocking-factor=20 --delete tre
6776 tar tf archive
6777 ) ) >"$at_stdout" 2>"$at_stder1"
6778     at_status=$?
6779     grep '^ *+' "$at_stder1" >&2
6780     grep -v '^ *+' "$at_stder1" >"$at_stderr"
6781 else
6782     ( :;
6783 mkdir v7
6784 (cd v7
6785 TEST_TAR_FORMAT=v7
6786 export TEST_TAR_FORMAT
6787 TAR_OPTIONS="-H v7"
6788 export TAR_OPTIONS
6789 rm -rf *
6790
6791 genfile -l 1024 -f en
6792 genfile -l 1024 -f to
6793
6794 tar cf archive en to
6795 # Make sure we don't use bogus blocking factor.
6796 # GNU tar up to and including 1.14.91 produced an empty archive this way:
6797 tar --file archive --blocking-factor=20 --delete tre
6798 tar tf archive
6799 ) ) >"$at_stdout" 2>"$at_stderr"
6800     at_status=$?
6801 fi
6802
6803 at_failed=false
6804 echo >>"$at_stderr"; echo "tar: tre: Not found in archive
6805 tar: Exiting with failure status due to previous errors
6806 " | $at_diff - "$at_stderr" || at_failed=:
6807 echo >>"$at_stdout"; echo "en
6808 to
6809 " | $at_diff - "$at_stdout" || at_failed=:
6810 case $at_status in
6811    77) echo 77 > "$at_status_file"; exit 77;;
6812    0) ;;
6813    *) echo "$at_srcdir/delete05.at:30: exit code was $at_status, expected 0"
6814       at_failed=:;;
6815 esac
6816 if $at_failed; then
6817
6818
6819   echo 1 > "$at_status_file"
6820   exit 1
6821 fi
6822
6823 $at_traceon
6824 $at_traceoff
6825 echo "$at_srcdir/delete05.at:30:
6826 mkdir oldgnu
6827 (cd oldgnu
6828 TEST_TAR_FORMAT=oldgnu
6829 export TEST_TAR_FORMAT
6830 TAR_OPTIONS=\"-H oldgnu\"
6831 export TAR_OPTIONS
6832 rm -rf *
6833
6834 genfile -l 1024 -f en
6835 genfile -l 1024 -f to
6836
6837 tar cf archive en to
6838 # Make sure we don't use bogus blocking factor.
6839 # GNU tar up to and including 1.14.91 produced an empty archive this way:
6840 tar --file archive --blocking-factor=20 --delete tre
6841 tar tf archive
6842 )"
6843 echo delete05.at:30 >"$at_check_line_file"
6844
6845 at_trace_this=
6846 if test -n "$at_traceon"; then
6847     echo 'Not enabling shell tracing (command contains an embedded newline)'
6848 fi
6849
6850 if test -n "$at_trace_this"; then
6851     ( $at_traceon;
6852 mkdir oldgnu
6853 (cd oldgnu
6854 TEST_TAR_FORMAT=oldgnu
6855 export TEST_TAR_FORMAT
6856 TAR_OPTIONS="-H oldgnu"
6857 export TAR_OPTIONS
6858 rm -rf *
6859
6860 genfile -l 1024 -f en
6861 genfile -l 1024 -f to
6862
6863 tar cf archive en to
6864 # Make sure we don't use bogus blocking factor.
6865 # GNU tar up to and including 1.14.91 produced an empty archive this way:
6866 tar --file archive --blocking-factor=20 --delete tre
6867 tar tf archive
6868 ) ) >"$at_stdout" 2>"$at_stder1"
6869     at_status=$?
6870     grep '^ *+' "$at_stder1" >&2
6871     grep -v '^ *+' "$at_stder1" >"$at_stderr"
6872 else
6873     ( :;
6874 mkdir oldgnu
6875 (cd oldgnu
6876 TEST_TAR_FORMAT=oldgnu
6877 export TEST_TAR_FORMAT
6878 TAR_OPTIONS="-H oldgnu"
6879 export TAR_OPTIONS
6880 rm -rf *
6881
6882 genfile -l 1024 -f en
6883 genfile -l 1024 -f to
6884
6885 tar cf archive en to
6886 # Make sure we don't use bogus blocking factor.
6887 # GNU tar up to and including 1.14.91 produced an empty archive this way:
6888 tar --file archive --blocking-factor=20 --delete tre
6889 tar tf archive
6890 ) ) >"$at_stdout" 2>"$at_stderr"
6891     at_status=$?
6892 fi
6893
6894 at_failed=false
6895 echo >>"$at_stderr"; echo "tar: tre: Not found in archive
6896 tar: Exiting with failure status due to previous errors
6897 " | $at_diff - "$at_stderr" || at_failed=:
6898 echo >>"$at_stdout"; echo "en
6899 to
6900 " | $at_diff - "$at_stdout" || at_failed=:
6901 case $at_status in
6902    77) echo 77 > "$at_status_file"; exit 77;;
6903    0) ;;
6904    *) echo "$at_srcdir/delete05.at:30: exit code was $at_status, expected 0"
6905       at_failed=:;;
6906 esac
6907 if $at_failed; then
6908
6909
6910   echo 1 > "$at_status_file"
6911   exit 1
6912 fi
6913
6914 $at_traceon
6915 $at_traceoff
6916 echo "$at_srcdir/delete05.at:30:
6917 mkdir ustar
6918 (cd ustar
6919 TEST_TAR_FORMAT=ustar
6920 export TEST_TAR_FORMAT
6921 TAR_OPTIONS=\"-H ustar\"
6922 export TAR_OPTIONS
6923 rm -rf *
6924
6925 genfile -l 1024 -f en
6926 genfile -l 1024 -f to
6927
6928 tar cf archive en to
6929 # Make sure we don't use bogus blocking factor.
6930 # GNU tar up to and including 1.14.91 produced an empty archive this way:
6931 tar --file archive --blocking-factor=20 --delete tre
6932 tar tf archive
6933 )"
6934 echo delete05.at:30 >"$at_check_line_file"
6935
6936 at_trace_this=
6937 if test -n "$at_traceon"; then
6938     echo 'Not enabling shell tracing (command contains an embedded newline)'
6939 fi
6940
6941 if test -n "$at_trace_this"; then
6942     ( $at_traceon;
6943 mkdir ustar
6944 (cd ustar
6945 TEST_TAR_FORMAT=ustar
6946 export TEST_TAR_FORMAT
6947 TAR_OPTIONS="-H ustar"
6948 export TAR_OPTIONS
6949 rm -rf *
6950
6951 genfile -l 1024 -f en
6952 genfile -l 1024 -f to
6953
6954 tar cf archive en to
6955 # Make sure we don't use bogus blocking factor.
6956 # GNU tar up to and including 1.14.91 produced an empty archive this way:
6957 tar --file archive --blocking-factor=20 --delete tre
6958 tar tf archive
6959 ) ) >"$at_stdout" 2>"$at_stder1"
6960     at_status=$?
6961     grep '^ *+' "$at_stder1" >&2
6962     grep -v '^ *+' "$at_stder1" >"$at_stderr"
6963 else
6964     ( :;
6965 mkdir ustar
6966 (cd ustar
6967 TEST_TAR_FORMAT=ustar
6968 export TEST_TAR_FORMAT
6969 TAR_OPTIONS="-H ustar"
6970 export TAR_OPTIONS
6971 rm -rf *
6972
6973 genfile -l 1024 -f en
6974 genfile -l 1024 -f to
6975
6976 tar cf archive en to
6977 # Make sure we don't use bogus blocking factor.
6978 # GNU tar up to and including 1.14.91 produced an empty archive this way:
6979 tar --file archive --blocking-factor=20 --delete tre
6980 tar tf archive
6981 ) ) >"$at_stdout" 2>"$at_stderr"
6982     at_status=$?
6983 fi
6984
6985 at_failed=false
6986 echo >>"$at_stderr"; echo "tar: tre: Not found in archive
6987 tar: Exiting with failure status due to previous errors
6988 " | $at_diff - "$at_stderr" || at_failed=:
6989 echo >>"$at_stdout"; echo "en
6990 to
6991 " | $at_diff - "$at_stdout" || at_failed=:
6992 case $at_status in
6993    77) echo 77 > "$at_status_file"; exit 77;;
6994    0) ;;
6995    *) echo "$at_srcdir/delete05.at:30: exit code was $at_status, expected 0"
6996       at_failed=:;;
6997 esac
6998 if $at_failed; then
6999
7000
7001   echo 1 > "$at_status_file"
7002   exit 1
7003 fi
7004
7005 $at_traceon
7006 $at_traceoff
7007 echo "$at_srcdir/delete05.at:30:
7008 mkdir posix
7009 (cd posix
7010 TEST_TAR_FORMAT=posix
7011 export TEST_TAR_FORMAT
7012 TAR_OPTIONS=\"-H posix\"
7013 export TAR_OPTIONS
7014 rm -rf *
7015
7016 genfile -l 1024 -f en
7017 genfile -l 1024 -f to
7018
7019 tar cf archive en to
7020 # Make sure we don't use bogus blocking factor.
7021 # GNU tar up to and including 1.14.91 produced an empty archive this way:
7022 tar --file archive --blocking-factor=20 --delete tre
7023 tar tf archive
7024 )"
7025 echo delete05.at:30 >"$at_check_line_file"
7026
7027 at_trace_this=
7028 if test -n "$at_traceon"; then
7029     echo 'Not enabling shell tracing (command contains an embedded newline)'
7030 fi
7031
7032 if test -n "$at_trace_this"; then
7033     ( $at_traceon;
7034 mkdir posix
7035 (cd posix
7036 TEST_TAR_FORMAT=posix
7037 export TEST_TAR_FORMAT
7038 TAR_OPTIONS="-H posix"
7039 export TAR_OPTIONS
7040 rm -rf *
7041
7042 genfile -l 1024 -f en
7043 genfile -l 1024 -f to
7044
7045 tar cf archive en to
7046 # Make sure we don't use bogus blocking factor.
7047 # GNU tar up to and including 1.14.91 produced an empty archive this way:
7048 tar --file archive --blocking-factor=20 --delete tre
7049 tar tf archive
7050 ) ) >"$at_stdout" 2>"$at_stder1"
7051     at_status=$?
7052     grep '^ *+' "$at_stder1" >&2
7053     grep -v '^ *+' "$at_stder1" >"$at_stderr"
7054 else
7055     ( :;
7056 mkdir posix
7057 (cd posix
7058 TEST_TAR_FORMAT=posix
7059 export TEST_TAR_FORMAT
7060 TAR_OPTIONS="-H posix"
7061 export TAR_OPTIONS
7062 rm -rf *
7063
7064 genfile -l 1024 -f en
7065 genfile -l 1024 -f to
7066
7067 tar cf archive en to
7068 # Make sure we don't use bogus blocking factor.
7069 # GNU tar up to and including 1.14.91 produced an empty archive this way:
7070 tar --file archive --blocking-factor=20 --delete tre
7071 tar tf archive
7072 ) ) >"$at_stdout" 2>"$at_stderr"
7073     at_status=$?
7074 fi
7075
7076 at_failed=false
7077 echo >>"$at_stderr"; echo "tar: tre: Not found in archive
7078 tar: Exiting with failure status due to previous errors
7079 " | $at_diff - "$at_stderr" || at_failed=:
7080 echo >>"$at_stdout"; echo "en
7081 to
7082 " | $at_diff - "$at_stdout" || at_failed=:
7083 case $at_status in
7084    77) echo 77 > "$at_status_file"; exit 77;;
7085    0) ;;
7086    *) echo "$at_srcdir/delete05.at:30: exit code was $at_status, expected 0"
7087       at_failed=:;;
7088 esac
7089 if $at_failed; then
7090
7091
7092   echo 1 > "$at_status_file"
7093   exit 1
7094 fi
7095
7096 $at_traceon
7097 $at_traceoff
7098 echo "$at_srcdir/delete05.at:30:
7099 mkdir gnu
7100 (cd gnu
7101 TEST_TAR_FORMAT=gnu
7102 export TEST_TAR_FORMAT
7103 TAR_OPTIONS=\"-H gnu\"
7104 export TAR_OPTIONS
7105 rm -rf *
7106
7107 genfile -l 1024 -f en
7108 genfile -l 1024 -f to
7109
7110 tar cf archive en to
7111 # Make sure we don't use bogus blocking factor.
7112 # GNU tar up to and including 1.14.91 produced an empty archive this way:
7113 tar --file archive --blocking-factor=20 --delete tre
7114 tar tf archive
7115 )"
7116 echo delete05.at:30 >"$at_check_line_file"
7117
7118 at_trace_this=
7119 if test -n "$at_traceon"; then
7120     echo 'Not enabling shell tracing (command contains an embedded newline)'
7121 fi
7122
7123 if test -n "$at_trace_this"; then
7124     ( $at_traceon;
7125 mkdir gnu
7126 (cd gnu
7127 TEST_TAR_FORMAT=gnu
7128 export TEST_TAR_FORMAT
7129 TAR_OPTIONS="-H gnu"
7130 export TAR_OPTIONS
7131 rm -rf *
7132
7133 genfile -l 1024 -f en
7134 genfile -l 1024 -f to
7135
7136 tar cf archive en to
7137 # Make sure we don't use bogus blocking factor.
7138 # GNU tar up to and including 1.14.91 produced an empty archive this way:
7139 tar --file archive --blocking-factor=20 --delete tre
7140 tar tf archive
7141 ) ) >"$at_stdout" 2>"$at_stder1"
7142     at_status=$?
7143     grep '^ *+' "$at_stder1" >&2
7144     grep -v '^ *+' "$at_stder1" >"$at_stderr"
7145 else
7146     ( :;
7147 mkdir gnu
7148 (cd gnu
7149 TEST_TAR_FORMAT=gnu
7150 export TEST_TAR_FORMAT
7151 TAR_OPTIONS="-H gnu"
7152 export TAR_OPTIONS
7153 rm -rf *
7154
7155 genfile -l 1024 -f en
7156 genfile -l 1024 -f to
7157
7158 tar cf archive en to
7159 # Make sure we don't use bogus blocking factor.
7160 # GNU tar up to and including 1.14.91 produced an empty archive this way:
7161 tar --file archive --blocking-factor=20 --delete tre
7162 tar tf archive
7163 ) ) >"$at_stdout" 2>"$at_stderr"
7164     at_status=$?
7165 fi
7166
7167 at_failed=false
7168 echo >>"$at_stderr"; echo "tar: tre: Not found in archive
7169 tar: Exiting with failure status due to previous errors
7170 " | $at_diff - "$at_stderr" || at_failed=:
7171 echo >>"$at_stdout"; echo "en
7172 to
7173 " | $at_diff - "$at_stdout" || at_failed=:
7174 case $at_status in
7175    77) echo 77 > "$at_status_file"; exit 77;;
7176    0) ;;
7177    *) echo "$at_srcdir/delete05.at:30: exit code was $at_status, expected 0"
7178       at_failed=:;;
7179 esac
7180 if $at_failed; then
7181
7182
7183   echo 1 > "$at_status_file"
7184   exit 1
7185 fi
7186
7187 $at_traceon
7188
7189
7190
7191       $at_traceoff
7192       $at_times_p && times >"$at_times_file"
7193     ) 5>&1 2>&1 | eval $at_tee_pipe
7194     at_status=`cat "$at_status_file"`
7195     ;;
7196
7197   18 ) # 18. extrac01.at:23: extract over an existing directory
7198     at_setup_line='extrac01.at:23'
7199     at_desc="extract over an existing directory"
7200     $at_quiet $ECHO_N " 18: extract over an existing directory             $ECHO_C"
7201     at_xfail=no
7202       test -f $XFAILFILE && at_xfail=yes
7203     echo "#                             -*- compilation -*-" >> "$at_group_log"
7204     (
7205       echo "18. extrac01.at:23: testing ..."
7206       $at_traceon
7207
7208
7209
7210
7211
7212   $at_traceoff
7213 echo "$at_srcdir/extrac01.at:26:
7214 mkdir v7
7215 (cd v7
7216 TEST_TAR_FORMAT=v7
7217 export TEST_TAR_FORMAT
7218 TAR_OPTIONS=\"-H v7\"
7219 export TAR_OPTIONS
7220 rm -rf *
7221
7222 mkdir directory
7223 touch directory/file
7224 tar cf archive directory || exit 1
7225 tar xf archive || exit 1
7226 )"
7227 echo extrac01.at:26 >"$at_check_line_file"
7228
7229 at_trace_this=
7230 if test -n "$at_traceon"; then
7231     echo 'Not enabling shell tracing (command contains an embedded newline)'
7232 fi
7233
7234 if test -n "$at_trace_this"; then
7235     ( $at_traceon;
7236 mkdir v7
7237 (cd v7
7238 TEST_TAR_FORMAT=v7
7239 export TEST_TAR_FORMAT
7240 TAR_OPTIONS="-H v7"
7241 export TAR_OPTIONS
7242 rm -rf *
7243
7244 mkdir directory
7245 touch directory/file
7246 tar cf archive directory || exit 1
7247 tar xf archive || exit 1
7248 ) ) >"$at_stdout" 2>"$at_stder1"
7249     at_status=$?
7250     grep '^ *+' "$at_stder1" >&2
7251     grep -v '^ *+' "$at_stder1" >"$at_stderr"
7252 else
7253     ( :;
7254 mkdir v7
7255 (cd v7
7256 TEST_TAR_FORMAT=v7
7257 export TEST_TAR_FORMAT
7258 TAR_OPTIONS="-H v7"
7259 export TAR_OPTIONS
7260 rm -rf *
7261
7262 mkdir directory
7263 touch directory/file
7264 tar cf archive directory || exit 1
7265 tar xf archive || exit 1
7266 ) ) >"$at_stdout" 2>"$at_stderr"
7267     at_status=$?
7268 fi
7269
7270 at_failed=false
7271 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
7272 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
7273 case $at_status in
7274    77) echo 77 > "$at_status_file"; exit 77;;
7275    0) ;;
7276    *) echo "$at_srcdir/extrac01.at:26: exit code was $at_status, expected 0"
7277       at_failed=:;;
7278 esac
7279 if $at_failed; then
7280
7281
7282   echo 1 > "$at_status_file"
7283   exit 1
7284 fi
7285
7286 $at_traceon
7287 $at_traceoff
7288 echo "$at_srcdir/extrac01.at:26:
7289 mkdir oldgnu
7290 (cd oldgnu
7291 TEST_TAR_FORMAT=oldgnu
7292 export TEST_TAR_FORMAT
7293 TAR_OPTIONS=\"-H oldgnu\"
7294 export TAR_OPTIONS
7295 rm -rf *
7296
7297 mkdir directory
7298 touch directory/file
7299 tar cf archive directory || exit 1
7300 tar xf archive || exit 1
7301 )"
7302 echo extrac01.at:26 >"$at_check_line_file"
7303
7304 at_trace_this=
7305 if test -n "$at_traceon"; then
7306     echo 'Not enabling shell tracing (command contains an embedded newline)'
7307 fi
7308
7309 if test -n "$at_trace_this"; then
7310     ( $at_traceon;
7311 mkdir oldgnu
7312 (cd oldgnu
7313 TEST_TAR_FORMAT=oldgnu
7314 export TEST_TAR_FORMAT
7315 TAR_OPTIONS="-H oldgnu"
7316 export TAR_OPTIONS
7317 rm -rf *
7318
7319 mkdir directory
7320 touch directory/file
7321 tar cf archive directory || exit 1
7322 tar xf archive || exit 1
7323 ) ) >"$at_stdout" 2>"$at_stder1"
7324     at_status=$?
7325     grep '^ *+' "$at_stder1" >&2
7326     grep -v '^ *+' "$at_stder1" >"$at_stderr"
7327 else
7328     ( :;
7329 mkdir oldgnu
7330 (cd oldgnu
7331 TEST_TAR_FORMAT=oldgnu
7332 export TEST_TAR_FORMAT
7333 TAR_OPTIONS="-H oldgnu"
7334 export TAR_OPTIONS
7335 rm -rf *
7336
7337 mkdir directory
7338 touch directory/file
7339 tar cf archive directory || exit 1
7340 tar xf archive || exit 1
7341 ) ) >"$at_stdout" 2>"$at_stderr"
7342     at_status=$?
7343 fi
7344
7345 at_failed=false
7346 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
7347 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
7348 case $at_status in
7349    77) echo 77 > "$at_status_file"; exit 77;;
7350    0) ;;
7351    *) echo "$at_srcdir/extrac01.at:26: exit code was $at_status, expected 0"
7352       at_failed=:;;
7353 esac
7354 if $at_failed; then
7355
7356
7357   echo 1 > "$at_status_file"
7358   exit 1
7359 fi
7360
7361 $at_traceon
7362 $at_traceoff
7363 echo "$at_srcdir/extrac01.at:26:
7364 mkdir ustar
7365 (cd ustar
7366 TEST_TAR_FORMAT=ustar
7367 export TEST_TAR_FORMAT
7368 TAR_OPTIONS=\"-H ustar\"
7369 export TAR_OPTIONS
7370 rm -rf *
7371
7372 mkdir directory
7373 touch directory/file
7374 tar cf archive directory || exit 1
7375 tar xf archive || exit 1
7376 )"
7377 echo extrac01.at:26 >"$at_check_line_file"
7378
7379 at_trace_this=
7380 if test -n "$at_traceon"; then
7381     echo 'Not enabling shell tracing (command contains an embedded newline)'
7382 fi
7383
7384 if test -n "$at_trace_this"; then
7385     ( $at_traceon;
7386 mkdir ustar
7387 (cd ustar
7388 TEST_TAR_FORMAT=ustar
7389 export TEST_TAR_FORMAT
7390 TAR_OPTIONS="-H ustar"
7391 export TAR_OPTIONS
7392 rm -rf *
7393
7394 mkdir directory
7395 touch directory/file
7396 tar cf archive directory || exit 1
7397 tar xf archive || exit 1
7398 ) ) >"$at_stdout" 2>"$at_stder1"
7399     at_status=$?
7400     grep '^ *+' "$at_stder1" >&2
7401     grep -v '^ *+' "$at_stder1" >"$at_stderr"
7402 else
7403     ( :;
7404 mkdir ustar
7405 (cd ustar
7406 TEST_TAR_FORMAT=ustar
7407 export TEST_TAR_FORMAT
7408 TAR_OPTIONS="-H ustar"
7409 export TAR_OPTIONS
7410 rm -rf *
7411
7412 mkdir directory
7413 touch directory/file
7414 tar cf archive directory || exit 1
7415 tar xf archive || exit 1
7416 ) ) >"$at_stdout" 2>"$at_stderr"
7417     at_status=$?
7418 fi
7419
7420 at_failed=false
7421 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
7422 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
7423 case $at_status in
7424    77) echo 77 > "$at_status_file"; exit 77;;
7425    0) ;;
7426    *) echo "$at_srcdir/extrac01.at:26: exit code was $at_status, expected 0"
7427       at_failed=:;;
7428 esac
7429 if $at_failed; then
7430
7431
7432   echo 1 > "$at_status_file"
7433   exit 1
7434 fi
7435
7436 $at_traceon
7437 $at_traceoff
7438 echo "$at_srcdir/extrac01.at:26:
7439 mkdir posix
7440 (cd posix
7441 TEST_TAR_FORMAT=posix
7442 export TEST_TAR_FORMAT
7443 TAR_OPTIONS=\"-H posix\"
7444 export TAR_OPTIONS
7445 rm -rf *
7446
7447 mkdir directory
7448 touch directory/file
7449 tar cf archive directory || exit 1
7450 tar xf archive || exit 1
7451 )"
7452 echo extrac01.at:26 >"$at_check_line_file"
7453
7454 at_trace_this=
7455 if test -n "$at_traceon"; then
7456     echo 'Not enabling shell tracing (command contains an embedded newline)'
7457 fi
7458
7459 if test -n "$at_trace_this"; then
7460     ( $at_traceon;
7461 mkdir posix
7462 (cd posix
7463 TEST_TAR_FORMAT=posix
7464 export TEST_TAR_FORMAT
7465 TAR_OPTIONS="-H posix"
7466 export TAR_OPTIONS
7467 rm -rf *
7468
7469 mkdir directory
7470 touch directory/file
7471 tar cf archive directory || exit 1
7472 tar xf archive || exit 1
7473 ) ) >"$at_stdout" 2>"$at_stder1"
7474     at_status=$?
7475     grep '^ *+' "$at_stder1" >&2
7476     grep -v '^ *+' "$at_stder1" >"$at_stderr"
7477 else
7478     ( :;
7479 mkdir posix
7480 (cd posix
7481 TEST_TAR_FORMAT=posix
7482 export TEST_TAR_FORMAT
7483 TAR_OPTIONS="-H posix"
7484 export TAR_OPTIONS
7485 rm -rf *
7486
7487 mkdir directory
7488 touch directory/file
7489 tar cf archive directory || exit 1
7490 tar xf archive || exit 1
7491 ) ) >"$at_stdout" 2>"$at_stderr"
7492     at_status=$?
7493 fi
7494
7495 at_failed=false
7496 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
7497 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
7498 case $at_status in
7499    77) echo 77 > "$at_status_file"; exit 77;;
7500    0) ;;
7501    *) echo "$at_srcdir/extrac01.at:26: exit code was $at_status, expected 0"
7502       at_failed=:;;
7503 esac
7504 if $at_failed; then
7505
7506
7507   echo 1 > "$at_status_file"
7508   exit 1
7509 fi
7510
7511 $at_traceon
7512 $at_traceoff
7513 echo "$at_srcdir/extrac01.at:26:
7514 mkdir gnu
7515 (cd gnu
7516 TEST_TAR_FORMAT=gnu
7517 export TEST_TAR_FORMAT
7518 TAR_OPTIONS=\"-H gnu\"
7519 export TAR_OPTIONS
7520 rm -rf *
7521
7522 mkdir directory
7523 touch directory/file
7524 tar cf archive directory || exit 1
7525 tar xf archive || exit 1
7526 )"
7527 echo extrac01.at:26 >"$at_check_line_file"
7528
7529 at_trace_this=
7530 if test -n "$at_traceon"; then
7531     echo 'Not enabling shell tracing (command contains an embedded newline)'
7532 fi
7533
7534 if test -n "$at_trace_this"; then
7535     ( $at_traceon;
7536 mkdir gnu
7537 (cd gnu
7538 TEST_TAR_FORMAT=gnu
7539 export TEST_TAR_FORMAT
7540 TAR_OPTIONS="-H gnu"
7541 export TAR_OPTIONS
7542 rm -rf *
7543
7544 mkdir directory
7545 touch directory/file
7546 tar cf archive directory || exit 1
7547 tar xf archive || exit 1
7548 ) ) >"$at_stdout" 2>"$at_stder1"
7549     at_status=$?
7550     grep '^ *+' "$at_stder1" >&2
7551     grep -v '^ *+' "$at_stder1" >"$at_stderr"
7552 else
7553     ( :;
7554 mkdir gnu
7555 (cd gnu
7556 TEST_TAR_FORMAT=gnu
7557 export TEST_TAR_FORMAT
7558 TAR_OPTIONS="-H gnu"
7559 export TAR_OPTIONS
7560 rm -rf *
7561
7562 mkdir directory
7563 touch directory/file
7564 tar cf archive directory || exit 1
7565 tar xf archive || exit 1
7566 ) ) >"$at_stdout" 2>"$at_stderr"
7567     at_status=$?
7568 fi
7569
7570 at_failed=false
7571 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
7572 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
7573 case $at_status in
7574    77) echo 77 > "$at_status_file"; exit 77;;
7575    0) ;;
7576    *) echo "$at_srcdir/extrac01.at:26: exit code was $at_status, expected 0"
7577       at_failed=:;;
7578 esac
7579 if $at_failed; then
7580
7581
7582   echo 1 > "$at_status_file"
7583   exit 1
7584 fi
7585
7586 $at_traceon
7587
7588
7589
7590       $at_traceoff
7591       $at_times_p && times >"$at_times_file"
7592     ) 5>&1 2>&1 | eval $at_tee_pipe
7593     at_status=`cat "$at_status_file"`
7594     ;;
7595
7596   19 ) # 19. extrac02.at:23: extracting symlinks over an existing file
7597     at_setup_line='extrac02.at:23'
7598     at_desc="extracting symlinks over an existing file"
7599     $at_quiet $ECHO_N " 19: extracting symlinks over an existing file      $ECHO_C"
7600     at_xfail=no
7601       test -f $XFAILFILE && at_xfail=yes
7602     echo "#                             -*- compilation -*-" >> "$at_group_log"
7603     (
7604       echo "19. extrac02.at:23: testing ..."
7605       $at_traceon
7606
7607
7608
7609 # FIXME: Skip if symlinks are not supported on the system
7610
7611
7612
7613   $at_traceoff
7614 echo "$at_srcdir/extrac02.at:28:
7615 mkdir v7
7616 (cd v7
7617 TEST_TAR_FORMAT=v7
7618 export TEST_TAR_FORMAT
7619 TAR_OPTIONS=\"-H v7\"
7620 export TAR_OPTIONS
7621 rm -rf *
7622
7623 touch file
7624 ln -s file link 2> /dev/null || ln file link
7625 tar cf archive link
7626 rm link
7627 touch link
7628 tar xf archive
7629 )"
7630 echo extrac02.at:28 >"$at_check_line_file"
7631
7632 at_trace_this=
7633 if test -n "$at_traceon"; then
7634     echo 'Not enabling shell tracing (command contains an embedded newline)'
7635 fi
7636
7637 if test -n "$at_trace_this"; then
7638     ( $at_traceon;
7639 mkdir v7
7640 (cd v7
7641 TEST_TAR_FORMAT=v7
7642 export TEST_TAR_FORMAT
7643 TAR_OPTIONS="-H v7"
7644 export TAR_OPTIONS
7645 rm -rf *
7646
7647 touch file
7648 ln -s file link 2> /dev/null || ln file link
7649 tar cf archive link
7650 rm link
7651 touch link
7652 tar xf archive
7653 ) ) >"$at_stdout" 2>"$at_stder1"
7654     at_status=$?
7655     grep '^ *+' "$at_stder1" >&2
7656     grep -v '^ *+' "$at_stder1" >"$at_stderr"
7657 else
7658     ( :;
7659 mkdir v7
7660 (cd v7
7661 TEST_TAR_FORMAT=v7
7662 export TEST_TAR_FORMAT
7663 TAR_OPTIONS="-H v7"
7664 export TAR_OPTIONS
7665 rm -rf *
7666
7667 touch file
7668 ln -s file link 2> /dev/null || ln file link
7669 tar cf archive link
7670 rm link
7671 touch link
7672 tar xf archive
7673 ) ) >"$at_stdout" 2>"$at_stderr"
7674     at_status=$?
7675 fi
7676
7677 at_failed=false
7678 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
7679 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
7680 case $at_status in
7681    77) echo 77 > "$at_status_file"; exit 77;;
7682    0) ;;
7683    *) echo "$at_srcdir/extrac02.at:28: exit code was $at_status, expected 0"
7684       at_failed=:;;
7685 esac
7686 if $at_failed; then
7687
7688
7689   echo 1 > "$at_status_file"
7690   exit 1
7691 fi
7692
7693 $at_traceon
7694 $at_traceoff
7695 echo "$at_srcdir/extrac02.at:28:
7696 mkdir oldgnu
7697 (cd oldgnu
7698 TEST_TAR_FORMAT=oldgnu
7699 export TEST_TAR_FORMAT
7700 TAR_OPTIONS=\"-H oldgnu\"
7701 export TAR_OPTIONS
7702 rm -rf *
7703
7704 touch file
7705 ln -s file link 2> /dev/null || ln file link
7706 tar cf archive link
7707 rm link
7708 touch link
7709 tar xf archive
7710 )"
7711 echo extrac02.at:28 >"$at_check_line_file"
7712
7713 at_trace_this=
7714 if test -n "$at_traceon"; then
7715     echo 'Not enabling shell tracing (command contains an embedded newline)'
7716 fi
7717
7718 if test -n "$at_trace_this"; then
7719     ( $at_traceon;
7720 mkdir oldgnu
7721 (cd oldgnu
7722 TEST_TAR_FORMAT=oldgnu
7723 export TEST_TAR_FORMAT
7724 TAR_OPTIONS="-H oldgnu"
7725 export TAR_OPTIONS
7726 rm -rf *
7727
7728 touch file
7729 ln -s file link 2> /dev/null || ln file link
7730 tar cf archive link
7731 rm link
7732 touch link
7733 tar xf archive
7734 ) ) >"$at_stdout" 2>"$at_stder1"
7735     at_status=$?
7736     grep '^ *+' "$at_stder1" >&2
7737     grep -v '^ *+' "$at_stder1" >"$at_stderr"
7738 else
7739     ( :;
7740 mkdir oldgnu
7741 (cd oldgnu
7742 TEST_TAR_FORMAT=oldgnu
7743 export TEST_TAR_FORMAT
7744 TAR_OPTIONS="-H oldgnu"
7745 export TAR_OPTIONS
7746 rm -rf *
7747
7748 touch file
7749 ln -s file link 2> /dev/null || ln file link
7750 tar cf archive link
7751 rm link
7752 touch link
7753 tar xf archive
7754 ) ) >"$at_stdout" 2>"$at_stderr"
7755     at_status=$?
7756 fi
7757
7758 at_failed=false
7759 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
7760 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
7761 case $at_status in
7762    77) echo 77 > "$at_status_file"; exit 77;;
7763    0) ;;
7764    *) echo "$at_srcdir/extrac02.at:28: exit code was $at_status, expected 0"
7765       at_failed=:;;
7766 esac
7767 if $at_failed; then
7768
7769
7770   echo 1 > "$at_status_file"
7771   exit 1
7772 fi
7773
7774 $at_traceon
7775 $at_traceoff
7776 echo "$at_srcdir/extrac02.at:28:
7777 mkdir ustar
7778 (cd ustar
7779 TEST_TAR_FORMAT=ustar
7780 export TEST_TAR_FORMAT
7781 TAR_OPTIONS=\"-H ustar\"
7782 export TAR_OPTIONS
7783 rm -rf *
7784
7785 touch file
7786 ln -s file link 2> /dev/null || ln file link
7787 tar cf archive link
7788 rm link
7789 touch link
7790 tar xf archive
7791 )"
7792 echo extrac02.at:28 >"$at_check_line_file"
7793
7794 at_trace_this=
7795 if test -n "$at_traceon"; then
7796     echo 'Not enabling shell tracing (command contains an embedded newline)'
7797 fi
7798
7799 if test -n "$at_trace_this"; then
7800     ( $at_traceon;
7801 mkdir ustar
7802 (cd ustar
7803 TEST_TAR_FORMAT=ustar
7804 export TEST_TAR_FORMAT
7805 TAR_OPTIONS="-H ustar"
7806 export TAR_OPTIONS
7807 rm -rf *
7808
7809 touch file
7810 ln -s file link 2> /dev/null || ln file link
7811 tar cf archive link
7812 rm link
7813 touch link
7814 tar xf archive
7815 ) ) >"$at_stdout" 2>"$at_stder1"
7816     at_status=$?
7817     grep '^ *+' "$at_stder1" >&2
7818     grep -v '^ *+' "$at_stder1" >"$at_stderr"
7819 else
7820     ( :;
7821 mkdir ustar
7822 (cd ustar
7823 TEST_TAR_FORMAT=ustar
7824 export TEST_TAR_FORMAT
7825 TAR_OPTIONS="-H ustar"
7826 export TAR_OPTIONS
7827 rm -rf *
7828
7829 touch file
7830 ln -s file link 2> /dev/null || ln file link
7831 tar cf archive link
7832 rm link
7833 touch link
7834 tar xf archive
7835 ) ) >"$at_stdout" 2>"$at_stderr"
7836     at_status=$?
7837 fi
7838
7839 at_failed=false
7840 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
7841 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
7842 case $at_status in
7843    77) echo 77 > "$at_status_file"; exit 77;;
7844    0) ;;
7845    *) echo "$at_srcdir/extrac02.at:28: exit code was $at_status, expected 0"
7846       at_failed=:;;
7847 esac
7848 if $at_failed; then
7849
7850
7851   echo 1 > "$at_status_file"
7852   exit 1
7853 fi
7854
7855 $at_traceon
7856 $at_traceoff
7857 echo "$at_srcdir/extrac02.at:28:
7858 mkdir posix
7859 (cd posix
7860 TEST_TAR_FORMAT=posix
7861 export TEST_TAR_FORMAT
7862 TAR_OPTIONS=\"-H posix\"
7863 export TAR_OPTIONS
7864 rm -rf *
7865
7866 touch file
7867 ln -s file link 2> /dev/null || ln file link
7868 tar cf archive link
7869 rm link
7870 touch link
7871 tar xf archive
7872 )"
7873 echo extrac02.at:28 >"$at_check_line_file"
7874
7875 at_trace_this=
7876 if test -n "$at_traceon"; then
7877     echo 'Not enabling shell tracing (command contains an embedded newline)'
7878 fi
7879
7880 if test -n "$at_trace_this"; then
7881     ( $at_traceon;
7882 mkdir posix
7883 (cd posix
7884 TEST_TAR_FORMAT=posix
7885 export TEST_TAR_FORMAT
7886 TAR_OPTIONS="-H posix"
7887 export TAR_OPTIONS
7888 rm -rf *
7889
7890 touch file
7891 ln -s file link 2> /dev/null || ln file link
7892 tar cf archive link
7893 rm link
7894 touch link
7895 tar xf archive
7896 ) ) >"$at_stdout" 2>"$at_stder1"
7897     at_status=$?
7898     grep '^ *+' "$at_stder1" >&2
7899     grep -v '^ *+' "$at_stder1" >"$at_stderr"
7900 else
7901     ( :;
7902 mkdir posix
7903 (cd posix
7904 TEST_TAR_FORMAT=posix
7905 export TEST_TAR_FORMAT
7906 TAR_OPTIONS="-H posix"
7907 export TAR_OPTIONS
7908 rm -rf *
7909
7910 touch file
7911 ln -s file link 2> /dev/null || ln file link
7912 tar cf archive link
7913 rm link
7914 touch link
7915 tar xf archive
7916 ) ) >"$at_stdout" 2>"$at_stderr"
7917     at_status=$?
7918 fi
7919
7920 at_failed=false
7921 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
7922 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
7923 case $at_status in
7924    77) echo 77 > "$at_status_file"; exit 77;;
7925    0) ;;
7926    *) echo "$at_srcdir/extrac02.at:28: exit code was $at_status, expected 0"
7927       at_failed=:;;
7928 esac
7929 if $at_failed; then
7930
7931
7932   echo 1 > "$at_status_file"
7933   exit 1
7934 fi
7935
7936 $at_traceon
7937 $at_traceoff
7938 echo "$at_srcdir/extrac02.at:28:
7939 mkdir gnu
7940 (cd gnu
7941 TEST_TAR_FORMAT=gnu
7942 export TEST_TAR_FORMAT
7943 TAR_OPTIONS=\"-H gnu\"
7944 export TAR_OPTIONS
7945 rm -rf *
7946
7947 touch file
7948 ln -s file link 2> /dev/null || ln file link
7949 tar cf archive link
7950 rm link
7951 touch link
7952 tar xf archive
7953 )"
7954 echo extrac02.at:28 >"$at_check_line_file"
7955
7956 at_trace_this=
7957 if test -n "$at_traceon"; then
7958     echo 'Not enabling shell tracing (command contains an embedded newline)'
7959 fi
7960
7961 if test -n "$at_trace_this"; then
7962     ( $at_traceon;
7963 mkdir gnu
7964 (cd gnu
7965 TEST_TAR_FORMAT=gnu
7966 export TEST_TAR_FORMAT
7967 TAR_OPTIONS="-H gnu"
7968 export TAR_OPTIONS
7969 rm -rf *
7970
7971 touch file
7972 ln -s file link 2> /dev/null || ln file link
7973 tar cf archive link
7974 rm link
7975 touch link
7976 tar xf archive
7977 ) ) >"$at_stdout" 2>"$at_stder1"
7978     at_status=$?
7979     grep '^ *+' "$at_stder1" >&2
7980     grep -v '^ *+' "$at_stder1" >"$at_stderr"
7981 else
7982     ( :;
7983 mkdir gnu
7984 (cd gnu
7985 TEST_TAR_FORMAT=gnu
7986 export TEST_TAR_FORMAT
7987 TAR_OPTIONS="-H gnu"
7988 export TAR_OPTIONS
7989 rm -rf *
7990
7991 touch file
7992 ln -s file link 2> /dev/null || ln file link
7993 tar cf archive link
7994 rm link
7995 touch link
7996 tar xf archive
7997 ) ) >"$at_stdout" 2>"$at_stderr"
7998     at_status=$?
7999 fi
8000
8001 at_failed=false
8002 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
8003 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
8004 case $at_status in
8005    77) echo 77 > "$at_status_file"; exit 77;;
8006    0) ;;
8007    *) echo "$at_srcdir/extrac02.at:28: exit code was $at_status, expected 0"
8008       at_failed=:;;
8009 esac
8010 if $at_failed; then
8011
8012
8013   echo 1 > "$at_status_file"
8014   exit 1
8015 fi
8016
8017 $at_traceon
8018
8019
8020
8021       $at_traceoff
8022       $at_times_p && times >"$at_times_file"
8023     ) 5>&1 2>&1 | eval $at_tee_pipe
8024     at_status=`cat "$at_status_file"`
8025     ;;
8026
8027   20 ) # 20. extrac03.at:23: extraction loops
8028     at_setup_line='extrac03.at:23'
8029     at_desc="extraction loops"
8030     $at_quiet $ECHO_N " 20: extraction loops                               $ECHO_C"
8031     at_xfail=no
8032       test -f $XFAILFILE && at_xfail=yes
8033     echo "#                             -*- compilation -*-" >> "$at_group_log"
8034     (
8035       echo "20. extrac03.at:23: testing ..."
8036       $at_traceon
8037
8038
8039
8040
8041
8042   $at_traceoff
8043 echo "$at_srcdir/extrac03.at:26:
8044 mkdir v7
8045 (cd v7
8046 TEST_TAR_FORMAT=v7
8047 export TEST_TAR_FORMAT
8048 TAR_OPTIONS=\"-H v7\"
8049 export TAR_OPTIONS
8050 rm -rf *
8051
8052 mkdir directory
8053 tar -cPvf archive directory/../directory
8054 echo separator
8055 tar -xPvf archive)"
8056 echo extrac03.at:26 >"$at_check_line_file"
8057
8058 at_trace_this=
8059 if test -n "$at_traceon"; then
8060     echo 'Not enabling shell tracing (command contains an embedded newline)'
8061 fi
8062
8063 if test -n "$at_trace_this"; then
8064     ( $at_traceon;
8065 mkdir v7
8066 (cd v7
8067 TEST_TAR_FORMAT=v7
8068 export TEST_TAR_FORMAT
8069 TAR_OPTIONS="-H v7"
8070 export TAR_OPTIONS
8071 rm -rf *
8072
8073 mkdir directory
8074 tar -cPvf archive directory/../directory
8075 echo separator
8076 tar -xPvf archive) ) >"$at_stdout" 2>"$at_stder1"
8077     at_status=$?
8078     grep '^ *+' "$at_stder1" >&2
8079     grep -v '^ *+' "$at_stder1" >"$at_stderr"
8080 else
8081     ( :;
8082 mkdir v7
8083 (cd v7
8084 TEST_TAR_FORMAT=v7
8085 export TEST_TAR_FORMAT
8086 TAR_OPTIONS="-H v7"
8087 export TAR_OPTIONS
8088 rm -rf *
8089
8090 mkdir directory
8091 tar -cPvf archive directory/../directory
8092 echo separator
8093 tar -xPvf archive) ) >"$at_stdout" 2>"$at_stderr"
8094     at_status=$?
8095 fi
8096
8097 at_failed=false
8098 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
8099 echo >>"$at_stdout"; echo "directory/../directory/
8100 separator
8101 directory/../directory/
8102 " | $at_diff - "$at_stdout" || at_failed=:
8103 case $at_status in
8104    77) echo 77 > "$at_status_file"; exit 77;;
8105    0) ;;
8106    *) echo "$at_srcdir/extrac03.at:26: exit code was $at_status, expected 0"
8107       at_failed=:;;
8108 esac
8109 if $at_failed; then
8110
8111
8112   echo 1 > "$at_status_file"
8113   exit 1
8114 fi
8115
8116 $at_traceon
8117 $at_traceoff
8118 echo "$at_srcdir/extrac03.at:26:
8119 mkdir oldgnu
8120 (cd oldgnu
8121 TEST_TAR_FORMAT=oldgnu
8122 export TEST_TAR_FORMAT
8123 TAR_OPTIONS=\"-H oldgnu\"
8124 export TAR_OPTIONS
8125 rm -rf *
8126
8127 mkdir directory
8128 tar -cPvf archive directory/../directory
8129 echo separator
8130 tar -xPvf archive)"
8131 echo extrac03.at:26 >"$at_check_line_file"
8132
8133 at_trace_this=
8134 if test -n "$at_traceon"; then
8135     echo 'Not enabling shell tracing (command contains an embedded newline)'
8136 fi
8137
8138 if test -n "$at_trace_this"; then
8139     ( $at_traceon;
8140 mkdir oldgnu
8141 (cd oldgnu
8142 TEST_TAR_FORMAT=oldgnu
8143 export TEST_TAR_FORMAT
8144 TAR_OPTIONS="-H oldgnu"
8145 export TAR_OPTIONS
8146 rm -rf *
8147
8148 mkdir directory
8149 tar -cPvf archive directory/../directory
8150 echo separator
8151 tar -xPvf archive) ) >"$at_stdout" 2>"$at_stder1"
8152     at_status=$?
8153     grep '^ *+' "$at_stder1" >&2
8154     grep -v '^ *+' "$at_stder1" >"$at_stderr"
8155 else
8156     ( :;
8157 mkdir oldgnu
8158 (cd oldgnu
8159 TEST_TAR_FORMAT=oldgnu
8160 export TEST_TAR_FORMAT
8161 TAR_OPTIONS="-H oldgnu"
8162 export TAR_OPTIONS
8163 rm -rf *
8164
8165 mkdir directory
8166 tar -cPvf archive directory/../directory
8167 echo separator
8168 tar -xPvf archive) ) >"$at_stdout" 2>"$at_stderr"
8169     at_status=$?
8170 fi
8171
8172 at_failed=false
8173 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
8174 echo >>"$at_stdout"; echo "directory/../directory/
8175 separator
8176 directory/../directory/
8177 " | $at_diff - "$at_stdout" || at_failed=:
8178 case $at_status in
8179    77) echo 77 > "$at_status_file"; exit 77;;
8180    0) ;;
8181    *) echo "$at_srcdir/extrac03.at:26: exit code was $at_status, expected 0"
8182       at_failed=:;;
8183 esac
8184 if $at_failed; then
8185
8186
8187   echo 1 > "$at_status_file"
8188   exit 1
8189 fi
8190
8191 $at_traceon
8192 $at_traceoff
8193 echo "$at_srcdir/extrac03.at:26:
8194 mkdir ustar
8195 (cd ustar
8196 TEST_TAR_FORMAT=ustar
8197 export TEST_TAR_FORMAT
8198 TAR_OPTIONS=\"-H ustar\"
8199 export TAR_OPTIONS
8200 rm -rf *
8201
8202 mkdir directory
8203 tar -cPvf archive directory/../directory
8204 echo separator
8205 tar -xPvf archive)"
8206 echo extrac03.at:26 >"$at_check_line_file"
8207
8208 at_trace_this=
8209 if test -n "$at_traceon"; then
8210     echo 'Not enabling shell tracing (command contains an embedded newline)'
8211 fi
8212
8213 if test -n "$at_trace_this"; then
8214     ( $at_traceon;
8215 mkdir ustar
8216 (cd ustar
8217 TEST_TAR_FORMAT=ustar
8218 export TEST_TAR_FORMAT
8219 TAR_OPTIONS="-H ustar"
8220 export TAR_OPTIONS
8221 rm -rf *
8222
8223 mkdir directory
8224 tar -cPvf archive directory/../directory
8225 echo separator
8226 tar -xPvf archive) ) >"$at_stdout" 2>"$at_stder1"
8227     at_status=$?
8228     grep '^ *+' "$at_stder1" >&2
8229     grep -v '^ *+' "$at_stder1" >"$at_stderr"
8230 else
8231     ( :;
8232 mkdir ustar
8233 (cd ustar
8234 TEST_TAR_FORMAT=ustar
8235 export TEST_TAR_FORMAT
8236 TAR_OPTIONS="-H ustar"
8237 export TAR_OPTIONS
8238 rm -rf *
8239
8240 mkdir directory
8241 tar -cPvf archive directory/../directory
8242 echo separator
8243 tar -xPvf archive) ) >"$at_stdout" 2>"$at_stderr"
8244     at_status=$?
8245 fi
8246
8247 at_failed=false
8248 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
8249 echo >>"$at_stdout"; echo "directory/../directory/
8250 separator
8251 directory/../directory/
8252 " | $at_diff - "$at_stdout" || at_failed=:
8253 case $at_status in
8254    77) echo 77 > "$at_status_file"; exit 77;;
8255    0) ;;
8256    *) echo "$at_srcdir/extrac03.at:26: exit code was $at_status, expected 0"
8257       at_failed=:;;
8258 esac
8259 if $at_failed; then
8260
8261
8262   echo 1 > "$at_status_file"
8263   exit 1
8264 fi
8265
8266 $at_traceon
8267 $at_traceoff
8268 echo "$at_srcdir/extrac03.at:26:
8269 mkdir posix
8270 (cd posix
8271 TEST_TAR_FORMAT=posix
8272 export TEST_TAR_FORMAT
8273 TAR_OPTIONS=\"-H posix\"
8274 export TAR_OPTIONS
8275 rm -rf *
8276
8277 mkdir directory
8278 tar -cPvf archive directory/../directory
8279 echo separator
8280 tar -xPvf archive)"
8281 echo extrac03.at:26 >"$at_check_line_file"
8282
8283 at_trace_this=
8284 if test -n "$at_traceon"; then
8285     echo 'Not enabling shell tracing (command contains an embedded newline)'
8286 fi
8287
8288 if test -n "$at_trace_this"; then
8289     ( $at_traceon;
8290 mkdir posix
8291 (cd posix
8292 TEST_TAR_FORMAT=posix
8293 export TEST_TAR_FORMAT
8294 TAR_OPTIONS="-H posix"
8295 export TAR_OPTIONS
8296 rm -rf *
8297
8298 mkdir directory
8299 tar -cPvf archive directory/../directory
8300 echo separator
8301 tar -xPvf archive) ) >"$at_stdout" 2>"$at_stder1"
8302     at_status=$?
8303     grep '^ *+' "$at_stder1" >&2
8304     grep -v '^ *+' "$at_stder1" >"$at_stderr"
8305 else
8306     ( :;
8307 mkdir posix
8308 (cd posix
8309 TEST_TAR_FORMAT=posix
8310 export TEST_TAR_FORMAT
8311 TAR_OPTIONS="-H posix"
8312 export TAR_OPTIONS
8313 rm -rf *
8314
8315 mkdir directory
8316 tar -cPvf archive directory/../directory
8317 echo separator
8318 tar -xPvf archive) ) >"$at_stdout" 2>"$at_stderr"
8319     at_status=$?
8320 fi
8321
8322 at_failed=false
8323 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
8324 echo >>"$at_stdout"; echo "directory/../directory/
8325 separator
8326 directory/../directory/
8327 " | $at_diff - "$at_stdout" || at_failed=:
8328 case $at_status in
8329    77) echo 77 > "$at_status_file"; exit 77;;
8330    0) ;;
8331    *) echo "$at_srcdir/extrac03.at:26: exit code was $at_status, expected 0"
8332       at_failed=:;;
8333 esac
8334 if $at_failed; then
8335
8336
8337   echo 1 > "$at_status_file"
8338   exit 1
8339 fi
8340
8341 $at_traceon
8342 $at_traceoff
8343 echo "$at_srcdir/extrac03.at:26:
8344 mkdir gnu
8345 (cd gnu
8346 TEST_TAR_FORMAT=gnu
8347 export TEST_TAR_FORMAT
8348 TAR_OPTIONS=\"-H gnu\"
8349 export TAR_OPTIONS
8350 rm -rf *
8351
8352 mkdir directory
8353 tar -cPvf archive directory/../directory
8354 echo separator
8355 tar -xPvf archive)"
8356 echo extrac03.at:26 >"$at_check_line_file"
8357
8358 at_trace_this=
8359 if test -n "$at_traceon"; then
8360     echo 'Not enabling shell tracing (command contains an embedded newline)'
8361 fi
8362
8363 if test -n "$at_trace_this"; then
8364     ( $at_traceon;
8365 mkdir gnu
8366 (cd gnu
8367 TEST_TAR_FORMAT=gnu
8368 export TEST_TAR_FORMAT
8369 TAR_OPTIONS="-H gnu"
8370 export TAR_OPTIONS
8371 rm -rf *
8372
8373 mkdir directory
8374 tar -cPvf archive directory/../directory
8375 echo separator
8376 tar -xPvf archive) ) >"$at_stdout" 2>"$at_stder1"
8377     at_status=$?
8378     grep '^ *+' "$at_stder1" >&2
8379     grep -v '^ *+' "$at_stder1" >"$at_stderr"
8380 else
8381     ( :;
8382 mkdir gnu
8383 (cd gnu
8384 TEST_TAR_FORMAT=gnu
8385 export TEST_TAR_FORMAT
8386 TAR_OPTIONS="-H gnu"
8387 export TAR_OPTIONS
8388 rm -rf *
8389
8390 mkdir directory
8391 tar -cPvf archive directory/../directory
8392 echo separator
8393 tar -xPvf archive) ) >"$at_stdout" 2>"$at_stderr"
8394     at_status=$?
8395 fi
8396
8397 at_failed=false
8398 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
8399 echo >>"$at_stdout"; echo "directory/../directory/
8400 separator
8401 directory/../directory/
8402 " | $at_diff - "$at_stdout" || at_failed=:
8403 case $at_status in
8404    77) echo 77 > "$at_status_file"; exit 77;;
8405    0) ;;
8406    *) echo "$at_srcdir/extrac03.at:26: exit code was $at_status, expected 0"
8407       at_failed=:;;
8408 esac
8409 if $at_failed; then
8410
8411
8412   echo 1 > "$at_status_file"
8413   exit 1
8414 fi
8415
8416 $at_traceon
8417
8418
8419
8420       $at_traceoff
8421       $at_times_p && times >"$at_times_file"
8422     ) 5>&1 2>&1 | eval $at_tee_pipe
8423     at_status=`cat "$at_status_file"`
8424     ;;
8425
8426   21 ) # 21. extrac04.at:23: extract + fnmatch
8427     at_setup_line='extrac04.at:23'
8428     at_desc="extract + fnmatch"
8429     $at_quiet $ECHO_N " 21: extract + fnmatch                              $ECHO_C"
8430     at_xfail=no
8431       test -f $XFAILFILE && at_xfail=yes
8432     echo "#                             -*- compilation -*-" >> "$at_group_log"
8433     (
8434       echo "21. extrac04.at:23: testing ..."
8435       $at_traceon
8436
8437
8438
8439
8440
8441   $at_traceoff
8442 echo "$at_srcdir/extrac04.at:26:
8443 mkdir v7
8444 (cd v7
8445 TEST_TAR_FORMAT=v7
8446 export TEST_TAR_FORMAT
8447 TAR_OPTIONS=\"-H v7\"
8448 export TAR_OPTIONS
8449 rm -rf *
8450
8451
8452 test -z "`sort < /dev/null 2>&1`" || exit 77
8453
8454 touch file1
8455 mkdir directory
8456 mkdir directory/subdirectory
8457 touch directory/file1
8458 touch directory/file2
8459 touch directory/subdirectory/file1
8460 touch directory/subdirectory/file2
8461 tar -cf archive ./file1 directory
8462 tar -tf archive \\
8463   --exclude='./*1' \\
8464   --exclude='d*/*1' \\
8465   --exclude='d*/s*/*2' | sort
8466 )"
8467 echo extrac04.at:26 >"$at_check_line_file"
8468
8469 at_trace_this=
8470 if test -n "$at_traceon"; then
8471     echo 'Not enabling shell tracing (command contains an embedded newline)'
8472 fi
8473
8474 if test -n "$at_trace_this"; then
8475     ( $at_traceon;
8476 mkdir v7
8477 (cd v7
8478 TEST_TAR_FORMAT=v7
8479 export TEST_TAR_FORMAT
8480 TAR_OPTIONS="-H v7"
8481 export TAR_OPTIONS
8482 rm -rf *
8483
8484
8485 test -z "`sort < /dev/null 2>&1`" || exit 77
8486
8487 touch file1
8488 mkdir directory
8489 mkdir directory/subdirectory
8490 touch directory/file1
8491 touch directory/file2
8492 touch directory/subdirectory/file1
8493 touch directory/subdirectory/file2
8494 tar -cf archive ./file1 directory
8495 tar -tf archive \
8496   --exclude='./*1' \
8497   --exclude='d*/*1' \
8498   --exclude='d*/s*/*2' | sort
8499 ) ) >"$at_stdout" 2>"$at_stder1"
8500     at_status=$?
8501     grep '^ *+' "$at_stder1" >&2
8502     grep -v '^ *+' "$at_stder1" >"$at_stderr"
8503 else
8504     ( :;
8505 mkdir v7
8506 (cd v7
8507 TEST_TAR_FORMAT=v7
8508 export TEST_TAR_FORMAT
8509 TAR_OPTIONS="-H v7"
8510 export TAR_OPTIONS
8511 rm -rf *
8512
8513
8514 test -z "`sort < /dev/null 2>&1`" || exit 77
8515
8516 touch file1
8517 mkdir directory
8518 mkdir directory/subdirectory
8519 touch directory/file1
8520 touch directory/file2
8521 touch directory/subdirectory/file1
8522 touch directory/subdirectory/file2
8523 tar -cf archive ./file1 directory
8524 tar -tf archive \
8525   --exclude='./*1' \
8526   --exclude='d*/*1' \
8527   --exclude='d*/s*/*2' | sort
8528 ) ) >"$at_stdout" 2>"$at_stderr"
8529     at_status=$?
8530 fi
8531
8532 at_failed=false
8533 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
8534 echo >>"$at_stdout"; echo "directory/
8535 directory/file2
8536 directory/subdirectory/
8537 " | $at_diff - "$at_stdout" || at_failed=:
8538 case $at_status in
8539    77) echo 77 > "$at_status_file"; exit 77;;
8540    0) ;;
8541    *) echo "$at_srcdir/extrac04.at:26: exit code was $at_status, expected 0"
8542       at_failed=:;;
8543 esac
8544 if $at_failed; then
8545
8546
8547   echo 1 > "$at_status_file"
8548   exit 1
8549 fi
8550
8551 $at_traceon
8552 $at_traceoff
8553 echo "$at_srcdir/extrac04.at:26:
8554 mkdir oldgnu
8555 (cd oldgnu
8556 TEST_TAR_FORMAT=oldgnu
8557 export TEST_TAR_FORMAT
8558 TAR_OPTIONS=\"-H oldgnu\"
8559 export TAR_OPTIONS
8560 rm -rf *
8561
8562
8563 test -z "`sort < /dev/null 2>&1`" || exit 77
8564
8565 touch file1
8566 mkdir directory
8567 mkdir directory/subdirectory
8568 touch directory/file1
8569 touch directory/file2
8570 touch directory/subdirectory/file1
8571 touch directory/subdirectory/file2
8572 tar -cf archive ./file1 directory
8573 tar -tf archive \\
8574   --exclude='./*1' \\
8575   --exclude='d*/*1' \\
8576   --exclude='d*/s*/*2' | sort
8577 )"
8578 echo extrac04.at:26 >"$at_check_line_file"
8579
8580 at_trace_this=
8581 if test -n "$at_traceon"; then
8582     echo 'Not enabling shell tracing (command contains an embedded newline)'
8583 fi
8584
8585 if test -n "$at_trace_this"; then
8586     ( $at_traceon;
8587 mkdir oldgnu
8588 (cd oldgnu
8589 TEST_TAR_FORMAT=oldgnu
8590 export TEST_TAR_FORMAT
8591 TAR_OPTIONS="-H oldgnu"
8592 export TAR_OPTIONS
8593 rm -rf *
8594
8595
8596 test -z "`sort < /dev/null 2>&1`" || exit 77
8597
8598 touch file1
8599 mkdir directory
8600 mkdir directory/subdirectory
8601 touch directory/file1
8602 touch directory/file2
8603 touch directory/subdirectory/file1
8604 touch directory/subdirectory/file2
8605 tar -cf archive ./file1 directory
8606 tar -tf archive \
8607   --exclude='./*1' \
8608   --exclude='d*/*1' \
8609   --exclude='d*/s*/*2' | sort
8610 ) ) >"$at_stdout" 2>"$at_stder1"
8611     at_status=$?
8612     grep '^ *+' "$at_stder1" >&2
8613     grep -v '^ *+' "$at_stder1" >"$at_stderr"
8614 else
8615     ( :;
8616 mkdir oldgnu
8617 (cd oldgnu
8618 TEST_TAR_FORMAT=oldgnu
8619 export TEST_TAR_FORMAT
8620 TAR_OPTIONS="-H oldgnu"
8621 export TAR_OPTIONS
8622 rm -rf *
8623
8624
8625 test -z "`sort < /dev/null 2>&1`" || exit 77
8626
8627 touch file1
8628 mkdir directory
8629 mkdir directory/subdirectory
8630 touch directory/file1
8631 touch directory/file2
8632 touch directory/subdirectory/file1
8633 touch directory/subdirectory/file2
8634 tar -cf archive ./file1 directory
8635 tar -tf archive \
8636   --exclude='./*1' \
8637   --exclude='d*/*1' \
8638   --exclude='d*/s*/*2' | sort
8639 ) ) >"$at_stdout" 2>"$at_stderr"
8640     at_status=$?
8641 fi
8642
8643 at_failed=false
8644 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
8645 echo >>"$at_stdout"; echo "directory/
8646 directory/file2
8647 directory/subdirectory/
8648 " | $at_diff - "$at_stdout" || at_failed=:
8649 case $at_status in
8650    77) echo 77 > "$at_status_file"; exit 77;;
8651    0) ;;
8652    *) echo "$at_srcdir/extrac04.at:26: exit code was $at_status, expected 0"
8653       at_failed=:;;
8654 esac
8655 if $at_failed; then
8656
8657
8658   echo 1 > "$at_status_file"
8659   exit 1
8660 fi
8661
8662 $at_traceon
8663 $at_traceoff
8664 echo "$at_srcdir/extrac04.at:26:
8665 mkdir ustar
8666 (cd ustar
8667 TEST_TAR_FORMAT=ustar
8668 export TEST_TAR_FORMAT
8669 TAR_OPTIONS=\"-H ustar\"
8670 export TAR_OPTIONS
8671 rm -rf *
8672
8673
8674 test -z "`sort < /dev/null 2>&1`" || exit 77
8675
8676 touch file1
8677 mkdir directory
8678 mkdir directory/subdirectory
8679 touch directory/file1
8680 touch directory/file2
8681 touch directory/subdirectory/file1
8682 touch directory/subdirectory/file2
8683 tar -cf archive ./file1 directory
8684 tar -tf archive \\
8685   --exclude='./*1' \\
8686   --exclude='d*/*1' \\
8687   --exclude='d*/s*/*2' | sort
8688 )"
8689 echo extrac04.at:26 >"$at_check_line_file"
8690
8691 at_trace_this=
8692 if test -n "$at_traceon"; then
8693     echo 'Not enabling shell tracing (command contains an embedded newline)'
8694 fi
8695
8696 if test -n "$at_trace_this"; then
8697     ( $at_traceon;
8698 mkdir ustar
8699 (cd ustar
8700 TEST_TAR_FORMAT=ustar
8701 export TEST_TAR_FORMAT
8702 TAR_OPTIONS="-H ustar"
8703 export TAR_OPTIONS
8704 rm -rf *
8705
8706
8707 test -z "`sort < /dev/null 2>&1`" || exit 77
8708
8709 touch file1
8710 mkdir directory
8711 mkdir directory/subdirectory
8712 touch directory/file1
8713 touch directory/file2
8714 touch directory/subdirectory/file1
8715 touch directory/subdirectory/file2
8716 tar -cf archive ./file1 directory
8717 tar -tf archive \
8718   --exclude='./*1' \
8719   --exclude='d*/*1' \
8720   --exclude='d*/s*/*2' | sort
8721 ) ) >"$at_stdout" 2>"$at_stder1"
8722     at_status=$?
8723     grep '^ *+' "$at_stder1" >&2
8724     grep -v '^ *+' "$at_stder1" >"$at_stderr"
8725 else
8726     ( :;
8727 mkdir ustar
8728 (cd ustar
8729 TEST_TAR_FORMAT=ustar
8730 export TEST_TAR_FORMAT
8731 TAR_OPTIONS="-H ustar"
8732 export TAR_OPTIONS
8733 rm -rf *
8734
8735
8736 test -z "`sort < /dev/null 2>&1`" || exit 77
8737
8738 touch file1
8739 mkdir directory
8740 mkdir directory/subdirectory
8741 touch directory/file1
8742 touch directory/file2
8743 touch directory/subdirectory/file1
8744 touch directory/subdirectory/file2
8745 tar -cf archive ./file1 directory
8746 tar -tf archive \
8747   --exclude='./*1' \
8748   --exclude='d*/*1' \
8749   --exclude='d*/s*/*2' | sort
8750 ) ) >"$at_stdout" 2>"$at_stderr"
8751     at_status=$?
8752 fi
8753
8754 at_failed=false
8755 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
8756 echo >>"$at_stdout"; echo "directory/
8757 directory/file2
8758 directory/subdirectory/
8759 " | $at_diff - "$at_stdout" || at_failed=:
8760 case $at_status in
8761    77) echo 77 > "$at_status_file"; exit 77;;
8762    0) ;;
8763    *) echo "$at_srcdir/extrac04.at:26: exit code was $at_status, expected 0"
8764       at_failed=:;;
8765 esac
8766 if $at_failed; then
8767
8768
8769   echo 1 > "$at_status_file"
8770   exit 1
8771 fi
8772
8773 $at_traceon
8774 $at_traceoff
8775 echo "$at_srcdir/extrac04.at:26:
8776 mkdir posix
8777 (cd posix
8778 TEST_TAR_FORMAT=posix
8779 export TEST_TAR_FORMAT
8780 TAR_OPTIONS=\"-H posix\"
8781 export TAR_OPTIONS
8782 rm -rf *
8783
8784
8785 test -z "`sort < /dev/null 2>&1`" || exit 77
8786
8787 touch file1
8788 mkdir directory
8789 mkdir directory/subdirectory
8790 touch directory/file1
8791 touch directory/file2
8792 touch directory/subdirectory/file1
8793 touch directory/subdirectory/file2
8794 tar -cf archive ./file1 directory
8795 tar -tf archive \\
8796   --exclude='./*1' \\
8797   --exclude='d*/*1' \\
8798   --exclude='d*/s*/*2' | sort
8799 )"
8800 echo extrac04.at:26 >"$at_check_line_file"
8801
8802 at_trace_this=
8803 if test -n "$at_traceon"; then
8804     echo 'Not enabling shell tracing (command contains an embedded newline)'
8805 fi
8806
8807 if test -n "$at_trace_this"; then
8808     ( $at_traceon;
8809 mkdir posix
8810 (cd posix
8811 TEST_TAR_FORMAT=posix
8812 export TEST_TAR_FORMAT
8813 TAR_OPTIONS="-H posix"
8814 export TAR_OPTIONS
8815 rm -rf *
8816
8817
8818 test -z "`sort < /dev/null 2>&1`" || exit 77
8819
8820 touch file1
8821 mkdir directory
8822 mkdir directory/subdirectory
8823 touch directory/file1
8824 touch directory/file2
8825 touch directory/subdirectory/file1
8826 touch directory/subdirectory/file2
8827 tar -cf archive ./file1 directory
8828 tar -tf archive \
8829   --exclude='./*1' \
8830   --exclude='d*/*1' \
8831   --exclude='d*/s*/*2' | sort
8832 ) ) >"$at_stdout" 2>"$at_stder1"
8833     at_status=$?
8834     grep '^ *+' "$at_stder1" >&2
8835     grep -v '^ *+' "$at_stder1" >"$at_stderr"
8836 else
8837     ( :;
8838 mkdir posix
8839 (cd posix
8840 TEST_TAR_FORMAT=posix
8841 export TEST_TAR_FORMAT
8842 TAR_OPTIONS="-H posix"
8843 export TAR_OPTIONS
8844 rm -rf *
8845
8846
8847 test -z "`sort < /dev/null 2>&1`" || exit 77
8848
8849 touch file1
8850 mkdir directory
8851 mkdir directory/subdirectory
8852 touch directory/file1
8853 touch directory/file2
8854 touch directory/subdirectory/file1
8855 touch directory/subdirectory/file2
8856 tar -cf archive ./file1 directory
8857 tar -tf archive \
8858   --exclude='./*1' \
8859   --exclude='d*/*1' \
8860   --exclude='d*/s*/*2' | sort
8861 ) ) >"$at_stdout" 2>"$at_stderr"
8862     at_status=$?
8863 fi
8864
8865 at_failed=false
8866 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
8867 echo >>"$at_stdout"; echo "directory/
8868 directory/file2
8869 directory/subdirectory/
8870 " | $at_diff - "$at_stdout" || at_failed=:
8871 case $at_status in
8872    77) echo 77 > "$at_status_file"; exit 77;;
8873    0) ;;
8874    *) echo "$at_srcdir/extrac04.at:26: exit code was $at_status, expected 0"
8875       at_failed=:;;
8876 esac
8877 if $at_failed; then
8878
8879
8880   echo 1 > "$at_status_file"
8881   exit 1
8882 fi
8883
8884 $at_traceon
8885 $at_traceoff
8886 echo "$at_srcdir/extrac04.at:26:
8887 mkdir gnu
8888 (cd gnu
8889 TEST_TAR_FORMAT=gnu
8890 export TEST_TAR_FORMAT
8891 TAR_OPTIONS=\"-H gnu\"
8892 export TAR_OPTIONS
8893 rm -rf *
8894
8895
8896 test -z "`sort < /dev/null 2>&1`" || exit 77
8897
8898 touch file1
8899 mkdir directory
8900 mkdir directory/subdirectory
8901 touch directory/file1
8902 touch directory/file2
8903 touch directory/subdirectory/file1
8904 touch directory/subdirectory/file2
8905 tar -cf archive ./file1 directory
8906 tar -tf archive \\
8907   --exclude='./*1' \\
8908   --exclude='d*/*1' \\
8909   --exclude='d*/s*/*2' | sort
8910 )"
8911 echo extrac04.at:26 >"$at_check_line_file"
8912
8913 at_trace_this=
8914 if test -n "$at_traceon"; then
8915     echo 'Not enabling shell tracing (command contains an embedded newline)'
8916 fi
8917
8918 if test -n "$at_trace_this"; then
8919     ( $at_traceon;
8920 mkdir gnu
8921 (cd gnu
8922 TEST_TAR_FORMAT=gnu
8923 export TEST_TAR_FORMAT
8924 TAR_OPTIONS="-H gnu"
8925 export TAR_OPTIONS
8926 rm -rf *
8927
8928
8929 test -z "`sort < /dev/null 2>&1`" || exit 77
8930
8931 touch file1
8932 mkdir directory
8933 mkdir directory/subdirectory
8934 touch directory/file1
8935 touch directory/file2
8936 touch directory/subdirectory/file1
8937 touch directory/subdirectory/file2
8938 tar -cf archive ./file1 directory
8939 tar -tf archive \
8940   --exclude='./*1' \
8941   --exclude='d*/*1' \
8942   --exclude='d*/s*/*2' | sort
8943 ) ) >"$at_stdout" 2>"$at_stder1"
8944     at_status=$?
8945     grep '^ *+' "$at_stder1" >&2
8946     grep -v '^ *+' "$at_stder1" >"$at_stderr"
8947 else
8948     ( :;
8949 mkdir gnu
8950 (cd gnu
8951 TEST_TAR_FORMAT=gnu
8952 export TEST_TAR_FORMAT
8953 TAR_OPTIONS="-H gnu"
8954 export TAR_OPTIONS
8955 rm -rf *
8956
8957
8958 test -z "`sort < /dev/null 2>&1`" || exit 77
8959
8960 touch file1
8961 mkdir directory
8962 mkdir directory/subdirectory
8963 touch directory/file1
8964 touch directory/file2
8965 touch directory/subdirectory/file1
8966 touch directory/subdirectory/file2
8967 tar -cf archive ./file1 directory
8968 tar -tf archive \
8969   --exclude='./*1' \
8970   --exclude='d*/*1' \
8971   --exclude='d*/s*/*2' | sort
8972 ) ) >"$at_stdout" 2>"$at_stderr"
8973     at_status=$?
8974 fi
8975
8976 at_failed=false
8977 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
8978 echo >>"$at_stdout"; echo "directory/
8979 directory/file2
8980 directory/subdirectory/
8981 " | $at_diff - "$at_stdout" || at_failed=:
8982 case $at_status in
8983    77) echo 77 > "$at_status_file"; exit 77;;
8984    0) ;;
8985    *) echo "$at_srcdir/extrac04.at:26: exit code was $at_status, expected 0"
8986       at_failed=:;;
8987 esac
8988 if $at_failed; then
8989
8990
8991   echo 1 > "$at_status_file"
8992   exit 1
8993 fi
8994
8995 $at_traceon
8996
8997
8998
8999       $at_traceoff
9000       $at_times_p && times >"$at_times_file"
9001     ) 5>&1 2>&1 | eval $at_tee_pipe
9002     at_status=`cat "$at_status_file"`
9003     ;;
9004
9005   22 ) # 22. extrac05.at:30: extracting selected members from pax
9006     at_setup_line='extrac05.at:30'
9007     at_desc="extracting selected members from pax"
9008     $at_quiet $ECHO_N " 22: extracting selected members from pax           $ECHO_C"
9009     at_xfail=no
9010       test -f $XFAILFILE && at_xfail=yes
9011     echo "#                             -*- compilation -*-" >> "$at_group_log"
9012     (
9013       echo "22. extrac05.at:30: testing ..."
9014       $at_traceon
9015
9016
9017
9018 cat >list <<'_ATEOF'
9019 jeden
9020 cztery
9021 _ATEOF
9022
9023
9024
9025
9026   $at_traceoff
9027 echo "$at_srcdir/extrac05.at:38:
9028 mkdir posix
9029 (cd posix
9030 TEST_TAR_FORMAT=posix
9031 export TEST_TAR_FORMAT
9032 TAR_OPTIONS=\"-H posix\"
9033 export TAR_OPTIONS
9034 rm -rf *
9035
9036 genfile --length 118 --file jeden
9037 genfile --length 223 --file dwa
9038 genfile --length 517 --file trzy
9039 genfile --sparse --file sparsefile 0 ABCD 1M EFGH 2000K IJKL
9040 genfile --length 110 --file cztery
9041
9042 tar cf archive jeden dwa trzy cztery || exit 1
9043
9044 mkdir dir
9045 cd dir
9046
9047 tar xvfT ../archive ../../list || exit 1
9048
9049 cd ..
9050 )"
9051 echo extrac05.at:38 >"$at_check_line_file"
9052
9053 at_trace_this=
9054 if test -n "$at_traceon"; then
9055     echo 'Not enabling shell tracing (command contains an embedded newline)'
9056 fi
9057
9058 if test -n "$at_trace_this"; then
9059     ( $at_traceon;
9060 mkdir posix
9061 (cd posix
9062 TEST_TAR_FORMAT=posix
9063 export TEST_TAR_FORMAT
9064 TAR_OPTIONS="-H posix"
9065 export TAR_OPTIONS
9066 rm -rf *
9067
9068 genfile --length 118 --file jeden
9069 genfile --length 223 --file dwa
9070 genfile --length 517 --file trzy
9071 genfile --sparse --file sparsefile 0 ABCD 1M EFGH 2000K IJKL
9072 genfile --length 110 --file cztery
9073
9074 tar cf archive jeden dwa trzy cztery || exit 1
9075
9076 mkdir dir
9077 cd dir
9078
9079 tar xvfT ../archive ../../list || exit 1
9080
9081 cd ..
9082 ) ) >"$at_stdout" 2>"$at_stder1"
9083     at_status=$?
9084     grep '^ *+' "$at_stder1" >&2
9085     grep -v '^ *+' "$at_stder1" >"$at_stderr"
9086 else
9087     ( :;
9088 mkdir posix
9089 (cd posix
9090 TEST_TAR_FORMAT=posix
9091 export TEST_TAR_FORMAT
9092 TAR_OPTIONS="-H posix"
9093 export TAR_OPTIONS
9094 rm -rf *
9095
9096 genfile --length 118 --file jeden
9097 genfile --length 223 --file dwa
9098 genfile --length 517 --file trzy
9099 genfile --sparse --file sparsefile 0 ABCD 1M EFGH 2000K IJKL
9100 genfile --length 110 --file cztery
9101
9102 tar cf archive jeden dwa trzy cztery || exit 1
9103
9104 mkdir dir
9105 cd dir
9106
9107 tar xvfT ../archive ../../list || exit 1
9108
9109 cd ..
9110 ) ) >"$at_stdout" 2>"$at_stderr"
9111     at_status=$?
9112 fi
9113
9114 at_failed=false
9115 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
9116 echo >>"$at_stdout"; echo "jeden
9117 cztery
9118 " | $at_diff - "$at_stdout" || at_failed=:
9119 case $at_status in
9120    77) echo 77 > "$at_status_file"; exit 77;;
9121    0) ;;
9122    *) echo "$at_srcdir/extrac05.at:38: exit code was $at_status, expected 0"
9123       at_failed=:;;
9124 esac
9125 if $at_failed; then
9126
9127
9128   echo 1 > "$at_status_file"
9129   exit 1
9130 fi
9131
9132 $at_traceon
9133
9134
9135
9136       $at_traceoff
9137       $at_times_p && times >"$at_times_file"
9138     ) 5>&1 2>&1 | eval $at_tee_pipe
9139     at_status=`cat "$at_status_file"`
9140     ;;
9141
9142   23 ) # 23. extrac06.at:33: mode of extracted directories
9143     at_setup_line='extrac06.at:33'
9144     at_desc="mode of extracted directories"
9145     $at_quiet $ECHO_N " 23: mode of extracted directories                  $ECHO_C"
9146     at_xfail=no
9147       test -f $XFAILFILE && at_xfail=yes
9148     echo "#                             -*- compilation -*-" >> "$at_group_log"
9149     (
9150       echo "23. extrac06.at:33: testing ..."
9151       $at_traceon
9152
9153
9154
9155
9156
9157   $at_traceoff
9158 echo "$at_srcdir/extrac06.at:36:
9159 mkdir v7
9160 (cd v7
9161 TEST_TAR_FORMAT=v7
9162 export TEST_TAR_FORMAT
9163 TAR_OPTIONS=\"-H v7\"
9164 export TAR_OPTIONS
9165 rm -rf *
9166
9167
9168 # Force umask
9169 umask 022
9170
9171 # Make sure user's umask is honored, even if we are superuser
9172 TAR_OPTIONS=\"\$TAR_OPTIONS --no-same-permissions\"
9173
9174 # Create a directory
9175 mkdir directory
9176 chmod 777 directory
9177 genfile --stat=mode:777 directory
9178
9179 # Archive it
9180 tar cf arc directory
9181
9182 # Change its permissions ...
9183 chmod 755 directory
9184 genfile --stat=mode:777 directory
9185
9186 # ... and attempt to restore it twice
9187 tar xf arc directory
9188 genfile --stat=mode:777 directory
9189
9190 tar xf arc directory
9191 genfile --stat=mode:777 directory
9192
9193 # After both restores, the directory mode should be 755
9194 )"
9195 echo extrac06.at:36 >"$at_check_line_file"
9196
9197 at_trace_this=
9198 if test -n "$at_traceon"; then
9199     echo 'Not enabling shell tracing (command contains an embedded newline)'
9200 fi
9201
9202 if test -n "$at_trace_this"; then
9203     ( $at_traceon;
9204 mkdir v7
9205 (cd v7
9206 TEST_TAR_FORMAT=v7
9207 export TEST_TAR_FORMAT
9208 TAR_OPTIONS="-H v7"
9209 export TAR_OPTIONS
9210 rm -rf *
9211
9212
9213 # Force umask
9214 umask 022
9215
9216 # Make sure user's umask is honored, even if we are superuser
9217 TAR_OPTIONS="$TAR_OPTIONS --no-same-permissions"
9218
9219 # Create a directory
9220 mkdir directory
9221 chmod 777 directory
9222 genfile --stat=mode:777 directory
9223
9224 # Archive it
9225 tar cf arc directory
9226
9227 # Change its permissions ...
9228 chmod 755 directory
9229 genfile --stat=mode:777 directory
9230
9231 # ... and attempt to restore it twice
9232 tar xf arc directory
9233 genfile --stat=mode:777 directory
9234
9235 tar xf arc directory
9236 genfile --stat=mode:777 directory
9237
9238 # After both restores, the directory mode should be 755
9239 ) ) >"$at_stdout" 2>"$at_stder1"
9240     at_status=$?
9241     grep '^ *+' "$at_stder1" >&2
9242     grep -v '^ *+' "$at_stder1" >"$at_stderr"
9243 else
9244     ( :;
9245 mkdir v7
9246 (cd v7
9247 TEST_TAR_FORMAT=v7
9248 export TEST_TAR_FORMAT
9249 TAR_OPTIONS="-H v7"
9250 export TAR_OPTIONS
9251 rm -rf *
9252
9253
9254 # Force umask
9255 umask 022
9256
9257 # Make sure user's umask is honored, even if we are superuser
9258 TAR_OPTIONS="$TAR_OPTIONS --no-same-permissions"
9259
9260 # Create a directory
9261 mkdir directory
9262 chmod 777 directory
9263 genfile --stat=mode:777 directory
9264
9265 # Archive it
9266 tar cf arc directory
9267
9268 # Change its permissions ...
9269 chmod 755 directory
9270 genfile --stat=mode:777 directory
9271
9272 # ... and attempt to restore it twice
9273 tar xf arc directory
9274 genfile --stat=mode:777 directory
9275
9276 tar xf arc directory
9277 genfile --stat=mode:777 directory
9278
9279 # After both restores, the directory mode should be 755
9280 ) ) >"$at_stdout" 2>"$at_stderr"
9281     at_status=$?
9282 fi
9283
9284 at_failed=false
9285 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
9286 echo >>"$at_stdout"; echo "777
9287 755
9288 755
9289 755
9290 " | $at_diff - "$at_stdout" || at_failed=:
9291 case $at_status in
9292    77) echo 77 > "$at_status_file"; exit 77;;
9293    0) ;;
9294    *) echo "$at_srcdir/extrac06.at:36: exit code was $at_status, expected 0"
9295       at_failed=:;;
9296 esac
9297 if $at_failed; then
9298
9299
9300   echo 1 > "$at_status_file"
9301   exit 1
9302 fi
9303
9304 $at_traceon
9305 $at_traceoff
9306 echo "$at_srcdir/extrac06.at:36:
9307 mkdir oldgnu
9308 (cd oldgnu
9309 TEST_TAR_FORMAT=oldgnu
9310 export TEST_TAR_FORMAT
9311 TAR_OPTIONS=\"-H oldgnu\"
9312 export TAR_OPTIONS
9313 rm -rf *
9314
9315
9316 # Force umask
9317 umask 022
9318
9319 # Make sure user's umask is honored, even if we are superuser
9320 TAR_OPTIONS=\"\$TAR_OPTIONS --no-same-permissions\"
9321
9322 # Create a directory
9323 mkdir directory
9324 chmod 777 directory
9325 genfile --stat=mode:777 directory
9326
9327 # Archive it
9328 tar cf arc directory
9329
9330 # Change its permissions ...
9331 chmod 755 directory
9332 genfile --stat=mode:777 directory
9333
9334 # ... and attempt to restore it twice
9335 tar xf arc directory
9336 genfile --stat=mode:777 directory
9337
9338 tar xf arc directory
9339 genfile --stat=mode:777 directory
9340
9341 # After both restores, the directory mode should be 755
9342 )"
9343 echo extrac06.at:36 >"$at_check_line_file"
9344
9345 at_trace_this=
9346 if test -n "$at_traceon"; then
9347     echo 'Not enabling shell tracing (command contains an embedded newline)'
9348 fi
9349
9350 if test -n "$at_trace_this"; then
9351     ( $at_traceon;
9352 mkdir oldgnu
9353 (cd oldgnu
9354 TEST_TAR_FORMAT=oldgnu
9355 export TEST_TAR_FORMAT
9356 TAR_OPTIONS="-H oldgnu"
9357 export TAR_OPTIONS
9358 rm -rf *
9359
9360
9361 # Force umask
9362 umask 022
9363
9364 # Make sure user's umask is honored, even if we are superuser
9365 TAR_OPTIONS="$TAR_OPTIONS --no-same-permissions"
9366
9367 # Create a directory
9368 mkdir directory
9369 chmod 777 directory
9370 genfile --stat=mode:777 directory
9371
9372 # Archive it
9373 tar cf arc directory
9374
9375 # Change its permissions ...
9376 chmod 755 directory
9377 genfile --stat=mode:777 directory
9378
9379 # ... and attempt to restore it twice
9380 tar xf arc directory
9381 genfile --stat=mode:777 directory
9382
9383 tar xf arc directory
9384 genfile --stat=mode:777 directory
9385
9386 # After both restores, the directory mode should be 755
9387 ) ) >"$at_stdout" 2>"$at_stder1"
9388     at_status=$?
9389     grep '^ *+' "$at_stder1" >&2
9390     grep -v '^ *+' "$at_stder1" >"$at_stderr"
9391 else
9392     ( :;
9393 mkdir oldgnu
9394 (cd oldgnu
9395 TEST_TAR_FORMAT=oldgnu
9396 export TEST_TAR_FORMAT
9397 TAR_OPTIONS="-H oldgnu"
9398 export TAR_OPTIONS
9399 rm -rf *
9400
9401
9402 # Force umask
9403 umask 022
9404
9405 # Make sure user's umask is honored, even if we are superuser
9406 TAR_OPTIONS="$TAR_OPTIONS --no-same-permissions"
9407
9408 # Create a directory
9409 mkdir directory
9410 chmod 777 directory
9411 genfile --stat=mode:777 directory
9412
9413 # Archive it
9414 tar cf arc directory
9415
9416 # Change its permissions ...
9417 chmod 755 directory
9418 genfile --stat=mode:777 directory
9419
9420 # ... and attempt to restore it twice
9421 tar xf arc directory
9422 genfile --stat=mode:777 directory
9423
9424 tar xf arc directory
9425 genfile --stat=mode:777 directory
9426
9427 # After both restores, the directory mode should be 755
9428 ) ) >"$at_stdout" 2>"$at_stderr"
9429     at_status=$?
9430 fi
9431
9432 at_failed=false
9433 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
9434 echo >>"$at_stdout"; echo "777
9435 755
9436 755
9437 755
9438 " | $at_diff - "$at_stdout" || at_failed=:
9439 case $at_status in
9440    77) echo 77 > "$at_status_file"; exit 77;;
9441    0) ;;
9442    *) echo "$at_srcdir/extrac06.at:36: exit code was $at_status, expected 0"
9443       at_failed=:;;
9444 esac
9445 if $at_failed; then
9446
9447
9448   echo 1 > "$at_status_file"
9449   exit 1
9450 fi
9451
9452 $at_traceon
9453 $at_traceoff
9454 echo "$at_srcdir/extrac06.at:36:
9455 mkdir ustar
9456 (cd ustar
9457 TEST_TAR_FORMAT=ustar
9458 export TEST_TAR_FORMAT
9459 TAR_OPTIONS=\"-H ustar\"
9460 export TAR_OPTIONS
9461 rm -rf *
9462
9463
9464 # Force umask
9465 umask 022
9466
9467 # Make sure user's umask is honored, even if we are superuser
9468 TAR_OPTIONS=\"\$TAR_OPTIONS --no-same-permissions\"
9469
9470 # Create a directory
9471 mkdir directory
9472 chmod 777 directory
9473 genfile --stat=mode:777 directory
9474
9475 # Archive it
9476 tar cf arc directory
9477
9478 # Change its permissions ...
9479 chmod 755 directory
9480 genfile --stat=mode:777 directory
9481
9482 # ... and attempt to restore it twice
9483 tar xf arc directory
9484 genfile --stat=mode:777 directory
9485
9486 tar xf arc directory
9487 genfile --stat=mode:777 directory
9488
9489 # After both restores, the directory mode should be 755
9490 )"
9491 echo extrac06.at:36 >"$at_check_line_file"
9492
9493 at_trace_this=
9494 if test -n "$at_traceon"; then
9495     echo 'Not enabling shell tracing (command contains an embedded newline)'
9496 fi
9497
9498 if test -n "$at_trace_this"; then
9499     ( $at_traceon;
9500 mkdir ustar
9501 (cd ustar
9502 TEST_TAR_FORMAT=ustar
9503 export TEST_TAR_FORMAT
9504 TAR_OPTIONS="-H ustar"
9505 export TAR_OPTIONS
9506 rm -rf *
9507
9508
9509 # Force umask
9510 umask 022
9511
9512 # Make sure user's umask is honored, even if we are superuser
9513 TAR_OPTIONS="$TAR_OPTIONS --no-same-permissions"
9514
9515 # Create a directory
9516 mkdir directory
9517 chmod 777 directory
9518 genfile --stat=mode:777 directory
9519
9520 # Archive it
9521 tar cf arc directory
9522
9523 # Change its permissions ...
9524 chmod 755 directory
9525 genfile --stat=mode:777 directory
9526
9527 # ... and attempt to restore it twice
9528 tar xf arc directory
9529 genfile --stat=mode:777 directory
9530
9531 tar xf arc directory
9532 genfile --stat=mode:777 directory
9533
9534 # After both restores, the directory mode should be 755
9535 ) ) >"$at_stdout" 2>"$at_stder1"
9536     at_status=$?
9537     grep '^ *+' "$at_stder1" >&2
9538     grep -v '^ *+' "$at_stder1" >"$at_stderr"
9539 else
9540     ( :;
9541 mkdir ustar
9542 (cd ustar
9543 TEST_TAR_FORMAT=ustar
9544 export TEST_TAR_FORMAT
9545 TAR_OPTIONS="-H ustar"
9546 export TAR_OPTIONS
9547 rm -rf *
9548
9549
9550 # Force umask
9551 umask 022
9552
9553 # Make sure user's umask is honored, even if we are superuser
9554 TAR_OPTIONS="$TAR_OPTIONS --no-same-permissions"
9555
9556 # Create a directory
9557 mkdir directory
9558 chmod 777 directory
9559 genfile --stat=mode:777 directory
9560
9561 # Archive it
9562 tar cf arc directory
9563
9564 # Change its permissions ...
9565 chmod 755 directory
9566 genfile --stat=mode:777 directory
9567
9568 # ... and attempt to restore it twice
9569 tar xf arc directory
9570 genfile --stat=mode:777 directory
9571
9572 tar xf arc directory
9573 genfile --stat=mode:777 directory
9574
9575 # After both restores, the directory mode should be 755
9576 ) ) >"$at_stdout" 2>"$at_stderr"
9577     at_status=$?
9578 fi
9579
9580 at_failed=false
9581 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
9582 echo >>"$at_stdout"; echo "777
9583 755
9584 755
9585 755
9586 " | $at_diff - "$at_stdout" || at_failed=:
9587 case $at_status in
9588    77) echo 77 > "$at_status_file"; exit 77;;
9589    0) ;;
9590    *) echo "$at_srcdir/extrac06.at:36: exit code was $at_status, expected 0"
9591       at_failed=:;;
9592 esac
9593 if $at_failed; then
9594
9595
9596   echo 1 > "$at_status_file"
9597   exit 1
9598 fi
9599
9600 $at_traceon
9601 $at_traceoff
9602 echo "$at_srcdir/extrac06.at:36:
9603 mkdir posix
9604 (cd posix
9605 TEST_TAR_FORMAT=posix
9606 export TEST_TAR_FORMAT
9607 TAR_OPTIONS=\"-H posix\"
9608 export TAR_OPTIONS
9609 rm -rf *
9610
9611
9612 # Force umask
9613 umask 022
9614
9615 # Make sure user's umask is honored, even if we are superuser
9616 TAR_OPTIONS=\"\$TAR_OPTIONS --no-same-permissions\"
9617
9618 # Create a directory
9619 mkdir directory
9620 chmod 777 directory
9621 genfile --stat=mode:777 directory
9622
9623 # Archive it
9624 tar cf arc directory
9625
9626 # Change its permissions ...
9627 chmod 755 directory
9628 genfile --stat=mode:777 directory
9629
9630 # ... and attempt to restore it twice
9631 tar xf arc directory
9632 genfile --stat=mode:777 directory
9633
9634 tar xf arc directory
9635 genfile --stat=mode:777 directory
9636
9637 # After both restores, the directory mode should be 755
9638 )"
9639 echo extrac06.at:36 >"$at_check_line_file"
9640
9641 at_trace_this=
9642 if test -n "$at_traceon"; then
9643     echo 'Not enabling shell tracing (command contains an embedded newline)'
9644 fi
9645
9646 if test -n "$at_trace_this"; then
9647     ( $at_traceon;
9648 mkdir posix
9649 (cd posix
9650 TEST_TAR_FORMAT=posix
9651 export TEST_TAR_FORMAT
9652 TAR_OPTIONS="-H posix"
9653 export TAR_OPTIONS
9654 rm -rf *
9655
9656
9657 # Force umask
9658 umask 022
9659
9660 # Make sure user's umask is honored, even if we are superuser
9661 TAR_OPTIONS="$TAR_OPTIONS --no-same-permissions"
9662
9663 # Create a directory
9664 mkdir directory
9665 chmod 777 directory
9666 genfile --stat=mode:777 directory
9667
9668 # Archive it
9669 tar cf arc directory
9670
9671 # Change its permissions ...
9672 chmod 755 directory
9673 genfile --stat=mode:777 directory
9674
9675 # ... and attempt to restore it twice
9676 tar xf arc directory
9677 genfile --stat=mode:777 directory
9678
9679 tar xf arc directory
9680 genfile --stat=mode:777 directory
9681
9682 # After both restores, the directory mode should be 755
9683 ) ) >"$at_stdout" 2>"$at_stder1"
9684     at_status=$?
9685     grep '^ *+' "$at_stder1" >&2
9686     grep -v '^ *+' "$at_stder1" >"$at_stderr"
9687 else
9688     ( :;
9689 mkdir posix
9690 (cd posix
9691 TEST_TAR_FORMAT=posix
9692 export TEST_TAR_FORMAT
9693 TAR_OPTIONS="-H posix"
9694 export TAR_OPTIONS
9695 rm -rf *
9696
9697
9698 # Force umask
9699 umask 022
9700
9701 # Make sure user's umask is honored, even if we are superuser
9702 TAR_OPTIONS="$TAR_OPTIONS --no-same-permissions"
9703
9704 # Create a directory
9705 mkdir directory
9706 chmod 777 directory
9707 genfile --stat=mode:777 directory
9708
9709 # Archive it
9710 tar cf arc directory
9711
9712 # Change its permissions ...
9713 chmod 755 directory
9714 genfile --stat=mode:777 directory
9715
9716 # ... and attempt to restore it twice
9717 tar xf arc directory
9718 genfile --stat=mode:777 directory
9719
9720 tar xf arc directory
9721 genfile --stat=mode:777 directory
9722
9723 # After both restores, the directory mode should be 755
9724 ) ) >"$at_stdout" 2>"$at_stderr"
9725     at_status=$?
9726 fi
9727
9728 at_failed=false
9729 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
9730 echo >>"$at_stdout"; echo "777
9731 755
9732 755
9733 755
9734 " | $at_diff - "$at_stdout" || at_failed=:
9735 case $at_status in
9736    77) echo 77 > "$at_status_file"; exit 77;;
9737    0) ;;
9738    *) echo "$at_srcdir/extrac06.at:36: exit code was $at_status, expected 0"
9739       at_failed=:;;
9740 esac
9741 if $at_failed; then
9742
9743
9744   echo 1 > "$at_status_file"
9745   exit 1
9746 fi
9747
9748 $at_traceon
9749 $at_traceoff
9750 echo "$at_srcdir/extrac06.at:36:
9751 mkdir gnu
9752 (cd gnu
9753 TEST_TAR_FORMAT=gnu
9754 export TEST_TAR_FORMAT
9755 TAR_OPTIONS=\"-H gnu\"
9756 export TAR_OPTIONS
9757 rm -rf *
9758
9759
9760 # Force umask
9761 umask 022
9762
9763 # Make sure user's umask is honored, even if we are superuser
9764 TAR_OPTIONS=\"\$TAR_OPTIONS --no-same-permissions\"
9765
9766 # Create a directory
9767 mkdir directory
9768 chmod 777 directory
9769 genfile --stat=mode:777 directory
9770
9771 # Archive it
9772 tar cf arc directory
9773
9774 # Change its permissions ...
9775 chmod 755 directory
9776 genfile --stat=mode:777 directory
9777
9778 # ... and attempt to restore it twice
9779 tar xf arc directory
9780 genfile --stat=mode:777 directory
9781
9782 tar xf arc directory
9783 genfile --stat=mode:777 directory
9784
9785 # After both restores, the directory mode should be 755
9786 )"
9787 echo extrac06.at:36 >"$at_check_line_file"
9788
9789 at_trace_this=
9790 if test -n "$at_traceon"; then
9791     echo 'Not enabling shell tracing (command contains an embedded newline)'
9792 fi
9793
9794 if test -n "$at_trace_this"; then
9795     ( $at_traceon;
9796 mkdir gnu
9797 (cd gnu
9798 TEST_TAR_FORMAT=gnu
9799 export TEST_TAR_FORMAT
9800 TAR_OPTIONS="-H gnu"
9801 export TAR_OPTIONS
9802 rm -rf *
9803
9804
9805 # Force umask
9806 umask 022
9807
9808 # Make sure user's umask is honored, even if we are superuser
9809 TAR_OPTIONS="$TAR_OPTIONS --no-same-permissions"
9810
9811 # Create a directory
9812 mkdir directory
9813 chmod 777 directory
9814 genfile --stat=mode:777 directory
9815
9816 # Archive it
9817 tar cf arc directory
9818
9819 # Change its permissions ...
9820 chmod 755 directory
9821 genfile --stat=mode:777 directory
9822
9823 # ... and attempt to restore it twice
9824 tar xf arc directory
9825 genfile --stat=mode:777 directory
9826
9827 tar xf arc directory
9828 genfile --stat=mode:777 directory
9829
9830 # After both restores, the directory mode should be 755
9831 ) ) >"$at_stdout" 2>"$at_stder1"
9832     at_status=$?
9833     grep '^ *+' "$at_stder1" >&2
9834     grep -v '^ *+' "$at_stder1" >"$at_stderr"
9835 else
9836     ( :;
9837 mkdir gnu
9838 (cd gnu
9839 TEST_TAR_FORMAT=gnu
9840 export TEST_TAR_FORMAT
9841 TAR_OPTIONS="-H gnu"
9842 export TAR_OPTIONS
9843 rm -rf *
9844
9845
9846 # Force umask
9847 umask 022
9848
9849 # Make sure user's umask is honored, even if we are superuser
9850 TAR_OPTIONS="$TAR_OPTIONS --no-same-permissions"
9851
9852 # Create a directory
9853 mkdir directory
9854 chmod 777 directory
9855 genfile --stat=mode:777 directory
9856
9857 # Archive it
9858 tar cf arc directory
9859
9860 # Change its permissions ...
9861 chmod 755 directory
9862 genfile --stat=mode:777 directory
9863
9864 # ... and attempt to restore it twice
9865 tar xf arc directory
9866 genfile --stat=mode:777 directory
9867
9868 tar xf arc directory
9869 genfile --stat=mode:777 directory
9870
9871 # After both restores, the directory mode should be 755
9872 ) ) >"$at_stdout" 2>"$at_stderr"
9873     at_status=$?
9874 fi
9875
9876 at_failed=false
9877 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
9878 echo >>"$at_stdout"; echo "777
9879 755
9880 755
9881 755
9882 " | $at_diff - "$at_stdout" || at_failed=:
9883 case $at_status in
9884    77) echo 77 > "$at_status_file"; exit 77;;
9885    0) ;;
9886    *) echo "$at_srcdir/extrac06.at:36: exit code was $at_status, expected 0"
9887       at_failed=:;;
9888 esac
9889 if $at_failed; then
9890
9891
9892   echo 1 > "$at_status_file"
9893   exit 1
9894 fi
9895
9896 $at_traceon
9897
9898
9899
9900       $at_traceoff
9901       $at_times_p && times >"$at_times_file"
9902     ) 5>&1 2>&1 | eval $at_tee_pipe
9903     at_status=`cat "$at_status_file"`
9904     ;;
9905
9906   24 ) # 24. extrac07.at:27: extracting symlinks to a read-only dir
9907     at_setup_line='extrac07.at:27'
9908     at_desc="extracting symlinks to a read-only dir"
9909     $at_quiet $ECHO_N " 24: extracting symlinks to a read-only dir         $ECHO_C"
9910     at_xfail=no
9911       test -f $XFAILFILE && at_xfail=yes
9912     echo "#                             -*- compilation -*-" >> "$at_group_log"
9913     (
9914       echo "24. extrac07.at:27: testing ..."
9915       $at_traceon
9916
9917
9918
9919
9920
9921   $at_traceoff
9922 echo "$at_srcdir/extrac07.at:30:
9923 mkdir v7
9924 (cd v7
9925 TEST_TAR_FORMAT=v7
9926 export TEST_TAR_FORMAT
9927 TAR_OPTIONS=\"-H v7\"
9928 export TAR_OPTIONS
9929 rm -rf *
9930
9931 echo Prepare the directory
9932 mkdir dir
9933 genfile -f foo
9934 cd dir
9935 ln -s ../foo .
9936 cd ..
9937 chmod -w dir
9938
9939 echo Create the archive
9940 tar cf archive dir || exit 1
9941
9942 chmod +w dir
9943
9944 echo Extract
9945 mkdir out
9946 tar -C out -xvf archive
9947 )"
9948 echo extrac07.at:30 >"$at_check_line_file"
9949
9950 at_trace_this=
9951 if test -n "$at_traceon"; then
9952     echo 'Not enabling shell tracing (command contains an embedded newline)'
9953 fi
9954
9955 if test -n "$at_trace_this"; then
9956     ( $at_traceon;
9957 mkdir v7
9958 (cd v7
9959 TEST_TAR_FORMAT=v7
9960 export TEST_TAR_FORMAT
9961 TAR_OPTIONS="-H v7"
9962 export TAR_OPTIONS
9963 rm -rf *
9964
9965 echo Prepare the directory
9966 mkdir dir
9967 genfile -f foo
9968 cd dir
9969 ln -s ../foo .
9970 cd ..
9971 chmod -w dir
9972
9973 echo Create the archive
9974 tar cf archive dir || exit 1
9975
9976 chmod +w dir
9977
9978 echo Extract
9979 mkdir out
9980 tar -C out -xvf archive
9981 ) ) >"$at_stdout" 2>"$at_stder1"
9982     at_status=$?
9983     grep '^ *+' "$at_stder1" >&2
9984     grep -v '^ *+' "$at_stder1" >"$at_stderr"
9985 else
9986     ( :;
9987 mkdir v7
9988 (cd v7
9989 TEST_TAR_FORMAT=v7
9990 export TEST_TAR_FORMAT
9991 TAR_OPTIONS="-H v7"
9992 export TAR_OPTIONS
9993 rm -rf *
9994
9995 echo Prepare the directory
9996 mkdir dir
9997 genfile -f foo
9998 cd dir
9999 ln -s ../foo .
10000 cd ..
10001 chmod -w dir
10002
10003 echo Create the archive
10004 tar cf archive dir || exit 1
10005
10006 chmod +w dir
10007
10008 echo Extract
10009 mkdir out
10010 tar -C out -xvf archive
10011 ) ) >"$at_stdout" 2>"$at_stderr"
10012     at_status=$?
10013 fi
10014
10015 at_failed=false
10016 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
10017 echo >>"$at_stdout"; echo "Prepare the directory
10018 Create the archive
10019 Extract
10020 dir/
10021 dir/foo
10022 " | $at_diff - "$at_stdout" || at_failed=:
10023 case $at_status in
10024    77) echo 77 > "$at_status_file"; exit 77;;
10025    0) ;;
10026    *) echo "$at_srcdir/extrac07.at:30: exit code was $at_status, expected 0"
10027       at_failed=:;;
10028 esac
10029 if $at_failed; then
10030
10031
10032   echo 1 > "$at_status_file"
10033   exit 1
10034 else
10035   ustar
10036 fi
10037
10038 $at_traceon
10039 $at_traceoff
10040 echo "$at_srcdir/extrac07.at:30:
10041 mkdir oldgnu
10042 (cd oldgnu
10043 TEST_TAR_FORMAT=oldgnu
10044 export TEST_TAR_FORMAT
10045 TAR_OPTIONS=\"-H oldgnu\"
10046 export TAR_OPTIONS
10047 rm -rf *
10048
10049 echo Prepare the directory
10050 mkdir dir
10051 genfile -f foo
10052 cd dir
10053 ln -s ../foo .
10054 cd ..
10055 chmod -w dir
10056
10057 echo Create the archive
10058 tar cf archive dir || exit 1
10059
10060 chmod +w dir
10061
10062 echo Extract
10063 mkdir out
10064 tar -C out -xvf archive
10065 )"
10066 echo extrac07.at:30 >"$at_check_line_file"
10067
10068 at_trace_this=
10069 if test -n "$at_traceon"; then
10070     echo 'Not enabling shell tracing (command contains an embedded newline)'
10071 fi
10072
10073 if test -n "$at_trace_this"; then
10074     ( $at_traceon;
10075 mkdir oldgnu
10076 (cd oldgnu
10077 TEST_TAR_FORMAT=oldgnu
10078 export TEST_TAR_FORMAT
10079 TAR_OPTIONS="-H oldgnu"
10080 export TAR_OPTIONS
10081 rm -rf *
10082
10083 echo Prepare the directory
10084 mkdir dir
10085 genfile -f foo
10086 cd dir
10087 ln -s ../foo .
10088 cd ..
10089 chmod -w dir
10090
10091 echo Create the archive
10092 tar cf archive dir || exit 1
10093
10094 chmod +w dir
10095
10096 echo Extract
10097 mkdir out
10098 tar -C out -xvf archive
10099 ) ) >"$at_stdout" 2>"$at_stder1"
10100     at_status=$?
10101     grep '^ *+' "$at_stder1" >&2
10102     grep -v '^ *+' "$at_stder1" >"$at_stderr"
10103 else
10104     ( :;
10105 mkdir oldgnu
10106 (cd oldgnu
10107 TEST_TAR_FORMAT=oldgnu
10108 export TEST_TAR_FORMAT
10109 TAR_OPTIONS="-H oldgnu"
10110 export TAR_OPTIONS
10111 rm -rf *
10112
10113 echo Prepare the directory
10114 mkdir dir
10115 genfile -f foo
10116 cd dir
10117 ln -s ../foo .
10118 cd ..
10119 chmod -w dir
10120
10121 echo Create the archive
10122 tar cf archive dir || exit 1
10123
10124 chmod +w dir
10125
10126 echo Extract
10127 mkdir out
10128 tar -C out -xvf archive
10129 ) ) >"$at_stdout" 2>"$at_stderr"
10130     at_status=$?
10131 fi
10132
10133 at_failed=false
10134 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
10135 echo >>"$at_stdout"; echo "Prepare the directory
10136 Create the archive
10137 Extract
10138 dir/
10139 dir/foo
10140 " | $at_diff - "$at_stdout" || at_failed=:
10141 case $at_status in
10142    77) echo 77 > "$at_status_file"; exit 77;;
10143    0) ;;
10144    *) echo "$at_srcdir/extrac07.at:30: exit code was $at_status, expected 0"
10145       at_failed=:;;
10146 esac
10147 if $at_failed; then
10148
10149
10150   echo 1 > "$at_status_file"
10151   exit 1
10152 else
10153   ustar
10154 fi
10155
10156 $at_traceon
10157 $at_traceoff
10158 echo "$at_srcdir/extrac07.at:30:
10159 mkdir ustar
10160 (cd ustar
10161 TEST_TAR_FORMAT=ustar
10162 export TEST_TAR_FORMAT
10163 TAR_OPTIONS=\"-H ustar\"
10164 export TAR_OPTIONS
10165 rm -rf *
10166
10167 echo Prepare the directory
10168 mkdir dir
10169 genfile -f foo
10170 cd dir
10171 ln -s ../foo .
10172 cd ..
10173 chmod -w dir
10174
10175 echo Create the archive
10176 tar cf archive dir || exit 1
10177
10178 chmod +w dir
10179
10180 echo Extract
10181 mkdir out
10182 tar -C out -xvf archive
10183 )"
10184 echo extrac07.at:30 >"$at_check_line_file"
10185
10186 at_trace_this=
10187 if test -n "$at_traceon"; then
10188     echo 'Not enabling shell tracing (command contains an embedded newline)'
10189 fi
10190
10191 if test -n "$at_trace_this"; then
10192     ( $at_traceon;
10193 mkdir ustar
10194 (cd ustar
10195 TEST_TAR_FORMAT=ustar
10196 export TEST_TAR_FORMAT
10197 TAR_OPTIONS="-H ustar"
10198 export TAR_OPTIONS
10199 rm -rf *
10200
10201 echo Prepare the directory
10202 mkdir dir
10203 genfile -f foo
10204 cd dir
10205 ln -s ../foo .
10206 cd ..
10207 chmod -w dir
10208
10209 echo Create the archive
10210 tar cf archive dir || exit 1
10211
10212 chmod +w dir
10213
10214 echo Extract
10215 mkdir out
10216 tar -C out -xvf archive
10217 ) ) >"$at_stdout" 2>"$at_stder1"
10218     at_status=$?
10219     grep '^ *+' "$at_stder1" >&2
10220     grep -v '^ *+' "$at_stder1" >"$at_stderr"
10221 else
10222     ( :;
10223 mkdir ustar
10224 (cd ustar
10225 TEST_TAR_FORMAT=ustar
10226 export TEST_TAR_FORMAT
10227 TAR_OPTIONS="-H ustar"
10228 export TAR_OPTIONS
10229 rm -rf *
10230
10231 echo Prepare the directory
10232 mkdir dir
10233 genfile -f foo
10234 cd dir
10235 ln -s ../foo .
10236 cd ..
10237 chmod -w dir
10238
10239 echo Create the archive
10240 tar cf archive dir || exit 1
10241
10242 chmod +w dir
10243
10244 echo Extract
10245 mkdir out
10246 tar -C out -xvf archive
10247 ) ) >"$at_stdout" 2>"$at_stderr"
10248     at_status=$?
10249 fi
10250
10251 at_failed=false
10252 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
10253 echo >>"$at_stdout"; echo "Prepare the directory
10254 Create the archive
10255 Extract
10256 dir/
10257 dir/foo
10258 " | $at_diff - "$at_stdout" || at_failed=:
10259 case $at_status in
10260    77) echo 77 > "$at_status_file"; exit 77;;
10261    0) ;;
10262    *) echo "$at_srcdir/extrac07.at:30: exit code was $at_status, expected 0"
10263       at_failed=:;;
10264 esac
10265 if $at_failed; then
10266
10267
10268   echo 1 > "$at_status_file"
10269   exit 1
10270 else
10271   ustar
10272 fi
10273
10274 $at_traceon
10275 $at_traceoff
10276 echo "$at_srcdir/extrac07.at:30:
10277 mkdir posix
10278 (cd posix
10279 TEST_TAR_FORMAT=posix
10280 export TEST_TAR_FORMAT
10281 TAR_OPTIONS=\"-H posix\"
10282 export TAR_OPTIONS
10283 rm -rf *
10284
10285 echo Prepare the directory
10286 mkdir dir
10287 genfile -f foo
10288 cd dir
10289 ln -s ../foo .
10290 cd ..
10291 chmod -w dir
10292
10293 echo Create the archive
10294 tar cf archive dir || exit 1
10295
10296 chmod +w dir
10297
10298 echo Extract
10299 mkdir out
10300 tar -C out -xvf archive
10301 )"
10302 echo extrac07.at:30 >"$at_check_line_file"
10303
10304 at_trace_this=
10305 if test -n "$at_traceon"; then
10306     echo 'Not enabling shell tracing (command contains an embedded newline)'
10307 fi
10308
10309 if test -n "$at_trace_this"; then
10310     ( $at_traceon;
10311 mkdir posix
10312 (cd posix
10313 TEST_TAR_FORMAT=posix
10314 export TEST_TAR_FORMAT
10315 TAR_OPTIONS="-H posix"
10316 export TAR_OPTIONS
10317 rm -rf *
10318
10319 echo Prepare the directory
10320 mkdir dir
10321 genfile -f foo
10322 cd dir
10323 ln -s ../foo .
10324 cd ..
10325 chmod -w dir
10326
10327 echo Create the archive
10328 tar cf archive dir || exit 1
10329
10330 chmod +w dir
10331
10332 echo Extract
10333 mkdir out
10334 tar -C out -xvf archive
10335 ) ) >"$at_stdout" 2>"$at_stder1"
10336     at_status=$?
10337     grep '^ *+' "$at_stder1" >&2
10338     grep -v '^ *+' "$at_stder1" >"$at_stderr"
10339 else
10340     ( :;
10341 mkdir posix
10342 (cd posix
10343 TEST_TAR_FORMAT=posix
10344 export TEST_TAR_FORMAT
10345 TAR_OPTIONS="-H posix"
10346 export TAR_OPTIONS
10347 rm -rf *
10348
10349 echo Prepare the directory
10350 mkdir dir
10351 genfile -f foo
10352 cd dir
10353 ln -s ../foo .
10354 cd ..
10355 chmod -w dir
10356
10357 echo Create the archive
10358 tar cf archive dir || exit 1
10359
10360 chmod +w dir
10361
10362 echo Extract
10363 mkdir out
10364 tar -C out -xvf archive
10365 ) ) >"$at_stdout" 2>"$at_stderr"
10366     at_status=$?
10367 fi
10368
10369 at_failed=false
10370 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
10371 echo >>"$at_stdout"; echo "Prepare the directory
10372 Create the archive
10373 Extract
10374 dir/
10375 dir/foo
10376 " | $at_diff - "$at_stdout" || at_failed=:
10377 case $at_status in
10378    77) echo 77 > "$at_status_file"; exit 77;;
10379    0) ;;
10380    *) echo "$at_srcdir/extrac07.at:30: exit code was $at_status, expected 0"
10381       at_failed=:;;
10382 esac
10383 if $at_failed; then
10384
10385
10386   echo 1 > "$at_status_file"
10387   exit 1
10388 else
10389   ustar
10390 fi
10391
10392 $at_traceon
10393 $at_traceoff
10394 echo "$at_srcdir/extrac07.at:30:
10395 mkdir gnu
10396 (cd gnu
10397 TEST_TAR_FORMAT=gnu
10398 export TEST_TAR_FORMAT
10399 TAR_OPTIONS=\"-H gnu\"
10400 export TAR_OPTIONS
10401 rm -rf *
10402
10403 echo Prepare the directory
10404 mkdir dir
10405 genfile -f foo
10406 cd dir
10407 ln -s ../foo .
10408 cd ..
10409 chmod -w dir
10410
10411 echo Create the archive
10412 tar cf archive dir || exit 1
10413
10414 chmod +w dir
10415
10416 echo Extract
10417 mkdir out
10418 tar -C out -xvf archive
10419 )"
10420 echo extrac07.at:30 >"$at_check_line_file"
10421
10422 at_trace_this=
10423 if test -n "$at_traceon"; then
10424     echo 'Not enabling shell tracing (command contains an embedded newline)'
10425 fi
10426
10427 if test -n "$at_trace_this"; then
10428     ( $at_traceon;
10429 mkdir gnu
10430 (cd gnu
10431 TEST_TAR_FORMAT=gnu
10432 export TEST_TAR_FORMAT
10433 TAR_OPTIONS="-H gnu"
10434 export TAR_OPTIONS
10435 rm -rf *
10436
10437 echo Prepare the directory
10438 mkdir dir
10439 genfile -f foo
10440 cd dir
10441 ln -s ../foo .
10442 cd ..
10443 chmod -w dir
10444
10445 echo Create the archive
10446 tar cf archive dir || exit 1
10447
10448 chmod +w dir
10449
10450 echo Extract
10451 mkdir out
10452 tar -C out -xvf archive
10453 ) ) >"$at_stdout" 2>"$at_stder1"
10454     at_status=$?
10455     grep '^ *+' "$at_stder1" >&2
10456     grep -v '^ *+' "$at_stder1" >"$at_stderr"
10457 else
10458     ( :;
10459 mkdir gnu
10460 (cd gnu
10461 TEST_TAR_FORMAT=gnu
10462 export TEST_TAR_FORMAT
10463 TAR_OPTIONS="-H gnu"
10464 export TAR_OPTIONS
10465 rm -rf *
10466
10467 echo Prepare the directory
10468 mkdir dir
10469 genfile -f foo
10470 cd dir
10471 ln -s ../foo .
10472 cd ..
10473 chmod -w dir
10474
10475 echo Create the archive
10476 tar cf archive dir || exit 1
10477
10478 chmod +w dir
10479
10480 echo Extract
10481 mkdir out
10482 tar -C out -xvf archive
10483 ) ) >"$at_stdout" 2>"$at_stderr"
10484     at_status=$?
10485 fi
10486
10487 at_failed=false
10488 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
10489 echo >>"$at_stdout"; echo "Prepare the directory
10490 Create the archive
10491 Extract
10492 dir/
10493 dir/foo
10494 " | $at_diff - "$at_stdout" || at_failed=:
10495 case $at_status in
10496    77) echo 77 > "$at_status_file"; exit 77;;
10497    0) ;;
10498    *) echo "$at_srcdir/extrac07.at:30: exit code was $at_status, expected 0"
10499       at_failed=:;;
10500 esac
10501 if $at_failed; then
10502
10503
10504   echo 1 > "$at_status_file"
10505   exit 1
10506 else
10507   ustar
10508 fi
10509
10510 $at_traceon
10511
10512  # Testing one format is enough
10513
10514       $at_traceoff
10515       $at_times_p && times >"$at_times_file"
10516     ) 5>&1 2>&1 | eval $at_tee_pipe
10517     at_status=`cat "$at_status_file"`
10518     ;;
10519
10520   25 ) # 25. gzip.at:23: gzip
10521     at_setup_line='gzip.at:23'
10522     at_desc="gzip"
10523     $at_quiet $ECHO_N " 25: gzip                                           $ECHO_C"
10524     at_xfail=no
10525     echo "#                             -*- compilation -*-" >> "$at_group_log"
10526     (
10527       echo "25. gzip.at:23: testing ..."
10528       $at_traceon
10529
10530
10531
10532 unset TAR_OPTIONS
10533
10534 $at_traceoff
10535 echo "$at_srcdir/gzip.at:28:
10536
10537 cat /dev/null | gzip - > /dev/null 2>&1 || exit 77
10538
10539 tar xfvz /dev/null
10540 test \$? = 2 || exit 1
10541 "
10542 echo gzip.at:28 >"$at_check_line_file"
10543
10544 at_trace_this=
10545 if test -n "$at_traceon"; then
10546     echo 'Not enabling shell tracing (command contains an embedded newline)'
10547 fi
10548
10549 if test -n "$at_trace_this"; then
10550     ( $at_traceon;
10551
10552 cat /dev/null | gzip - > /dev/null 2>&1 || exit 77
10553
10554 tar xfvz /dev/null
10555 test $? = 2 || exit 1
10556  ) >"$at_stdout" 2>"$at_stder1"
10557     at_status=$?
10558     grep '^ *+' "$at_stder1" >&2
10559     grep -v '^ *+' "$at_stder1" >"$at_stderr"
10560 else
10561     ( :;
10562
10563 cat /dev/null | gzip - > /dev/null 2>&1 || exit 77
10564
10565 tar xfvz /dev/null
10566 test $? = 2 || exit 1
10567  ) >"$at_stdout" 2>"$at_stderr"
10568     at_status=$?
10569 fi
10570
10571 at_failed=false
10572 echo >>"$at_stderr"; echo "
10573 gzip: stdin: unexpected end of file
10574 tar: Child returned status 1
10575 tar: Exiting with failure status due to previous errors
10576 " | $at_diff - "$at_stderr" || at_failed=:
10577 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
10578 case $at_status in
10579    77) echo 77 > "$at_status_file"; exit 77;;
10580    0) ;;
10581    *) echo "$at_srcdir/gzip.at:28: exit code was $at_status, expected 0"
10582       at_failed=:;;
10583 esac
10584 if $at_failed; then
10585
10586
10587   echo 1 > "$at_status_file"
10588   exit 1
10589 fi
10590
10591 $at_traceon
10592
10593
10594       $at_traceoff
10595       $at_times_p && times >"$at_times_file"
10596     ) 5>&1 2>&1 | eval $at_tee_pipe
10597     at_status=`cat "$at_status_file"`
10598     ;;
10599
10600   26 ) # 26. incremental.at:23: incremental
10601     at_setup_line='incremental.at:23'
10602     at_desc="incremental"
10603     $at_quiet $ECHO_N " 26: incremental                                    $ECHO_C"
10604     at_xfail=no
10605       test -f $XFAILFILE && at_xfail=yes
10606     echo "#                             -*- compilation -*-" >> "$at_group_log"
10607     (
10608       echo "26. incremental.at:23: testing ..."
10609       $at_traceon
10610
10611
10612
10613
10614
10615   $at_traceoff
10616 echo "$at_srcdir/incremental.at:26:
10617 mkdir gnu
10618 (cd gnu
10619 TEST_TAR_FORMAT=gnu
10620 export TEST_TAR_FORMAT
10621 TAR_OPTIONS=\"-H gnu\"
10622 export TAR_OPTIONS
10623 rm -rf *
10624
10625 mkdir structure
10626 echo x >structure/file
10627
10628 # On Nextstep (and perhaps other 4.3BSD systems),
10629 # a newly created file's ctime isn't updated
10630 # until the next sync or stat operation on the file.
10631 ls -l structure/file >/dev/null
10632
10633 # If the time of an initial backup and the creation time of a file contained
10634 # in that backup are the same, the file will be backed up again when an
10635 # incremental backup is done, because the incremental backup backs up
10636 # files created \`on or after' the initial backup time.  Without the sleep
10637 # command, behaviour of tar becomes variable, depending whether the system
10638 # clock ticked over to the next second between creating the file and
10639 # backing it up.
10640 sleep 1
10641
10642 tar cf archive --listed=list structure
10643 tar cfv archive --listed=list structure
10644 echo separator
10645 # ReiserFS often offsets the timestamps of newly created files
10646 # 1 second to the past.  Try to compensate for it, until a better
10647 # solution is found.
10648 sleep 2
10649 echo y >structure/file
10650 tar cfv archive --listed=list structure
10651 )"
10652 echo incremental.at:26 >"$at_check_line_file"
10653
10654 at_trace_this=
10655 if test -n "$at_traceon"; then
10656     echo 'Not enabling shell tracing (command contains an embedded newline)'
10657 fi
10658
10659 if test -n "$at_trace_this"; then
10660     ( $at_traceon;
10661 mkdir gnu
10662 (cd gnu
10663 TEST_TAR_FORMAT=gnu
10664 export TEST_TAR_FORMAT
10665 TAR_OPTIONS="-H gnu"
10666 export TAR_OPTIONS
10667 rm -rf *
10668
10669 mkdir structure
10670 echo x >structure/file
10671
10672 # On Nextstep (and perhaps other 4.3BSD systems),
10673 # a newly created file's ctime isn't updated
10674 # until the next sync or stat operation on the file.
10675 ls -l structure/file >/dev/null
10676
10677 # If the time of an initial backup and the creation time of a file contained
10678 # in that backup are the same, the file will be backed up again when an
10679 # incremental backup is done, because the incremental backup backs up
10680 # files created `on or after' the initial backup time.  Without the sleep
10681 # command, behaviour of tar becomes variable, depending whether the system
10682 # clock ticked over to the next second between creating the file and
10683 # backing it up.
10684 sleep 1
10685
10686 tar cf archive --listed=list structure
10687 tar cfv archive --listed=list structure
10688 echo separator
10689 # ReiserFS often offsets the timestamps of newly created files
10690 # 1 second to the past.  Try to compensate for it, until a better
10691 # solution is found.
10692 sleep 2
10693 echo y >structure/file
10694 tar cfv archive --listed=list structure
10695 ) ) >"$at_stdout" 2>"$at_stder1"
10696     at_status=$?
10697     grep '^ *+' "$at_stder1" >&2
10698     grep -v '^ *+' "$at_stder1" >"$at_stderr"
10699 else
10700     ( :;
10701 mkdir gnu
10702 (cd gnu
10703 TEST_TAR_FORMAT=gnu
10704 export TEST_TAR_FORMAT
10705 TAR_OPTIONS="-H gnu"
10706 export TAR_OPTIONS
10707 rm -rf *
10708
10709 mkdir structure
10710 echo x >structure/file
10711
10712 # On Nextstep (and perhaps other 4.3BSD systems),
10713 # a newly created file's ctime isn't updated
10714 # until the next sync or stat operation on the file.
10715 ls -l structure/file >/dev/null
10716
10717 # If the time of an initial backup and the creation time of a file contained
10718 # in that backup are the same, the file will be backed up again when an
10719 # incremental backup is done, because the incremental backup backs up
10720 # files created `on or after' the initial backup time.  Without the sleep
10721 # command, behaviour of tar becomes variable, depending whether the system
10722 # clock ticked over to the next second between creating the file and
10723 # backing it up.
10724 sleep 1
10725
10726 tar cf archive --listed=list structure
10727 tar cfv archive --listed=list structure
10728 echo separator
10729 # ReiserFS often offsets the timestamps of newly created files
10730 # 1 second to the past.  Try to compensate for it, until a better
10731 # solution is found.
10732 sleep 2
10733 echo y >structure/file
10734 tar cfv archive --listed=list structure
10735 ) ) >"$at_stdout" 2>"$at_stderr"
10736     at_status=$?
10737 fi
10738
10739 at_failed=false
10740 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
10741 echo >>"$at_stdout"; echo "structure/
10742 separator
10743 structure/
10744 structure/file
10745 " | $at_diff - "$at_stdout" || at_failed=:
10746 case $at_status in
10747    77) echo 77 > "$at_status_file"; exit 77;;
10748    0) ;;
10749    *) echo "$at_srcdir/incremental.at:26: exit code was $at_status, expected 0"
10750       at_failed=:;;
10751 esac
10752 if $at_failed; then
10753
10754
10755   echo 1 > "$at_status_file"
10756   exit 1
10757 fi
10758
10759 $at_traceon
10760 $at_traceoff
10761 echo "$at_srcdir/incremental.at:26:
10762 mkdir oldgnu
10763 (cd oldgnu
10764 TEST_TAR_FORMAT=oldgnu
10765 export TEST_TAR_FORMAT
10766 TAR_OPTIONS=\"-H oldgnu\"
10767 export TAR_OPTIONS
10768 rm -rf *
10769
10770 mkdir structure
10771 echo x >structure/file
10772
10773 # On Nextstep (and perhaps other 4.3BSD systems),
10774 # a newly created file's ctime isn't updated
10775 # until the next sync or stat operation on the file.
10776 ls -l structure/file >/dev/null
10777
10778 # If the time of an initial backup and the creation time of a file contained
10779 # in that backup are the same, the file will be backed up again when an
10780 # incremental backup is done, because the incremental backup backs up
10781 # files created \`on or after' the initial backup time.  Without the sleep
10782 # command, behaviour of tar becomes variable, depending whether the system
10783 # clock ticked over to the next second between creating the file and
10784 # backing it up.
10785 sleep 1
10786
10787 tar cf archive --listed=list structure
10788 tar cfv archive --listed=list structure
10789 echo separator
10790 # ReiserFS often offsets the timestamps of newly created files
10791 # 1 second to the past.  Try to compensate for it, until a better
10792 # solution is found.
10793 sleep 2
10794 echo y >structure/file
10795 tar cfv archive --listed=list structure
10796 )"
10797 echo incremental.at:26 >"$at_check_line_file"
10798
10799 at_trace_this=
10800 if test -n "$at_traceon"; then
10801     echo 'Not enabling shell tracing (command contains an embedded newline)'
10802 fi
10803
10804 if test -n "$at_trace_this"; then
10805     ( $at_traceon;
10806 mkdir oldgnu
10807 (cd oldgnu
10808 TEST_TAR_FORMAT=oldgnu
10809 export TEST_TAR_FORMAT
10810 TAR_OPTIONS="-H oldgnu"
10811 export TAR_OPTIONS
10812 rm -rf *
10813
10814 mkdir structure
10815 echo x >structure/file
10816
10817 # On Nextstep (and perhaps other 4.3BSD systems),
10818 # a newly created file's ctime isn't updated
10819 # until the next sync or stat operation on the file.
10820 ls -l structure/file >/dev/null
10821
10822 # If the time of an initial backup and the creation time of a file contained
10823 # in that backup are the same, the file will be backed up again when an
10824 # incremental backup is done, because the incremental backup backs up
10825 # files created `on or after' the initial backup time.  Without the sleep
10826 # command, behaviour of tar becomes variable, depending whether the system
10827 # clock ticked over to the next second between creating the file and
10828 # backing it up.
10829 sleep 1
10830
10831 tar cf archive --listed=list structure
10832 tar cfv archive --listed=list structure
10833 echo separator
10834 # ReiserFS often offsets the timestamps of newly created files
10835 # 1 second to the past.  Try to compensate for it, until a better
10836 # solution is found.
10837 sleep 2
10838 echo y >structure/file
10839 tar cfv archive --listed=list structure
10840 ) ) >"$at_stdout" 2>"$at_stder1"
10841     at_status=$?
10842     grep '^ *+' "$at_stder1" >&2
10843     grep -v '^ *+' "$at_stder1" >"$at_stderr"
10844 else
10845     ( :;
10846 mkdir oldgnu
10847 (cd oldgnu
10848 TEST_TAR_FORMAT=oldgnu
10849 export TEST_TAR_FORMAT
10850 TAR_OPTIONS="-H oldgnu"
10851 export TAR_OPTIONS
10852 rm -rf *
10853
10854 mkdir structure
10855 echo x >structure/file
10856
10857 # On Nextstep (and perhaps other 4.3BSD systems),
10858 # a newly created file's ctime isn't updated
10859 # until the next sync or stat operation on the file.
10860 ls -l structure/file >/dev/null
10861
10862 # If the time of an initial backup and the creation time of a file contained
10863 # in that backup are the same, the file will be backed up again when an
10864 # incremental backup is done, because the incremental backup backs up
10865 # files created `on or after' the initial backup time.  Without the sleep
10866 # command, behaviour of tar becomes variable, depending whether the system
10867 # clock ticked over to the next second between creating the file and
10868 # backing it up.
10869 sleep 1
10870
10871 tar cf archive --listed=list structure
10872 tar cfv archive --listed=list structure
10873 echo separator
10874 # ReiserFS often offsets the timestamps of newly created files
10875 # 1 second to the past.  Try to compensate for it, until a better
10876 # solution is found.
10877 sleep 2
10878 echo y >structure/file
10879 tar cfv archive --listed=list structure
10880 ) ) >"$at_stdout" 2>"$at_stderr"
10881     at_status=$?
10882 fi
10883
10884 at_failed=false
10885 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
10886 echo >>"$at_stdout"; echo "structure/
10887 separator
10888 structure/
10889 structure/file
10890 " | $at_diff - "$at_stdout" || at_failed=:
10891 case $at_status in
10892    77) echo 77 > "$at_status_file"; exit 77;;
10893    0) ;;
10894    *) echo "$at_srcdir/incremental.at:26: exit code was $at_status, expected 0"
10895       at_failed=:;;
10896 esac
10897 if $at_failed; then
10898
10899
10900   echo 1 > "$at_status_file"
10901   exit 1
10902 fi
10903
10904 $at_traceon
10905 $at_traceoff
10906 echo "$at_srcdir/incremental.at:26:
10907 mkdir posix
10908 (cd posix
10909 TEST_TAR_FORMAT=posix
10910 export TEST_TAR_FORMAT
10911 TAR_OPTIONS=\"-H posix\"
10912 export TAR_OPTIONS
10913 rm -rf *
10914
10915 mkdir structure
10916 echo x >structure/file
10917
10918 # On Nextstep (and perhaps other 4.3BSD systems),
10919 # a newly created file's ctime isn't updated
10920 # until the next sync or stat operation on the file.
10921 ls -l structure/file >/dev/null
10922
10923 # If the time of an initial backup and the creation time of a file contained
10924 # in that backup are the same, the file will be backed up again when an
10925 # incremental backup is done, because the incremental backup backs up
10926 # files created \`on or after' the initial backup time.  Without the sleep
10927 # command, behaviour of tar becomes variable, depending whether the system
10928 # clock ticked over to the next second between creating the file and
10929 # backing it up.
10930 sleep 1
10931
10932 tar cf archive --listed=list structure
10933 tar cfv archive --listed=list structure
10934 echo separator
10935 # ReiserFS often offsets the timestamps of newly created files
10936 # 1 second to the past.  Try to compensate for it, until a better
10937 # solution is found.
10938 sleep 2
10939 echo y >structure/file
10940 tar cfv archive --listed=list structure
10941 )"
10942 echo incremental.at:26 >"$at_check_line_file"
10943
10944 at_trace_this=
10945 if test -n "$at_traceon"; then
10946     echo 'Not enabling shell tracing (command contains an embedded newline)'
10947 fi
10948
10949 if test -n "$at_trace_this"; then
10950     ( $at_traceon;
10951 mkdir posix
10952 (cd posix
10953 TEST_TAR_FORMAT=posix
10954 export TEST_TAR_FORMAT
10955 TAR_OPTIONS="-H posix"
10956 export TAR_OPTIONS
10957 rm -rf *
10958
10959 mkdir structure
10960 echo x >structure/file
10961
10962 # On Nextstep (and perhaps other 4.3BSD systems),
10963 # a newly created file's ctime isn't updated
10964 # until the next sync or stat operation on the file.
10965 ls -l structure/file >/dev/null
10966
10967 # If the time of an initial backup and the creation time of a file contained
10968 # in that backup are the same, the file will be backed up again when an
10969 # incremental backup is done, because the incremental backup backs up
10970 # files created `on or after' the initial backup time.  Without the sleep
10971 # command, behaviour of tar becomes variable, depending whether the system
10972 # clock ticked over to the next second between creating the file and
10973 # backing it up.
10974 sleep 1
10975
10976 tar cf archive --listed=list structure
10977 tar cfv archive --listed=list structure
10978 echo separator
10979 # ReiserFS often offsets the timestamps of newly created files
10980 # 1 second to the past.  Try to compensate for it, until a better
10981 # solution is found.
10982 sleep 2
10983 echo y >structure/file
10984 tar cfv archive --listed=list structure
10985 ) ) >"$at_stdout" 2>"$at_stder1"
10986     at_status=$?
10987     grep '^ *+' "$at_stder1" >&2
10988     grep -v '^ *+' "$at_stder1" >"$at_stderr"
10989 else
10990     ( :;
10991 mkdir posix
10992 (cd posix
10993 TEST_TAR_FORMAT=posix
10994 export TEST_TAR_FORMAT
10995 TAR_OPTIONS="-H posix"
10996 export TAR_OPTIONS
10997 rm -rf *
10998
10999 mkdir structure
11000 echo x >structure/file
11001
11002 # On Nextstep (and perhaps other 4.3BSD systems),
11003 # a newly created file's ctime isn't updated
11004 # until the next sync or stat operation on the file.
11005 ls -l structure/file >/dev/null
11006
11007 # If the time of an initial backup and the creation time of a file contained
11008 # in that backup are the same, the file will be backed up again when an
11009 # incremental backup is done, because the incremental backup backs up
11010 # files created `on or after' the initial backup time.  Without the sleep
11011 # command, behaviour of tar becomes variable, depending whether the system
11012 # clock ticked over to the next second between creating the file and
11013 # backing it up.
11014 sleep 1
11015
11016 tar cf archive --listed=list structure
11017 tar cfv archive --listed=list structure
11018 echo separator
11019 # ReiserFS often offsets the timestamps of newly created files
11020 # 1 second to the past.  Try to compensate for it, until a better
11021 # solution is found.
11022 sleep 2
11023 echo y >structure/file
11024 tar cfv archive --listed=list structure
11025 ) ) >"$at_stdout" 2>"$at_stderr"
11026     at_status=$?
11027 fi
11028
11029 at_failed=false
11030 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
11031 echo >>"$at_stdout"; echo "structure/
11032 separator
11033 structure/
11034 structure/file
11035 " | $at_diff - "$at_stdout" || at_failed=:
11036 case $at_status in
11037    77) echo 77 > "$at_status_file"; exit 77;;
11038    0) ;;
11039    *) echo "$at_srcdir/incremental.at:26: exit code was $at_status, expected 0"
11040       at_failed=:;;
11041 esac
11042 if $at_failed; then
11043
11044
11045   echo 1 > "$at_status_file"
11046   exit 1
11047 fi
11048
11049 $at_traceon
11050
11051
11052
11053       $at_traceoff
11054       $at_times_p && times >"$at_times_file"
11055     ) 5>&1 2>&1 | eval $at_tee_pipe
11056     at_status=`cat "$at_status_file"`
11057     ;;
11058
11059   27 ) # 27. incr01.at:27: restore broken symlinks from incremental
11060     at_setup_line='incr01.at:27'
11061     at_desc="restore broken symlinks from incremental"
11062     $at_quiet $ECHO_N " 27: restore broken symlinks from incremental       $ECHO_C"
11063     at_xfail=no
11064       test -f $XFAILFILE && at_xfail=yes
11065     echo "#                             -*- compilation -*-" >> "$at_group_log"
11066     (
11067       echo "27. incr01.at:27: testing ..."
11068       $at_traceon
11069
11070
11071
11072
11073
11074   $at_traceoff
11075 echo "$at_srcdir/incr01.at:30:
11076 mkdir gnu
11077 (cd gnu
11078 TEST_TAR_FORMAT=gnu
11079 export TEST_TAR_FORMAT
11080 TAR_OPTIONS=\"-H gnu\"
11081 export TAR_OPTIONS
11082 rm -rf *
11083
11084 mkdir directory
11085 \$as_ln_s foo directory/bar
11086
11087 tar -cf archive.0 -g db directory
11088 rm directory/bar
11089 tar -cf archive.1 -g db directory
11090
11091 mv directory orig
11092
11093 tar xvfg archive.0 /dev/null
11094 echo separator
11095 tar xvfg archive.1 /dev/null
11096 )"
11097 echo incr01.at:30 >"$at_check_line_file"
11098
11099 at_trace_this=
11100 if test -n "$at_traceon"; then
11101     echo 'Not enabling shell tracing (command contains an embedded newline)'
11102 fi
11103
11104 if test -n "$at_trace_this"; then
11105     ( $at_traceon;
11106 mkdir gnu
11107 (cd gnu
11108 TEST_TAR_FORMAT=gnu
11109 export TEST_TAR_FORMAT
11110 TAR_OPTIONS="-H gnu"
11111 export TAR_OPTIONS
11112 rm -rf *
11113
11114 mkdir directory
11115 $as_ln_s foo directory/bar
11116
11117 tar -cf archive.0 -g db directory
11118 rm directory/bar
11119 tar -cf archive.1 -g db directory
11120
11121 mv directory orig
11122
11123 tar xvfg archive.0 /dev/null
11124 echo separator
11125 tar xvfg archive.1 /dev/null
11126 ) ) >"$at_stdout" 2>"$at_stder1"
11127     at_status=$?
11128     grep '^ *+' "$at_stder1" >&2
11129     grep -v '^ *+' "$at_stder1" >"$at_stderr"
11130 else
11131     ( :;
11132 mkdir gnu
11133 (cd gnu
11134 TEST_TAR_FORMAT=gnu
11135 export TEST_TAR_FORMAT
11136 TAR_OPTIONS="-H gnu"
11137 export TAR_OPTIONS
11138 rm -rf *
11139
11140 mkdir directory
11141 $as_ln_s foo directory/bar
11142
11143 tar -cf archive.0 -g db directory
11144 rm directory/bar
11145 tar -cf archive.1 -g db directory
11146
11147 mv directory orig
11148
11149 tar xvfg archive.0 /dev/null
11150 echo separator
11151 tar xvfg archive.1 /dev/null
11152 ) ) >"$at_stdout" 2>"$at_stderr"
11153     at_status=$?
11154 fi
11155
11156 at_failed=false
11157 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
11158 echo >>"$at_stdout"; echo "directory/
11159 directory/bar
11160 separator
11161 directory/
11162 tar: Deleting \`directory/bar'
11163 " | $at_diff - "$at_stdout" || at_failed=:
11164 case $at_status in
11165    77) echo 77 > "$at_status_file"; exit 77;;
11166    0) ;;
11167    *) echo "$at_srcdir/incr01.at:30: exit code was $at_status, expected 0"
11168       at_failed=:;;
11169 esac
11170 if $at_failed; then
11171
11172
11173   echo 1 > "$at_status_file"
11174   exit 1
11175 fi
11176
11177 $at_traceon
11178 $at_traceoff
11179 echo "$at_srcdir/incr01.at:30:
11180 mkdir oldgnu
11181 (cd oldgnu
11182 TEST_TAR_FORMAT=oldgnu
11183 export TEST_TAR_FORMAT
11184 TAR_OPTIONS=\"-H oldgnu\"
11185 export TAR_OPTIONS
11186 rm -rf *
11187
11188 mkdir directory
11189 \$as_ln_s foo directory/bar
11190
11191 tar -cf archive.0 -g db directory
11192 rm directory/bar
11193 tar -cf archive.1 -g db directory
11194
11195 mv directory orig
11196
11197 tar xvfg archive.0 /dev/null
11198 echo separator
11199 tar xvfg archive.1 /dev/null
11200 )"
11201 echo incr01.at:30 >"$at_check_line_file"
11202
11203 at_trace_this=
11204 if test -n "$at_traceon"; then
11205     echo 'Not enabling shell tracing (command contains an embedded newline)'
11206 fi
11207
11208 if test -n "$at_trace_this"; then
11209     ( $at_traceon;
11210 mkdir oldgnu
11211 (cd oldgnu
11212 TEST_TAR_FORMAT=oldgnu
11213 export TEST_TAR_FORMAT
11214 TAR_OPTIONS="-H oldgnu"
11215 export TAR_OPTIONS
11216 rm -rf *
11217
11218 mkdir directory
11219 $as_ln_s foo directory/bar
11220
11221 tar -cf archive.0 -g db directory
11222 rm directory/bar
11223 tar -cf archive.1 -g db directory
11224
11225 mv directory orig
11226
11227 tar xvfg archive.0 /dev/null
11228 echo separator
11229 tar xvfg archive.1 /dev/null
11230 ) ) >"$at_stdout" 2>"$at_stder1"
11231     at_status=$?
11232     grep '^ *+' "$at_stder1" >&2
11233     grep -v '^ *+' "$at_stder1" >"$at_stderr"
11234 else
11235     ( :;
11236 mkdir oldgnu
11237 (cd oldgnu
11238 TEST_TAR_FORMAT=oldgnu
11239 export TEST_TAR_FORMAT
11240 TAR_OPTIONS="-H oldgnu"
11241 export TAR_OPTIONS
11242 rm -rf *
11243
11244 mkdir directory
11245 $as_ln_s foo directory/bar
11246
11247 tar -cf archive.0 -g db directory
11248 rm directory/bar
11249 tar -cf archive.1 -g db directory
11250
11251 mv directory orig
11252
11253 tar xvfg archive.0 /dev/null
11254 echo separator
11255 tar xvfg archive.1 /dev/null
11256 ) ) >"$at_stdout" 2>"$at_stderr"
11257     at_status=$?
11258 fi
11259
11260 at_failed=false
11261 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
11262 echo >>"$at_stdout"; echo "directory/
11263 directory/bar
11264 separator
11265 directory/
11266 tar: Deleting \`directory/bar'
11267 " | $at_diff - "$at_stdout" || at_failed=:
11268 case $at_status in
11269    77) echo 77 > "$at_status_file"; exit 77;;
11270    0) ;;
11271    *) echo "$at_srcdir/incr01.at:30: exit code was $at_status, expected 0"
11272       at_failed=:;;
11273 esac
11274 if $at_failed; then
11275
11276
11277   echo 1 > "$at_status_file"
11278   exit 1
11279 fi
11280
11281 $at_traceon
11282 $at_traceoff
11283 echo "$at_srcdir/incr01.at:30:
11284 mkdir posix
11285 (cd posix
11286 TEST_TAR_FORMAT=posix
11287 export TEST_TAR_FORMAT
11288 TAR_OPTIONS=\"-H posix\"
11289 export TAR_OPTIONS
11290 rm -rf *
11291
11292 mkdir directory
11293 \$as_ln_s foo directory/bar
11294
11295 tar -cf archive.0 -g db directory
11296 rm directory/bar
11297 tar -cf archive.1 -g db directory
11298
11299 mv directory orig
11300
11301 tar xvfg archive.0 /dev/null
11302 echo separator
11303 tar xvfg archive.1 /dev/null
11304 )"
11305 echo incr01.at:30 >"$at_check_line_file"
11306
11307 at_trace_this=
11308 if test -n "$at_traceon"; then
11309     echo 'Not enabling shell tracing (command contains an embedded newline)'
11310 fi
11311
11312 if test -n "$at_trace_this"; then
11313     ( $at_traceon;
11314 mkdir posix
11315 (cd posix
11316 TEST_TAR_FORMAT=posix
11317 export TEST_TAR_FORMAT
11318 TAR_OPTIONS="-H posix"
11319 export TAR_OPTIONS
11320 rm -rf *
11321
11322 mkdir directory
11323 $as_ln_s foo directory/bar
11324
11325 tar -cf archive.0 -g db directory
11326 rm directory/bar
11327 tar -cf archive.1 -g db directory
11328
11329 mv directory orig
11330
11331 tar xvfg archive.0 /dev/null
11332 echo separator
11333 tar xvfg archive.1 /dev/null
11334 ) ) >"$at_stdout" 2>"$at_stder1"
11335     at_status=$?
11336     grep '^ *+' "$at_stder1" >&2
11337     grep -v '^ *+' "$at_stder1" >"$at_stderr"
11338 else
11339     ( :;
11340 mkdir posix
11341 (cd posix
11342 TEST_TAR_FORMAT=posix
11343 export TEST_TAR_FORMAT
11344 TAR_OPTIONS="-H posix"
11345 export TAR_OPTIONS
11346 rm -rf *
11347
11348 mkdir directory
11349 $as_ln_s foo directory/bar
11350
11351 tar -cf archive.0 -g db directory
11352 rm directory/bar
11353 tar -cf archive.1 -g db directory
11354
11355 mv directory orig
11356
11357 tar xvfg archive.0 /dev/null
11358 echo separator
11359 tar xvfg archive.1 /dev/null
11360 ) ) >"$at_stdout" 2>"$at_stderr"
11361     at_status=$?
11362 fi
11363
11364 at_failed=false
11365 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
11366 echo >>"$at_stdout"; echo "directory/
11367 directory/bar
11368 separator
11369 directory/
11370 tar: Deleting \`directory/bar'
11371 " | $at_diff - "$at_stdout" || at_failed=:
11372 case $at_status in
11373    77) echo 77 > "$at_status_file"; exit 77;;
11374    0) ;;
11375    *) echo "$at_srcdir/incr01.at:30: exit code was $at_status, expected 0"
11376       at_failed=:;;
11377 esac
11378 if $at_failed; then
11379
11380
11381   echo 1 > "$at_status_file"
11382   exit 1
11383 fi
11384
11385 $at_traceon
11386
11387
11388
11389       $at_traceoff
11390       $at_times_p && times >"$at_times_file"
11391     ) 5>&1 2>&1 | eval $at_tee_pipe
11392     at_status=`cat "$at_status_file"`
11393     ;;
11394
11395   28 ) # 28. incr02.at:32: restoring timestamps from incremental
11396     at_setup_line='incr02.at:32'
11397     at_desc="restoring timestamps from incremental"
11398     $at_quiet $ECHO_N " 28: restoring timestamps from incremental          $ECHO_C"
11399     at_xfail=no
11400       test -f $XFAILFILE && at_xfail=yes
11401     echo "#                             -*- compilation -*-" >> "$at_group_log"
11402     (
11403       echo "28. incr02.at:32: testing ..."
11404       $at_traceon
11405
11406
11407
11408
11409
11410   $at_traceoff
11411 echo "$at_srcdir/incr02.at:35:
11412 mkdir gnu
11413 (cd gnu
11414 TEST_TAR_FORMAT=gnu
11415 export TEST_TAR_FORMAT
11416 TAR_OPTIONS=\"-H gnu\"
11417 export TAR_OPTIONS
11418 rm -rf *
11419
11420 # Create directory structure
11421 mkdir dir
11422 mkdir dir/subdir1
11423 mkdir dir/subdir2
11424 genfile --length 10 --file dir/subdir1/file
11425
11426 # Save mtime for later comparison
11427 genfile --stat=mtime dir/subdir1 > ts
11428
11429 # Create an archive. Using incremental mode makes sure the
11430 # archive will have a directory-first member ordering,
11431 # i.e.:
11432 # dir/
11433 # dir/subdir1/
11434 # dir/subdir2/
11435 # dir/subdir1/foofile
11436 #
11437 # When restoring from this directory structure, \`dir/subdir2/' used to
11438 # trigger apply_nonancestor_delayed_set_stat() which restored stats for
11439 # \`subdir1' prior to restoring \`dir/subdir1/foofile'. Then, restoring the
11440 # latter clobbered the directory timestamp.
11441
11442 tar -cf archive -g db dir
11443
11444 # Move away the directory
11445 mv dir orig
11446
11447 # Wait enough time for timestamps to differ in case of failure.
11448 sleep 5
11449
11450 # Restore the directory
11451 tar -xf archive dir
11452
11453 # Check the timestamp
11454 genfile --stat=mtime dir/subdir1 | diff ts -
11455 )"
11456 echo incr02.at:35 >"$at_check_line_file"
11457
11458 at_trace_this=
11459 if test -n "$at_traceon"; then
11460     echo 'Not enabling shell tracing (command contains a `...` command substitution)'
11461 fi
11462
11463 if test -n "$at_trace_this"; then
11464     ( $at_traceon;
11465 mkdir gnu
11466 (cd gnu
11467 TEST_TAR_FORMAT=gnu
11468 export TEST_TAR_FORMAT
11469 TAR_OPTIONS="-H gnu"
11470 export TAR_OPTIONS
11471 rm -rf *
11472
11473 # Create directory structure
11474 mkdir dir
11475 mkdir dir/subdir1
11476 mkdir dir/subdir2
11477 genfile --length 10 --file dir/subdir1/file
11478
11479 # Save mtime for later comparison
11480 genfile --stat=mtime dir/subdir1 > ts
11481
11482 # Create an archive. Using incremental mode makes sure the
11483 # archive will have a directory-first member ordering,
11484 # i.e.:
11485 # dir/
11486 # dir/subdir1/
11487 # dir/subdir2/
11488 # dir/subdir1/foofile
11489 #
11490 # When restoring from this directory structure, `dir/subdir2/' used to
11491 # trigger apply_nonancestor_delayed_set_stat() which restored stats for
11492 # `subdir1' prior to restoring `dir/subdir1/foofile'. Then, restoring the
11493 # latter clobbered the directory timestamp.
11494
11495 tar -cf archive -g db dir
11496
11497 # Move away the directory
11498 mv dir orig
11499
11500 # Wait enough time for timestamps to differ in case of failure.
11501 sleep 5
11502
11503 # Restore the directory
11504 tar -xf archive dir
11505
11506 # Check the timestamp
11507 genfile --stat=mtime dir/subdir1 | diff ts -
11508 ) ) >"$at_stdout" 2>"$at_stder1"
11509     at_status=$?
11510     grep '^ *+' "$at_stder1" >&2
11511     grep -v '^ *+' "$at_stder1" >"$at_stderr"
11512 else
11513     ( :;
11514 mkdir gnu
11515 (cd gnu
11516 TEST_TAR_FORMAT=gnu
11517 export TEST_TAR_FORMAT
11518 TAR_OPTIONS="-H gnu"
11519 export TAR_OPTIONS
11520 rm -rf *
11521
11522 # Create directory structure
11523 mkdir dir
11524 mkdir dir/subdir1
11525 mkdir dir/subdir2
11526 genfile --length 10 --file dir/subdir1/file
11527
11528 # Save mtime for later comparison
11529 genfile --stat=mtime dir/subdir1 > ts
11530
11531 # Create an archive. Using incremental mode makes sure the
11532 # archive will have a directory-first member ordering,
11533 # i.e.:
11534 # dir/
11535 # dir/subdir1/
11536 # dir/subdir2/
11537 # dir/subdir1/foofile
11538 #
11539 # When restoring from this directory structure, `dir/subdir2/' used to
11540 # trigger apply_nonancestor_delayed_set_stat() which restored stats for
11541 # `subdir1' prior to restoring `dir/subdir1/foofile'. Then, restoring the
11542 # latter clobbered the directory timestamp.
11543
11544 tar -cf archive -g db dir
11545
11546 # Move away the directory
11547 mv dir orig
11548
11549 # Wait enough time for timestamps to differ in case of failure.
11550 sleep 5
11551
11552 # Restore the directory
11553 tar -xf archive dir
11554
11555 # Check the timestamp
11556 genfile --stat=mtime dir/subdir1 | diff ts -
11557 ) ) >"$at_stdout" 2>"$at_stderr"
11558     at_status=$?
11559 fi
11560
11561 at_failed=false
11562 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
11563 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
11564 case $at_status in
11565    77) echo 77 > "$at_status_file"; exit 77;;
11566    0) ;;
11567    *) echo "$at_srcdir/incr02.at:35: exit code was $at_status, expected 0"
11568       at_failed=:;;
11569 esac
11570 if $at_failed; then
11571
11572
11573   echo 1 > "$at_status_file"
11574   exit 1
11575 fi
11576
11577 $at_traceon
11578 $at_traceoff
11579 echo "$at_srcdir/incr02.at:35:
11580 mkdir oldgnu
11581 (cd oldgnu
11582 TEST_TAR_FORMAT=oldgnu
11583 export TEST_TAR_FORMAT
11584 TAR_OPTIONS=\"-H oldgnu\"
11585 export TAR_OPTIONS
11586 rm -rf *
11587
11588 # Create directory structure
11589 mkdir dir
11590 mkdir dir/subdir1
11591 mkdir dir/subdir2
11592 genfile --length 10 --file dir/subdir1/file
11593
11594 # Save mtime for later comparison
11595 genfile --stat=mtime dir/subdir1 > ts
11596
11597 # Create an archive. Using incremental mode makes sure the
11598 # archive will have a directory-first member ordering,
11599 # i.e.:
11600 # dir/
11601 # dir/subdir1/
11602 # dir/subdir2/
11603 # dir/subdir1/foofile
11604 #
11605 # When restoring from this directory structure, \`dir/subdir2/' used to
11606 # trigger apply_nonancestor_delayed_set_stat() which restored stats for
11607 # \`subdir1' prior to restoring \`dir/subdir1/foofile'. Then, restoring the
11608 # latter clobbered the directory timestamp.
11609
11610 tar -cf archive -g db dir
11611
11612 # Move away the directory
11613 mv dir orig
11614
11615 # Wait enough time for timestamps to differ in case of failure.
11616 sleep 5
11617
11618 # Restore the directory
11619 tar -xf archive dir
11620
11621 # Check the timestamp
11622 genfile --stat=mtime dir/subdir1 | diff ts -
11623 )"
11624 echo incr02.at:35 >"$at_check_line_file"
11625
11626 at_trace_this=
11627 if test -n "$at_traceon"; then
11628     echo 'Not enabling shell tracing (command contains a `...` command substitution)'
11629 fi
11630
11631 if test -n "$at_trace_this"; then
11632     ( $at_traceon;
11633 mkdir oldgnu
11634 (cd oldgnu
11635 TEST_TAR_FORMAT=oldgnu
11636 export TEST_TAR_FORMAT
11637 TAR_OPTIONS="-H oldgnu"
11638 export TAR_OPTIONS
11639 rm -rf *
11640
11641 # Create directory structure
11642 mkdir dir
11643 mkdir dir/subdir1
11644 mkdir dir/subdir2
11645 genfile --length 10 --file dir/subdir1/file
11646
11647 # Save mtime for later comparison
11648 genfile --stat=mtime dir/subdir1 > ts
11649
11650 # Create an archive. Using incremental mode makes sure the
11651 # archive will have a directory-first member ordering,
11652 # i.e.:
11653 # dir/
11654 # dir/subdir1/
11655 # dir/subdir2/
11656 # dir/subdir1/foofile
11657 #
11658 # When restoring from this directory structure, `dir/subdir2/' used to
11659 # trigger apply_nonancestor_delayed_set_stat() which restored stats for
11660 # `subdir1' prior to restoring `dir/subdir1/foofile'. Then, restoring the
11661 # latter clobbered the directory timestamp.
11662
11663 tar -cf archive -g db dir
11664
11665 # Move away the directory
11666 mv dir orig
11667
11668 # Wait enough time for timestamps to differ in case of failure.
11669 sleep 5
11670
11671 # Restore the directory
11672 tar -xf archive dir
11673
11674 # Check the timestamp
11675 genfile --stat=mtime dir/subdir1 | diff ts -
11676 ) ) >"$at_stdout" 2>"$at_stder1"
11677     at_status=$?
11678     grep '^ *+' "$at_stder1" >&2
11679     grep -v '^ *+' "$at_stder1" >"$at_stderr"
11680 else
11681     ( :;
11682 mkdir oldgnu
11683 (cd oldgnu
11684 TEST_TAR_FORMAT=oldgnu
11685 export TEST_TAR_FORMAT
11686 TAR_OPTIONS="-H oldgnu"
11687 export TAR_OPTIONS
11688 rm -rf *
11689
11690 # Create directory structure
11691 mkdir dir
11692 mkdir dir/subdir1
11693 mkdir dir/subdir2
11694 genfile --length 10 --file dir/subdir1/file
11695
11696 # Save mtime for later comparison
11697 genfile --stat=mtime dir/subdir1 > ts
11698
11699 # Create an archive. Using incremental mode makes sure the
11700 # archive will have a directory-first member ordering,
11701 # i.e.:
11702 # dir/
11703 # dir/subdir1/
11704 # dir/subdir2/
11705 # dir/subdir1/foofile
11706 #
11707 # When restoring from this directory structure, `dir/subdir2/' used to
11708 # trigger apply_nonancestor_delayed_set_stat() which restored stats for
11709 # `subdir1' prior to restoring `dir/subdir1/foofile'. Then, restoring the
11710 # latter clobbered the directory timestamp.
11711
11712 tar -cf archive -g db dir
11713
11714 # Move away the directory
11715 mv dir orig
11716
11717 # Wait enough time for timestamps to differ in case of failure.
11718 sleep 5
11719
11720 # Restore the directory
11721 tar -xf archive dir
11722
11723 # Check the timestamp
11724 genfile --stat=mtime dir/subdir1 | diff ts -
11725 ) ) >"$at_stdout" 2>"$at_stderr"
11726     at_status=$?
11727 fi
11728
11729 at_failed=false
11730 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
11731 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
11732 case $at_status in
11733    77) echo 77 > "$at_status_file"; exit 77;;
11734    0) ;;
11735    *) echo "$at_srcdir/incr02.at:35: exit code was $at_status, expected 0"
11736       at_failed=:;;
11737 esac
11738 if $at_failed; then
11739
11740
11741   echo 1 > "$at_status_file"
11742   exit 1
11743 fi
11744
11745 $at_traceon
11746 $at_traceoff
11747 echo "$at_srcdir/incr02.at:35:
11748 mkdir posix
11749 (cd posix
11750 TEST_TAR_FORMAT=posix
11751 export TEST_TAR_FORMAT
11752 TAR_OPTIONS=\"-H posix\"
11753 export TAR_OPTIONS
11754 rm -rf *
11755
11756 # Create directory structure
11757 mkdir dir
11758 mkdir dir/subdir1
11759 mkdir dir/subdir2
11760 genfile --length 10 --file dir/subdir1/file
11761
11762 # Save mtime for later comparison
11763 genfile --stat=mtime dir/subdir1 > ts
11764
11765 # Create an archive. Using incremental mode makes sure the
11766 # archive will have a directory-first member ordering,
11767 # i.e.:
11768 # dir/
11769 # dir/subdir1/
11770 # dir/subdir2/
11771 # dir/subdir1/foofile
11772 #
11773 # When restoring from this directory structure, \`dir/subdir2/' used to
11774 # trigger apply_nonancestor_delayed_set_stat() which restored stats for
11775 # \`subdir1' prior to restoring \`dir/subdir1/foofile'. Then, restoring the
11776 # latter clobbered the directory timestamp.
11777
11778 tar -cf archive -g db dir
11779
11780 # Move away the directory
11781 mv dir orig
11782
11783 # Wait enough time for timestamps to differ in case of failure.
11784 sleep 5
11785
11786 # Restore the directory
11787 tar -xf archive dir
11788
11789 # Check the timestamp
11790 genfile --stat=mtime dir/subdir1 | diff ts -
11791 )"
11792 echo incr02.at:35 >"$at_check_line_file"
11793
11794 at_trace_this=
11795 if test -n "$at_traceon"; then
11796     echo 'Not enabling shell tracing (command contains a `...` command substitution)'
11797 fi
11798
11799 if test -n "$at_trace_this"; then
11800     ( $at_traceon;
11801 mkdir posix
11802 (cd posix
11803 TEST_TAR_FORMAT=posix
11804 export TEST_TAR_FORMAT
11805 TAR_OPTIONS="-H posix"
11806 export TAR_OPTIONS
11807 rm -rf *
11808
11809 # Create directory structure
11810 mkdir dir
11811 mkdir dir/subdir1
11812 mkdir dir/subdir2
11813 genfile --length 10 --file dir/subdir1/file
11814
11815 # Save mtime for later comparison
11816 genfile --stat=mtime dir/subdir1 > ts
11817
11818 # Create an archive. Using incremental mode makes sure the
11819 # archive will have a directory-first member ordering,
11820 # i.e.:
11821 # dir/
11822 # dir/subdir1/
11823 # dir/subdir2/
11824 # dir/subdir1/foofile
11825 #
11826 # When restoring from this directory structure, `dir/subdir2/' used to
11827 # trigger apply_nonancestor_delayed_set_stat() which restored stats for
11828 # `subdir1' prior to restoring `dir/subdir1/foofile'. Then, restoring the
11829 # latter clobbered the directory timestamp.
11830
11831 tar -cf archive -g db dir
11832
11833 # Move away the directory
11834 mv dir orig
11835
11836 # Wait enough time for timestamps to differ in case of failure.
11837 sleep 5
11838
11839 # Restore the directory
11840 tar -xf archive dir
11841
11842 # Check the timestamp
11843 genfile --stat=mtime dir/subdir1 | diff ts -
11844 ) ) >"$at_stdout" 2>"$at_stder1"
11845     at_status=$?
11846     grep '^ *+' "$at_stder1" >&2
11847     grep -v '^ *+' "$at_stder1" >"$at_stderr"
11848 else
11849     ( :;
11850 mkdir posix
11851 (cd posix
11852 TEST_TAR_FORMAT=posix
11853 export TEST_TAR_FORMAT
11854 TAR_OPTIONS="-H posix"
11855 export TAR_OPTIONS
11856 rm -rf *
11857
11858 # Create directory structure
11859 mkdir dir
11860 mkdir dir/subdir1
11861 mkdir dir/subdir2
11862 genfile --length 10 --file dir/subdir1/file
11863
11864 # Save mtime for later comparison
11865 genfile --stat=mtime dir/subdir1 > ts
11866
11867 # Create an archive. Using incremental mode makes sure the
11868 # archive will have a directory-first member ordering,
11869 # i.e.:
11870 # dir/
11871 # dir/subdir1/
11872 # dir/subdir2/
11873 # dir/subdir1/foofile
11874 #
11875 # When restoring from this directory structure, `dir/subdir2/' used to
11876 # trigger apply_nonancestor_delayed_set_stat() which restored stats for
11877 # `subdir1' prior to restoring `dir/subdir1/foofile'. Then, restoring the
11878 # latter clobbered the directory timestamp.
11879
11880 tar -cf archive -g db dir
11881
11882 # Move away the directory
11883 mv dir orig
11884
11885 # Wait enough time for timestamps to differ in case of failure.
11886 sleep 5
11887
11888 # Restore the directory
11889 tar -xf archive dir
11890
11891 # Check the timestamp
11892 genfile --stat=mtime dir/subdir1 | diff ts -
11893 ) ) >"$at_stdout" 2>"$at_stderr"
11894     at_status=$?
11895 fi
11896
11897 at_failed=false
11898 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
11899 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
11900 case $at_status in
11901    77) echo 77 > "$at_status_file"; exit 77;;
11902    0) ;;
11903    *) echo "$at_srcdir/incr02.at:35: exit code was $at_status, expected 0"
11904       at_failed=:;;
11905 esac
11906 if $at_failed; then
11907
11908
11909   echo 1 > "$at_status_file"
11910   exit 1
11911 fi
11912
11913 $at_traceon
11914
11915
11916
11917       $at_traceoff
11918       $at_times_p && times >"$at_times_file"
11919     ) 5>&1 2>&1 | eval $at_tee_pipe
11920     at_status=`cat "$at_status_file"`
11921     ;;
11922
11923   29 ) # 29. listed01.at:26: --listed for individual files
11924     at_setup_line='listed01.at:26'
11925     at_desc="--listed for individual files"
11926     $at_quiet $ECHO_N " 29: --listed for individual files                  $ECHO_C"
11927     at_xfail=no
11928       test -f $XFAILFILE && at_xfail=yes
11929     echo "#                             -*- compilation -*-" >> "$at_group_log"
11930     (
11931       echo "29. listed01.at:26: testing ..."
11932       $at_traceon
11933
11934
11935
11936
11937
11938   $at_traceoff
11939 echo "$at_srcdir/listed01.at:29:
11940 mkdir gnu
11941 (cd gnu
11942 TEST_TAR_FORMAT=gnu
11943 export TEST_TAR_FORMAT
11944 TAR_OPTIONS=\"-H gnu\"
11945 export TAR_OPTIONS
11946 rm -rf *
11947
11948 mkdir directory
11949 genfile --length 10240 --pattern zeros --file directory/file1
11950 # Let the things settle
11951 sleep 1
11952
11953 tar --create \\
11954     --file=archive.1 \\
11955     --listed-incremental=listing \\
11956     directory/file*
11957
11958 tar tf archive.1 || exit 1
11959
11960 sleep 2
11961
11962 genfile --length 10240 --pattern zeros --file directory/file2
11963
11964 echo \"separator\"
11965
11966 tar --create \\
11967     --file=archive.2 \\
11968     --listed-incremental=listing \\
11969     directory/file* || exit 1
11970
11971 tar tf archive.2 || exit 1
11972 )"
11973 echo listed01.at:29 >"$at_check_line_file"
11974
11975 at_trace_this=
11976 if test -n "$at_traceon"; then
11977     echo 'Not enabling shell tracing (command contains an embedded newline)'
11978 fi
11979
11980 if test -n "$at_trace_this"; then
11981     ( $at_traceon;
11982 mkdir gnu
11983 (cd gnu
11984 TEST_TAR_FORMAT=gnu
11985 export TEST_TAR_FORMAT
11986 TAR_OPTIONS="-H gnu"
11987 export TAR_OPTIONS
11988 rm -rf *
11989
11990 mkdir directory
11991 genfile --length 10240 --pattern zeros --file directory/file1
11992 # Let the things settle
11993 sleep 1
11994
11995 tar --create \
11996     --file=archive.1 \
11997     --listed-incremental=listing \
11998     directory/file*
11999
12000 tar tf archive.1 || exit 1
12001
12002 sleep 2
12003
12004 genfile --length 10240 --pattern zeros --file directory/file2
12005
12006 echo "separator"
12007
12008 tar --create \
12009     --file=archive.2 \
12010     --listed-incremental=listing \
12011     directory/file* || exit 1
12012
12013 tar tf archive.2 || exit 1
12014 ) ) >"$at_stdout" 2>"$at_stder1"
12015     at_status=$?
12016     grep '^ *+' "$at_stder1" >&2
12017     grep -v '^ *+' "$at_stder1" >"$at_stderr"
12018 else
12019     ( :;
12020 mkdir gnu
12021 (cd gnu
12022 TEST_TAR_FORMAT=gnu
12023 export TEST_TAR_FORMAT
12024 TAR_OPTIONS="-H gnu"
12025 export TAR_OPTIONS
12026 rm -rf *
12027
12028 mkdir directory
12029 genfile --length 10240 --pattern zeros --file directory/file1
12030 # Let the things settle
12031 sleep 1
12032
12033 tar --create \
12034     --file=archive.1 \
12035     --listed-incremental=listing \
12036     directory/file*
12037
12038 tar tf archive.1 || exit 1
12039
12040 sleep 2
12041
12042 genfile --length 10240 --pattern zeros --file directory/file2
12043
12044 echo "separator"
12045
12046 tar --create \
12047     --file=archive.2 \
12048     --listed-incremental=listing \
12049     directory/file* || exit 1
12050
12051 tar tf archive.2 || exit 1
12052 ) ) >"$at_stdout" 2>"$at_stderr"
12053     at_status=$?
12054 fi
12055
12056 at_failed=false
12057 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
12058 echo >>"$at_stdout"; echo "directory/file1
12059 separator
12060 directory/file2
12061 " | $at_diff - "$at_stdout" || at_failed=:
12062 case $at_status in
12063    77) echo 77 > "$at_status_file"; exit 77;;
12064    0) ;;
12065    *) echo "$at_srcdir/listed01.at:29: exit code was $at_status, expected 0"
12066       at_failed=:;;
12067 esac
12068 if $at_failed; then
12069
12070
12071   echo 1 > "$at_status_file"
12072   exit 1
12073 fi
12074
12075 $at_traceon
12076 $at_traceoff
12077 echo "$at_srcdir/listed01.at:29:
12078 mkdir oldgnu
12079 (cd oldgnu
12080 TEST_TAR_FORMAT=oldgnu
12081 export TEST_TAR_FORMAT
12082 TAR_OPTIONS=\"-H oldgnu\"
12083 export TAR_OPTIONS
12084 rm -rf *
12085
12086 mkdir directory
12087 genfile --length 10240 --pattern zeros --file directory/file1
12088 # Let the things settle
12089 sleep 1
12090
12091 tar --create \\
12092     --file=archive.1 \\
12093     --listed-incremental=listing \\
12094     directory/file*
12095
12096 tar tf archive.1 || exit 1
12097
12098 sleep 2
12099
12100 genfile --length 10240 --pattern zeros --file directory/file2
12101
12102 echo \"separator\"
12103
12104 tar --create \\
12105     --file=archive.2 \\
12106     --listed-incremental=listing \\
12107     directory/file* || exit 1
12108
12109 tar tf archive.2 || exit 1
12110 )"
12111 echo listed01.at:29 >"$at_check_line_file"
12112
12113 at_trace_this=
12114 if test -n "$at_traceon"; then
12115     echo 'Not enabling shell tracing (command contains an embedded newline)'
12116 fi
12117
12118 if test -n "$at_trace_this"; then
12119     ( $at_traceon;
12120 mkdir oldgnu
12121 (cd oldgnu
12122 TEST_TAR_FORMAT=oldgnu
12123 export TEST_TAR_FORMAT
12124 TAR_OPTIONS="-H oldgnu"
12125 export TAR_OPTIONS
12126 rm -rf *
12127
12128 mkdir directory
12129 genfile --length 10240 --pattern zeros --file directory/file1
12130 # Let the things settle
12131 sleep 1
12132
12133 tar --create \
12134     --file=archive.1 \
12135     --listed-incremental=listing \
12136     directory/file*
12137
12138 tar tf archive.1 || exit 1
12139
12140 sleep 2
12141
12142 genfile --length 10240 --pattern zeros --file directory/file2
12143
12144 echo "separator"
12145
12146 tar --create \
12147     --file=archive.2 \
12148     --listed-incremental=listing \
12149     directory/file* || exit 1
12150
12151 tar tf archive.2 || exit 1
12152 ) ) >"$at_stdout" 2>"$at_stder1"
12153     at_status=$?
12154     grep '^ *+' "$at_stder1" >&2
12155     grep -v '^ *+' "$at_stder1" >"$at_stderr"
12156 else
12157     ( :;
12158 mkdir oldgnu
12159 (cd oldgnu
12160 TEST_TAR_FORMAT=oldgnu
12161 export TEST_TAR_FORMAT
12162 TAR_OPTIONS="-H oldgnu"
12163 export TAR_OPTIONS
12164 rm -rf *
12165
12166 mkdir directory
12167 genfile --length 10240 --pattern zeros --file directory/file1
12168 # Let the things settle
12169 sleep 1
12170
12171 tar --create \
12172     --file=archive.1 \
12173     --listed-incremental=listing \
12174     directory/file*
12175
12176 tar tf archive.1 || exit 1
12177
12178 sleep 2
12179
12180 genfile --length 10240 --pattern zeros --file directory/file2
12181
12182 echo "separator"
12183
12184 tar --create \
12185     --file=archive.2 \
12186     --listed-incremental=listing \
12187     directory/file* || exit 1
12188
12189 tar tf archive.2 || exit 1
12190 ) ) >"$at_stdout" 2>"$at_stderr"
12191     at_status=$?
12192 fi
12193
12194 at_failed=false
12195 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
12196 echo >>"$at_stdout"; echo "directory/file1
12197 separator
12198 directory/file2
12199 " | $at_diff - "$at_stdout" || at_failed=:
12200 case $at_status in
12201    77) echo 77 > "$at_status_file"; exit 77;;
12202    0) ;;
12203    *) echo "$at_srcdir/listed01.at:29: exit code was $at_status, expected 0"
12204       at_failed=:;;
12205 esac
12206 if $at_failed; then
12207
12208
12209   echo 1 > "$at_status_file"
12210   exit 1
12211 fi
12212
12213 $at_traceon
12214
12215
12216
12217       $at_traceoff
12218       $at_times_p && times >"$at_times_file"
12219     ) 5>&1 2>&1 | eval $at_tee_pipe
12220     at_status=`cat "$at_status_file"`
12221     ;;
12222
12223   30 ) # 30. listed02.at:28: working --listed
12224     at_setup_line='listed02.at:28'
12225     at_desc="working --listed"
12226     $at_quiet $ECHO_N " 30: working --listed                               $ECHO_C"
12227     at_xfail=no
12228       test -f $XFAILFILE && at_xfail=yes
12229     echo "#                             -*- compilation -*-" >> "$at_group_log"
12230     (
12231       echo "30. listed02.at:28: testing ..."
12232       $at_traceon
12233
12234
12235
12236
12237
12238   $at_traceoff
12239 echo "$at_srcdir/listed02.at:31:
12240 mkdir gnu
12241 (cd gnu
12242 TEST_TAR_FORMAT=gnu
12243 export TEST_TAR_FORMAT
12244 TAR_OPTIONS=\"-H gnu\"
12245 export TAR_OPTIONS
12246 rm -rf *
12247
12248
12249 test -z "`sort < /dev/null 2>&1`" || exit 77
12250
12251 echo Create directories
12252
12253 mkdir tart
12254 sleep 1
12255 mkdir tart/c0
12256 sleep 1
12257 mkdir tart/c1
12258 sleep 1
12259
12260 for file in tart/a1 tart/b1 tart/c0/cq1 tart/c0/cq2 tart/c1/ca1 tart/c1/ca2
12261 do
12262   echo File \$file > \$file
12263   sleep 1
12264 done
12265
12266 sleep 1
12267 echo Creating main archive
12268 tar -c -v --listed-incremental=tart.incr1 -f archive.1 tart 2> err || exit 1
12269
12270 # The above prints two lines to stderr announcing the new directories c0 and c1.
12271 # Ensure that they appear in this script's stderr in sorted order.
12272 sort err 1>&2; rm -f err
12273
12274 sleep 1
12275 echo Modifying filesystem
12276 rm tart/a1
12277
12278 mv tart/b1 tart/b2
12279 mv tart/c1 tart/c2
12280 touch tart/c2/ca3
12281
12282 echo Directory contents
12283 find tart -print | sort 2>/dev/null
12284
12285 sleep 1
12286 echo Creating incremental archive
12287 cp -p tart.incr1 tart.incr2
12288 tar -c -v --listed-incremental=tart.incr2 -f archive.2 tart || exit 1
12289
12290 sleep 1
12291
12292 rm -rf tart/*
12293 echo Extracting main archive
12294 tar -x -v --listed-incremental=tart.incr1 -f archive.1 || exit 1
12295 echo Extracting incremental archive
12296 # This command should produce three messages about deletion
12297 # of the existing files, that may appear in any order. Piping
12298 # to sort makes sure we don't depend on any particular ordering.
12299 tar -x -v --listed-incremental=tart.incr2 -f archive.2 | sort 2>/dev/null
12300
12301 echo Final files:
12302 find tart -print | sort 2>/dev/null
12303 )"
12304 echo listed02.at:31 >"$at_check_line_file"
12305
12306 at_trace_this=
12307 if test -n "$at_traceon"; then
12308     echo 'Not enabling shell tracing (command contains an embedded newline)'
12309 fi
12310
12311 if test -n "$at_trace_this"; then
12312     ( $at_traceon;
12313 mkdir gnu
12314 (cd gnu
12315 TEST_TAR_FORMAT=gnu
12316 export TEST_TAR_FORMAT
12317 TAR_OPTIONS="-H gnu"
12318 export TAR_OPTIONS
12319 rm -rf *
12320
12321
12322 test -z "`sort < /dev/null 2>&1`" || exit 77
12323
12324 echo Create directories
12325
12326 mkdir tart
12327 sleep 1
12328 mkdir tart/c0
12329 sleep 1
12330 mkdir tart/c1
12331 sleep 1
12332
12333 for file in tart/a1 tart/b1 tart/c0/cq1 tart/c0/cq2 tart/c1/ca1 tart/c1/ca2
12334 do
12335   echo File $file > $file
12336   sleep 1
12337 done
12338
12339 sleep 1
12340 echo Creating main archive
12341 tar -c -v --listed-incremental=tart.incr1 -f archive.1 tart 2> err || exit 1
12342
12343 # The above prints two lines to stderr announcing the new directories c0 and c1.
12344 # Ensure that they appear in this script's stderr in sorted order.
12345 sort err 1>&2; rm -f err
12346
12347 sleep 1
12348 echo Modifying filesystem
12349 rm tart/a1
12350
12351 mv tart/b1 tart/b2
12352 mv tart/c1 tart/c2
12353 touch tart/c2/ca3
12354
12355 echo Directory contents
12356 find tart -print | sort 2>/dev/null
12357
12358 sleep 1
12359 echo Creating incremental archive
12360 cp -p tart.incr1 tart.incr2
12361 tar -c -v --listed-incremental=tart.incr2 -f archive.2 tart || exit 1
12362
12363 sleep 1
12364
12365 rm -rf tart/*
12366 echo Extracting main archive
12367 tar -x -v --listed-incremental=tart.incr1 -f archive.1 || exit 1
12368 echo Extracting incremental archive
12369 # This command should produce three messages about deletion
12370 # of the existing files, that may appear in any order. Piping
12371 # to sort makes sure we don't depend on any particular ordering.
12372 tar -x -v --listed-incremental=tart.incr2 -f archive.2 | sort 2>/dev/null
12373
12374 echo Final files:
12375 find tart -print | sort 2>/dev/null
12376 ) ) >"$at_stdout" 2>"$at_stder1"
12377     at_status=$?
12378     grep '^ *+' "$at_stder1" >&2
12379     grep -v '^ *+' "$at_stder1" >"$at_stderr"
12380 else
12381     ( :;
12382 mkdir gnu
12383 (cd gnu
12384 TEST_TAR_FORMAT=gnu
12385 export TEST_TAR_FORMAT
12386 TAR_OPTIONS="-H gnu"
12387 export TAR_OPTIONS
12388 rm -rf *
12389
12390
12391 test -z "`sort < /dev/null 2>&1`" || exit 77
12392
12393 echo Create directories
12394
12395 mkdir tart
12396 sleep 1
12397 mkdir tart/c0
12398 sleep 1
12399 mkdir tart/c1
12400 sleep 1
12401
12402 for file in tart/a1 tart/b1 tart/c0/cq1 tart/c0/cq2 tart/c1/ca1 tart/c1/ca2
12403 do
12404   echo File $file > $file
12405   sleep 1
12406 done
12407
12408 sleep 1
12409 echo Creating main archive
12410 tar -c -v --listed-incremental=tart.incr1 -f archive.1 tart 2> err || exit 1
12411
12412 # The above prints two lines to stderr announcing the new directories c0 and c1.
12413 # Ensure that they appear in this script's stderr in sorted order.
12414 sort err 1>&2; rm -f err
12415
12416 sleep 1
12417 echo Modifying filesystem
12418 rm tart/a1
12419
12420 mv tart/b1 tart/b2
12421 mv tart/c1 tart/c2
12422 touch tart/c2/ca3
12423
12424 echo Directory contents
12425 find tart -print | sort 2>/dev/null
12426
12427 sleep 1
12428 echo Creating incremental archive
12429 cp -p tart.incr1 tart.incr2
12430 tar -c -v --listed-incremental=tart.incr2 -f archive.2 tart || exit 1
12431
12432 sleep 1
12433
12434 rm -rf tart/*
12435 echo Extracting main archive
12436 tar -x -v --listed-incremental=tart.incr1 -f archive.1 || exit 1
12437 echo Extracting incremental archive
12438 # This command should produce three messages about deletion
12439 # of the existing files, that may appear in any order. Piping
12440 # to sort makes sure we don't depend on any particular ordering.
12441 tar -x -v --listed-incremental=tart.incr2 -f archive.2 | sort 2>/dev/null
12442
12443 echo Final files:
12444 find tart -print | sort 2>/dev/null
12445 ) ) >"$at_stdout" 2>"$at_stderr"
12446     at_status=$?
12447 fi
12448
12449 at_failed=false
12450 echo >>"$at_stderr"; echo "tar: tart/c0: Directory is new
12451 tar: tart/c1: Directory is new
12452 tar: tart/c2: Directory has been renamed from \`tart/c1'
12453 " | $at_diff - "$at_stderr" || at_failed=:
12454 echo >>"$at_stdout"; echo "Create directories
12455 Creating main archive
12456 tart/
12457 tart/c0/
12458 tart/c1/
12459 tart/a1
12460 tart/b1
12461 tart/c0/cq1
12462 tart/c0/cq2
12463 tart/c1/ca1
12464 tart/c1/ca2
12465 Modifying filesystem
12466 Directory contents
12467 tart
12468 tart/b2
12469 tart/c0
12470 tart/c0/cq1
12471 tart/c0/cq2
12472 tart/c2
12473 tart/c2/ca1
12474 tart/c2/ca2
12475 tart/c2/ca3
12476 Creating incremental archive
12477 tart/
12478 tart/c0/
12479 tart/c2/
12480 tart/b2
12481 tart/c2/ca3
12482 Extracting main archive
12483 tart/
12484 tart/c0/
12485 tart/c1/
12486 tart/a1
12487 tart/b1
12488 tart/c0/cq1
12489 tart/c0/cq2
12490 tart/c1/ca1
12491 tart/c1/ca2
12492 Extracting incremental archive
12493 tar: Deleting \`tart/a1'
12494 tar: Deleting \`tart/b1'
12495 tart/
12496 tart/b2
12497 tart/c0/
12498 tart/c2/
12499 tart/c2/ca3
12500 Final files:
12501 tart
12502 tart/b2
12503 tart/c0
12504 tart/c0/cq1
12505 tart/c0/cq2
12506 tart/c2
12507 tart/c2/ca1
12508 tart/c2/ca2
12509 tart/c2/ca3
12510 " | $at_diff - "$at_stdout" || at_failed=:
12511 case $at_status in
12512    77) echo 77 > "$at_status_file"; exit 77;;
12513    0) ;;
12514    *) echo "$at_srcdir/listed02.at:31: exit code was $at_status, expected 0"
12515       at_failed=:;;
12516 esac
12517 if $at_failed; then
12518
12519
12520   echo 1 > "$at_status_file"
12521   exit 1
12522 fi
12523
12524 $at_traceon
12525 $at_traceoff
12526 echo "$at_srcdir/listed02.at:31:
12527 mkdir oldgnu
12528 (cd oldgnu
12529 TEST_TAR_FORMAT=oldgnu
12530 export TEST_TAR_FORMAT
12531 TAR_OPTIONS=\"-H oldgnu\"
12532 export TAR_OPTIONS
12533 rm -rf *
12534
12535
12536 test -z "`sort < /dev/null 2>&1`" || exit 77
12537
12538 echo Create directories
12539
12540 mkdir tart
12541 sleep 1
12542 mkdir tart/c0
12543 sleep 1
12544 mkdir tart/c1
12545 sleep 1
12546
12547 for file in tart/a1 tart/b1 tart/c0/cq1 tart/c0/cq2 tart/c1/ca1 tart/c1/ca2
12548 do
12549   echo File \$file > \$file
12550   sleep 1
12551 done
12552
12553 sleep 1
12554 echo Creating main archive
12555 tar -c -v --listed-incremental=tart.incr1 -f archive.1 tart 2> err || exit 1
12556
12557 # The above prints two lines to stderr announcing the new directories c0 and c1.
12558 # Ensure that they appear in this script's stderr in sorted order.
12559 sort err 1>&2; rm -f err
12560
12561 sleep 1
12562 echo Modifying filesystem
12563 rm tart/a1
12564
12565 mv tart/b1 tart/b2
12566 mv tart/c1 tart/c2
12567 touch tart/c2/ca3
12568
12569 echo Directory contents
12570 find tart -print | sort 2>/dev/null
12571
12572 sleep 1
12573 echo Creating incremental archive
12574 cp -p tart.incr1 tart.incr2
12575 tar -c -v --listed-incremental=tart.incr2 -f archive.2 tart || exit 1
12576
12577 sleep 1
12578
12579 rm -rf tart/*
12580 echo Extracting main archive
12581 tar -x -v --listed-incremental=tart.incr1 -f archive.1 || exit 1
12582 echo Extracting incremental archive
12583 # This command should produce three messages about deletion
12584 # of the existing files, that may appear in any order. Piping
12585 # to sort makes sure we don't depend on any particular ordering.
12586 tar -x -v --listed-incremental=tart.incr2 -f archive.2 | sort 2>/dev/null
12587
12588 echo Final files:
12589 find tart -print | sort 2>/dev/null
12590 )"
12591 echo listed02.at:31 >"$at_check_line_file"
12592
12593 at_trace_this=
12594 if test -n "$at_traceon"; then
12595     echo 'Not enabling shell tracing (command contains an embedded newline)'
12596 fi
12597
12598 if test -n "$at_trace_this"; then
12599     ( $at_traceon;
12600 mkdir oldgnu
12601 (cd oldgnu
12602 TEST_TAR_FORMAT=oldgnu
12603 export TEST_TAR_FORMAT
12604 TAR_OPTIONS="-H oldgnu"
12605 export TAR_OPTIONS
12606 rm -rf *
12607
12608
12609 test -z "`sort < /dev/null 2>&1`" || exit 77
12610
12611 echo Create directories
12612
12613 mkdir tart
12614 sleep 1
12615 mkdir tart/c0
12616 sleep 1
12617 mkdir tart/c1
12618 sleep 1
12619
12620 for file in tart/a1 tart/b1 tart/c0/cq1 tart/c0/cq2 tart/c1/ca1 tart/c1/ca2
12621 do
12622   echo File $file > $file
12623   sleep 1
12624 done
12625
12626 sleep 1
12627 echo Creating main archive
12628 tar -c -v --listed-incremental=tart.incr1 -f archive.1 tart 2> err || exit 1
12629
12630 # The above prints two lines to stderr announcing the new directories c0 and c1.
12631 # Ensure that they appear in this script's stderr in sorted order.
12632 sort err 1>&2; rm -f err
12633
12634 sleep 1
12635 echo Modifying filesystem
12636 rm tart/a1
12637
12638 mv tart/b1 tart/b2
12639 mv tart/c1 tart/c2
12640 touch tart/c2/ca3
12641
12642 echo Directory contents
12643 find tart -print | sort 2>/dev/null
12644
12645 sleep 1
12646 echo Creating incremental archive
12647 cp -p tart.incr1 tart.incr2
12648 tar -c -v --listed-incremental=tart.incr2 -f archive.2 tart || exit 1
12649
12650 sleep 1
12651
12652 rm -rf tart/*
12653 echo Extracting main archive
12654 tar -x -v --listed-incremental=tart.incr1 -f archive.1 || exit 1
12655 echo Extracting incremental archive
12656 # This command should produce three messages about deletion
12657 # of the existing files, that may appear in any order. Piping
12658 # to sort makes sure we don't depend on any particular ordering.
12659 tar -x -v --listed-incremental=tart.incr2 -f archive.2 | sort 2>/dev/null
12660
12661 echo Final files:
12662 find tart -print | sort 2>/dev/null
12663 ) ) >"$at_stdout" 2>"$at_stder1"
12664     at_status=$?
12665     grep '^ *+' "$at_stder1" >&2
12666     grep -v '^ *+' "$at_stder1" >"$at_stderr"
12667 else
12668     ( :;
12669 mkdir oldgnu
12670 (cd oldgnu
12671 TEST_TAR_FORMAT=oldgnu
12672 export TEST_TAR_FORMAT
12673 TAR_OPTIONS="-H oldgnu"
12674 export TAR_OPTIONS
12675 rm -rf *
12676
12677
12678 test -z "`sort < /dev/null 2>&1`" || exit 77
12679
12680 echo Create directories
12681
12682 mkdir tart
12683 sleep 1
12684 mkdir tart/c0
12685 sleep 1
12686 mkdir tart/c1
12687 sleep 1
12688
12689 for file in tart/a1 tart/b1 tart/c0/cq1 tart/c0/cq2 tart/c1/ca1 tart/c1/ca2
12690 do
12691   echo File $file > $file
12692   sleep 1
12693 done
12694
12695 sleep 1
12696 echo Creating main archive
12697 tar -c -v --listed-incremental=tart.incr1 -f archive.1 tart 2> err || exit 1
12698
12699 # The above prints two lines to stderr announcing the new directories c0 and c1.
12700 # Ensure that they appear in this script's stderr in sorted order.
12701 sort err 1>&2; rm -f err
12702
12703 sleep 1
12704 echo Modifying filesystem
12705 rm tart/a1
12706
12707 mv tart/b1 tart/b2
12708 mv tart/c1 tart/c2
12709 touch tart/c2/ca3
12710
12711 echo Directory contents
12712 find tart -print | sort 2>/dev/null
12713
12714 sleep 1
12715 echo Creating incremental archive
12716 cp -p tart.incr1 tart.incr2
12717 tar -c -v --listed-incremental=tart.incr2 -f archive.2 tart || exit 1
12718
12719 sleep 1
12720
12721 rm -rf tart/*
12722 echo Extracting main archive
12723 tar -x -v --listed-incremental=tart.incr1 -f archive.1 || exit 1
12724 echo Extracting incremental archive
12725 # This command should produce three messages about deletion
12726 # of the existing files, that may appear in any order. Piping
12727 # to sort makes sure we don't depend on any particular ordering.
12728 tar -x -v --listed-incremental=tart.incr2 -f archive.2 | sort 2>/dev/null
12729
12730 echo Final files:
12731 find tart -print | sort 2>/dev/null
12732 ) ) >"$at_stdout" 2>"$at_stderr"
12733     at_status=$?
12734 fi
12735
12736 at_failed=false
12737 echo >>"$at_stderr"; echo "tar: tart/c0: Directory is new
12738 tar: tart/c1: Directory is new
12739 tar: tart/c2: Directory has been renamed from \`tart/c1'
12740 " | $at_diff - "$at_stderr" || at_failed=:
12741 echo >>"$at_stdout"; echo "Create directories
12742 Creating main archive
12743 tart/
12744 tart/c0/
12745 tart/c1/
12746 tart/a1
12747 tart/b1
12748 tart/c0/cq1
12749 tart/c0/cq2
12750 tart/c1/ca1
12751 tart/c1/ca2
12752 Modifying filesystem
12753 Directory contents
12754 tart
12755 tart/b2
12756 tart/c0
12757 tart/c0/cq1
12758 tart/c0/cq2
12759 tart/c2
12760 tart/c2/ca1
12761 tart/c2/ca2
12762 tart/c2/ca3
12763 Creating incremental archive
12764 tart/
12765 tart/c0/
12766 tart/c2/
12767 tart/b2
12768 tart/c2/ca3
12769 Extracting main archive
12770 tart/
12771 tart/c0/
12772 tart/c1/
12773 tart/a1
12774 tart/b1
12775 tart/c0/cq1
12776 tart/c0/cq2
12777 tart/c1/ca1
12778 tart/c1/ca2
12779 Extracting incremental archive
12780 tar: Deleting \`tart/a1'
12781 tar: Deleting \`tart/b1'
12782 tart/
12783 tart/b2
12784 tart/c0/
12785 tart/c2/
12786 tart/c2/ca3
12787 Final files:
12788 tart
12789 tart/b2
12790 tart/c0
12791 tart/c0/cq1
12792 tart/c0/cq2
12793 tart/c2
12794 tart/c2/ca1
12795 tart/c2/ca2
12796 tart/c2/ca3
12797 " | $at_diff - "$at_stdout" || at_failed=:
12798 case $at_status in
12799    77) echo 77 > "$at_status_file"; exit 77;;
12800    0) ;;
12801    *) echo "$at_srcdir/listed02.at:31: exit code was $at_status, expected 0"
12802       at_failed=:;;
12803 esac
12804 if $at_failed; then
12805
12806
12807   echo 1 > "$at_status_file"
12808   exit 1
12809 fi
12810
12811 $at_traceon
12812
12813
12814
12815       $at_traceoff
12816       $at_times_p && times >"$at_times_file"
12817     ) 5>&1 2>&1 | eval $at_tee_pipe
12818     at_status=`cat "$at_status_file"`
12819     ;;
12820
12821   31 ) # 31. incr03.at:28: renamed files in incrementals
12822     at_setup_line='incr03.at:28'
12823     at_desc="renamed files in incrementals"
12824     $at_quiet $ECHO_N " 31: renamed files in incrementals                  $ECHO_C"
12825     at_xfail=no
12826       test -f $XFAILFILE && at_xfail=yes
12827     echo "#                             -*- compilation -*-" >> "$at_group_log"
12828     (
12829       echo "31. incr03.at:28: testing ..."
12830       $at_traceon
12831
12832
12833
12834
12835
12836   $at_traceoff
12837 echo "$at_srcdir/incr03.at:31:
12838 mkdir gnu
12839 (cd gnu
12840 TEST_TAR_FORMAT=gnu
12841 export TEST_TAR_FORMAT
12842 TAR_OPTIONS=\"-H gnu\"
12843 export TAR_OPTIONS
12844 rm -rf *
12845
12846
12847 test -z "`sort < /dev/null 2>&1`" || exit 77
12848
12849 mkdir directory
12850 genfile --file=directory/x
12851 genfile --file=directory/y
12852
12853 sleep 1
12854
12855 tar -cf archive.1 -g db directory
12856
12857 mv directory/x directory/z
12858 tar -cf archive.2 -g db directory
12859
12860 mv directory orig
12861
12862 echo Listing of archive.1
12863 tar -tf archive.1 | sort
12864 echo Listing of archive.2
12865 tar -tf archive.2 | sort
12866
12867 echo Directory after first restore
12868 tar -xf archive.1 -g db
12869 find directory | sort
12870
12871 echo Directory after second restore
12872 tar -xf archive.2 -g db
12873 find directory | sort
12874 )"
12875 echo incr03.at:31 >"$at_check_line_file"
12876
12877 at_trace_this=
12878 if test -n "$at_traceon"; then
12879     echo 'Not enabling shell tracing (command contains an embedded newline)'
12880 fi
12881
12882 if test -n "$at_trace_this"; then
12883     ( $at_traceon;
12884 mkdir gnu
12885 (cd gnu
12886 TEST_TAR_FORMAT=gnu
12887 export TEST_TAR_FORMAT
12888 TAR_OPTIONS="-H gnu"
12889 export TAR_OPTIONS
12890 rm -rf *
12891
12892
12893 test -z "`sort < /dev/null 2>&1`" || exit 77
12894
12895 mkdir directory
12896 genfile --file=directory/x
12897 genfile --file=directory/y
12898
12899 sleep 1
12900
12901 tar -cf archive.1 -g db directory
12902
12903 mv directory/x directory/z
12904 tar -cf archive.2 -g db directory
12905
12906 mv directory orig
12907
12908 echo Listing of archive.1
12909 tar -tf archive.1 | sort
12910 echo Listing of archive.2
12911 tar -tf archive.2 | sort
12912
12913 echo Directory after first restore
12914 tar -xf archive.1 -g db
12915 find directory | sort
12916
12917 echo Directory after second restore
12918 tar -xf archive.2 -g db
12919 find directory | sort
12920 ) ) >"$at_stdout" 2>"$at_stder1"
12921     at_status=$?
12922     grep '^ *+' "$at_stder1" >&2
12923     grep -v '^ *+' "$at_stder1" >"$at_stderr"
12924 else
12925     ( :;
12926 mkdir gnu
12927 (cd gnu
12928 TEST_TAR_FORMAT=gnu
12929 export TEST_TAR_FORMAT
12930 TAR_OPTIONS="-H gnu"
12931 export TAR_OPTIONS
12932 rm -rf *
12933
12934
12935 test -z "`sort < /dev/null 2>&1`" || exit 77
12936
12937 mkdir directory
12938 genfile --file=directory/x
12939 genfile --file=directory/y
12940
12941 sleep 1
12942
12943 tar -cf archive.1 -g db directory
12944
12945 mv directory/x directory/z
12946 tar -cf archive.2 -g db directory
12947
12948 mv directory orig
12949
12950 echo Listing of archive.1
12951 tar -tf archive.1 | sort
12952 echo Listing of archive.2
12953 tar -tf archive.2 | sort
12954
12955 echo Directory after first restore
12956 tar -xf archive.1 -g db
12957 find directory | sort
12958
12959 echo Directory after second restore
12960 tar -xf archive.2 -g db
12961 find directory | sort
12962 ) ) >"$at_stdout" 2>"$at_stderr"
12963     at_status=$?
12964 fi
12965
12966 at_failed=false
12967 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
12968 echo >>"$at_stdout"; echo "Listing of archive.1
12969 directory/
12970 directory/x
12971 directory/y
12972 Listing of archive.2
12973 directory/
12974 directory/z
12975 Directory after first restore
12976 directory
12977 directory/x
12978 directory/y
12979 Directory after second restore
12980 directory
12981 directory/y
12982 directory/z
12983 " | $at_diff - "$at_stdout" || at_failed=:
12984 case $at_status in
12985    77) echo 77 > "$at_status_file"; exit 77;;
12986    0) ;;
12987    *) echo "$at_srcdir/incr03.at:31: exit code was $at_status, expected 0"
12988       at_failed=:;;
12989 esac
12990 if $at_failed; then
12991
12992
12993   echo 1 > "$at_status_file"
12994   exit 1
12995 fi
12996
12997 $at_traceon
12998 $at_traceoff
12999 echo "$at_srcdir/incr03.at:31:
13000 mkdir oldgnu
13001 (cd oldgnu
13002 TEST_TAR_FORMAT=oldgnu
13003 export TEST_TAR_FORMAT
13004 TAR_OPTIONS=\"-H oldgnu\"
13005 export TAR_OPTIONS
13006 rm -rf *
13007
13008
13009 test -z "`sort < /dev/null 2>&1`" || exit 77
13010
13011 mkdir directory
13012 genfile --file=directory/x
13013 genfile --file=directory/y
13014
13015 sleep 1
13016
13017 tar -cf archive.1 -g db directory
13018
13019 mv directory/x directory/z
13020 tar -cf archive.2 -g db directory
13021
13022 mv directory orig
13023
13024 echo Listing of archive.1
13025 tar -tf archive.1 | sort
13026 echo Listing of archive.2
13027 tar -tf archive.2 | sort
13028
13029 echo Directory after first restore
13030 tar -xf archive.1 -g db
13031 find directory | sort
13032
13033 echo Directory after second restore
13034 tar -xf archive.2 -g db
13035 find directory | sort
13036 )"
13037 echo incr03.at:31 >"$at_check_line_file"
13038
13039 at_trace_this=
13040 if test -n "$at_traceon"; then
13041     echo 'Not enabling shell tracing (command contains an embedded newline)'
13042 fi
13043
13044 if test -n "$at_trace_this"; then
13045     ( $at_traceon;
13046 mkdir oldgnu
13047 (cd oldgnu
13048 TEST_TAR_FORMAT=oldgnu
13049 export TEST_TAR_FORMAT
13050 TAR_OPTIONS="-H oldgnu"
13051 export TAR_OPTIONS
13052 rm -rf *
13053
13054
13055 test -z "`sort < /dev/null 2>&1`" || exit 77
13056
13057 mkdir directory
13058 genfile --file=directory/x
13059 genfile --file=directory/y
13060
13061 sleep 1
13062
13063 tar -cf archive.1 -g db directory
13064
13065 mv directory/x directory/z
13066 tar -cf archive.2 -g db directory
13067
13068 mv directory orig
13069
13070 echo Listing of archive.1
13071 tar -tf archive.1 | sort
13072 echo Listing of archive.2
13073 tar -tf archive.2 | sort
13074
13075 echo Directory after first restore
13076 tar -xf archive.1 -g db
13077 find directory | sort
13078
13079 echo Directory after second restore
13080 tar -xf archive.2 -g db
13081 find directory | sort
13082 ) ) >"$at_stdout" 2>"$at_stder1"
13083     at_status=$?
13084     grep '^ *+' "$at_stder1" >&2
13085     grep -v '^ *+' "$at_stder1" >"$at_stderr"
13086 else
13087     ( :;
13088 mkdir oldgnu
13089 (cd oldgnu
13090 TEST_TAR_FORMAT=oldgnu
13091 export TEST_TAR_FORMAT
13092 TAR_OPTIONS="-H oldgnu"
13093 export TAR_OPTIONS
13094 rm -rf *
13095
13096
13097 test -z "`sort < /dev/null 2>&1`" || exit 77
13098
13099 mkdir directory
13100 genfile --file=directory/x
13101 genfile --file=directory/y
13102
13103 sleep 1
13104
13105 tar -cf archive.1 -g db directory
13106
13107 mv directory/x directory/z
13108 tar -cf archive.2 -g db directory
13109
13110 mv directory orig
13111
13112 echo Listing of archive.1
13113 tar -tf archive.1 | sort
13114 echo Listing of archive.2
13115 tar -tf archive.2 | sort
13116
13117 echo Directory after first restore
13118 tar -xf archive.1 -g db
13119 find directory | sort
13120
13121 echo Directory after second restore
13122 tar -xf archive.2 -g db
13123 find directory | sort
13124 ) ) >"$at_stdout" 2>"$at_stderr"
13125     at_status=$?
13126 fi
13127
13128 at_failed=false
13129 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
13130 echo >>"$at_stdout"; echo "Listing of archive.1
13131 directory/
13132 directory/x
13133 directory/y
13134 Listing of archive.2
13135 directory/
13136 directory/z
13137 Directory after first restore
13138 directory
13139 directory/x
13140 directory/y
13141 Directory after second restore
13142 directory
13143 directory/y
13144 directory/z
13145 " | $at_diff - "$at_stdout" || at_failed=:
13146 case $at_status in
13147    77) echo 77 > "$at_status_file"; exit 77;;
13148    0) ;;
13149    *) echo "$at_srcdir/incr03.at:31: exit code was $at_status, expected 0"
13150       at_failed=:;;
13151 esac
13152 if $at_failed; then
13153
13154
13155   echo 1 > "$at_status_file"
13156   exit 1
13157 fi
13158
13159 $at_traceon
13160 $at_traceoff
13161 echo "$at_srcdir/incr03.at:31:
13162 mkdir posix
13163 (cd posix
13164 TEST_TAR_FORMAT=posix
13165 export TEST_TAR_FORMAT
13166 TAR_OPTIONS=\"-H posix\"
13167 export TAR_OPTIONS
13168 rm -rf *
13169
13170
13171 test -z "`sort < /dev/null 2>&1`" || exit 77
13172
13173 mkdir directory
13174 genfile --file=directory/x
13175 genfile --file=directory/y
13176
13177 sleep 1
13178
13179 tar -cf archive.1 -g db directory
13180
13181 mv directory/x directory/z
13182 tar -cf archive.2 -g db directory
13183
13184 mv directory orig
13185
13186 echo Listing of archive.1
13187 tar -tf archive.1 | sort
13188 echo Listing of archive.2
13189 tar -tf archive.2 | sort
13190
13191 echo Directory after first restore
13192 tar -xf archive.1 -g db
13193 find directory | sort
13194
13195 echo Directory after second restore
13196 tar -xf archive.2 -g db
13197 find directory | sort
13198 )"
13199 echo incr03.at:31 >"$at_check_line_file"
13200
13201 at_trace_this=
13202 if test -n "$at_traceon"; then
13203     echo 'Not enabling shell tracing (command contains an embedded newline)'
13204 fi
13205
13206 if test -n "$at_trace_this"; then
13207     ( $at_traceon;
13208 mkdir posix
13209 (cd posix
13210 TEST_TAR_FORMAT=posix
13211 export TEST_TAR_FORMAT
13212 TAR_OPTIONS="-H posix"
13213 export TAR_OPTIONS
13214 rm -rf *
13215
13216
13217 test -z "`sort < /dev/null 2>&1`" || exit 77
13218
13219 mkdir directory
13220 genfile --file=directory/x
13221 genfile --file=directory/y
13222
13223 sleep 1
13224
13225 tar -cf archive.1 -g db directory
13226
13227 mv directory/x directory/z
13228 tar -cf archive.2 -g db directory
13229
13230 mv directory orig
13231
13232 echo Listing of archive.1
13233 tar -tf archive.1 | sort
13234 echo Listing of archive.2
13235 tar -tf archive.2 | sort
13236
13237 echo Directory after first restore
13238 tar -xf archive.1 -g db
13239 find directory | sort
13240
13241 echo Directory after second restore
13242 tar -xf archive.2 -g db
13243 find directory | sort
13244 ) ) >"$at_stdout" 2>"$at_stder1"
13245     at_status=$?
13246     grep '^ *+' "$at_stder1" >&2
13247     grep -v '^ *+' "$at_stder1" >"$at_stderr"
13248 else
13249     ( :;
13250 mkdir posix
13251 (cd posix
13252 TEST_TAR_FORMAT=posix
13253 export TEST_TAR_FORMAT
13254 TAR_OPTIONS="-H posix"
13255 export TAR_OPTIONS
13256 rm -rf *
13257
13258
13259 test -z "`sort < /dev/null 2>&1`" || exit 77
13260
13261 mkdir directory
13262 genfile --file=directory/x
13263 genfile --file=directory/y
13264
13265 sleep 1
13266
13267 tar -cf archive.1 -g db directory
13268
13269 mv directory/x directory/z
13270 tar -cf archive.2 -g db directory
13271
13272 mv directory orig
13273
13274 echo Listing of archive.1
13275 tar -tf archive.1 | sort
13276 echo Listing of archive.2
13277 tar -tf archive.2 | sort
13278
13279 echo Directory after first restore
13280 tar -xf archive.1 -g db
13281 find directory | sort
13282
13283 echo Directory after second restore
13284 tar -xf archive.2 -g db
13285 find directory | sort
13286 ) ) >"$at_stdout" 2>"$at_stderr"
13287     at_status=$?
13288 fi
13289
13290 at_failed=false
13291 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
13292 echo >>"$at_stdout"; echo "Listing of archive.1
13293 directory/
13294 directory/x
13295 directory/y
13296 Listing of archive.2
13297 directory/
13298 directory/z
13299 Directory after first restore
13300 directory
13301 directory/x
13302 directory/y
13303 Directory after second restore
13304 directory
13305 directory/y
13306 directory/z
13307 " | $at_diff - "$at_stdout" || at_failed=:
13308 case $at_status in
13309    77) echo 77 > "$at_status_file"; exit 77;;
13310    0) ;;
13311    *) echo "$at_srcdir/incr03.at:31: exit code was $at_status, expected 0"
13312       at_failed=:;;
13313 esac
13314 if $at_failed; then
13315
13316
13317   echo 1 > "$at_status_file"
13318   exit 1
13319 fi
13320
13321 $at_traceon
13322
13323
13324
13325       $at_traceoff
13326       $at_times_p && times >"$at_times_file"
13327     ) 5>&1 2>&1 | eval $at_tee_pipe
13328     at_status=`cat "$at_status_file"`
13329     ;;
13330
13331   32 ) # 32. incr04.at:29: proper icontents initialization
13332     at_setup_line='incr04.at:29'
13333     at_desc="proper icontents initialization"
13334     $at_quiet $ECHO_N " 32: proper icontents initialization                $ECHO_C"
13335     at_xfail=no
13336       test -f $XFAILFILE && at_xfail=yes
13337     echo "#                             -*- compilation -*-" >> "$at_group_log"
13338     (
13339       echo "32. incr04.at:29: testing ..."
13340       $at_traceon
13341
13342
13343
13344
13345
13346
13347
13348   $at_traceoff
13349 echo "$at_srcdir/incr04.at:34:
13350 mkdir gnu
13351 (cd gnu
13352 TEST_TAR_FORMAT=gnu
13353 export TEST_TAR_FORMAT
13354 TAR_OPTIONS=\"-H gnu\"
13355 export TAR_OPTIONS
13356 rm -rf *
13357
13358
13359 install-sh -d a/b >/dev/null  || exit 77
13360 awk 'BEGIN {
13361   for (i=1;i<=142;i++)
13362     printf(\"a/b/one_31_chars_long_file_name_%03d\\n\", i);
13363   }' < /dev/null | genfile --files-from -
13364
13365 sleep 1
13366
13367 echo \"Initial dump\"
13368 tar cvf a0.tar -g a.sna a
13369 mv a/b a/c
13370 echo \"Incremental dump\"
13371 tar cvf a1.tar -g a.sna a
13372 )"
13373 echo incr04.at:34 >"$at_check_line_file"
13374
13375 at_trace_this=
13376 if test -n "$at_traceon"; then
13377     echo 'Not enabling shell tracing (command contains an embedded newline)'
13378 fi
13379
13380 if test -n "$at_trace_this"; then
13381     ( $at_traceon;
13382 mkdir gnu
13383 (cd gnu
13384 TEST_TAR_FORMAT=gnu
13385 export TEST_TAR_FORMAT
13386 TAR_OPTIONS="-H gnu"
13387 export TAR_OPTIONS
13388 rm -rf *
13389
13390
13391 install-sh -d a/b >/dev/null  || exit 77
13392 awk 'BEGIN {
13393   for (i=1;i<=142;i++)
13394     printf("a/b/one_31_chars_long_file_name_%03d\n", i);
13395   }' < /dev/null | genfile --files-from -
13396
13397 sleep 1
13398
13399 echo "Initial dump"
13400 tar cvf a0.tar -g a.sna a
13401 mv a/b a/c
13402 echo "Incremental dump"
13403 tar cvf a1.tar -g a.sna a
13404 ) ) >"$at_stdout" 2>"$at_stder1"
13405     at_status=$?
13406     grep '^ *+' "$at_stder1" >&2
13407     grep -v '^ *+' "$at_stder1" >"$at_stderr"
13408 else
13409     ( :;
13410 mkdir gnu
13411 (cd gnu
13412 TEST_TAR_FORMAT=gnu
13413 export TEST_TAR_FORMAT
13414 TAR_OPTIONS="-H gnu"
13415 export TAR_OPTIONS
13416 rm -rf *
13417
13418
13419 install-sh -d a/b >/dev/null  || exit 77
13420 awk 'BEGIN {
13421   for (i=1;i<=142;i++)
13422     printf("a/b/one_31_chars_long_file_name_%03d\n", i);
13423   }' < /dev/null | genfile --files-from -
13424
13425 sleep 1
13426
13427 echo "Initial dump"
13428 tar cvf a0.tar -g a.sna a
13429 mv a/b a/c
13430 echo "Incremental dump"
13431 tar cvf a1.tar -g a.sna a
13432 ) ) >"$at_stdout" 2>"$at_stderr"
13433     at_status=$?
13434 fi
13435
13436 at_failed=false
13437 echo >>"$at_stderr"; echo "tar: a/b: Directory is new
13438 tar: a/c: Directory has been renamed from \`a/b'
13439 " | $at_diff - "$at_stderr" || at_failed=:
13440 echo >>"$at_stdout"; echo "Initial dump
13441 a/
13442 a/b/
13443 a/b/one_31_chars_long_file_name_001
13444 a/b/one_31_chars_long_file_name_002
13445 a/b/one_31_chars_long_file_name_003
13446 a/b/one_31_chars_long_file_name_004
13447 a/b/one_31_chars_long_file_name_005
13448 a/b/one_31_chars_long_file_name_006
13449 a/b/one_31_chars_long_file_name_007
13450 a/b/one_31_chars_long_file_name_008
13451 a/b/one_31_chars_long_file_name_009
13452 a/b/one_31_chars_long_file_name_010
13453 a/b/one_31_chars_long_file_name_011
13454 a/b/one_31_chars_long_file_name_012
13455 a/b/one_31_chars_long_file_name_013
13456 a/b/one_31_chars_long_file_name_014
13457 a/b/one_31_chars_long_file_name_015
13458 a/b/one_31_chars_long_file_name_016
13459 a/b/one_31_chars_long_file_name_017
13460 a/b/one_31_chars_long_file_name_018
13461 a/b/one_31_chars_long_file_name_019
13462 a/b/one_31_chars_long_file_name_020
13463 a/b/one_31_chars_long_file_name_021
13464 a/b/one_31_chars_long_file_name_022
13465 a/b/one_31_chars_long_file_name_023
13466 a/b/one_31_chars_long_file_name_024
13467 a/b/one_31_chars_long_file_name_025
13468 a/b/one_31_chars_long_file_name_026
13469 a/b/one_31_chars_long_file_name_027
13470 a/b/one_31_chars_long_file_name_028
13471 a/b/one_31_chars_long_file_name_029
13472 a/b/one_31_chars_long_file_name_030
13473 a/b/one_31_chars_long_file_name_031
13474 a/b/one_31_chars_long_file_name_032
13475 a/b/one_31_chars_long_file_name_033
13476 a/b/one_31_chars_long_file_name_034
13477 a/b/one_31_chars_long_file_name_035
13478 a/b/one_31_chars_long_file_name_036
13479 a/b/one_31_chars_long_file_name_037
13480 a/b/one_31_chars_long_file_name_038
13481 a/b/one_31_chars_long_file_name_039
13482 a/b/one_31_chars_long_file_name_040
13483 a/b/one_31_chars_long_file_name_041
13484 a/b/one_31_chars_long_file_name_042
13485 a/b/one_31_chars_long_file_name_043
13486 a/b/one_31_chars_long_file_name_044
13487 a/b/one_31_chars_long_file_name_045
13488 a/b/one_31_chars_long_file_name_046
13489 a/b/one_31_chars_long_file_name_047
13490 a/b/one_31_chars_long_file_name_048
13491 a/b/one_31_chars_long_file_name_049
13492 a/b/one_31_chars_long_file_name_050
13493 a/b/one_31_chars_long_file_name_051
13494 a/b/one_31_chars_long_file_name_052
13495 a/b/one_31_chars_long_file_name_053
13496 a/b/one_31_chars_long_file_name_054
13497 a/b/one_31_chars_long_file_name_055
13498 a/b/one_31_chars_long_file_name_056
13499 a/b/one_31_chars_long_file_name_057
13500 a/b/one_31_chars_long_file_name_058
13501 a/b/one_31_chars_long_file_name_059
13502 a/b/one_31_chars_long_file_name_060
13503 a/b/one_31_chars_long_file_name_061
13504 a/b/one_31_chars_long_file_name_062
13505 a/b/one_31_chars_long_file_name_063
13506 a/b/one_31_chars_long_file_name_064
13507 a/b/one_31_chars_long_file_name_065
13508 a/b/one_31_chars_long_file_name_066
13509 a/b/one_31_chars_long_file_name_067
13510 a/b/one_31_chars_long_file_name_068
13511 a/b/one_31_chars_long_file_name_069
13512 a/b/one_31_chars_long_file_name_070
13513 a/b/one_31_chars_long_file_name_071
13514 a/b/one_31_chars_long_file_name_072
13515 a/b/one_31_chars_long_file_name_073
13516 a/b/one_31_chars_long_file_name_074
13517 a/b/one_31_chars_long_file_name_075
13518 a/b/one_31_chars_long_file_name_076
13519 a/b/one_31_chars_long_file_name_077
13520 a/b/one_31_chars_long_file_name_078
13521 a/b/one_31_chars_long_file_name_079
13522 a/b/one_31_chars_long_file_name_080
13523 a/b/one_31_chars_long_file_name_081
13524 a/b/one_31_chars_long_file_name_082
13525 a/b/one_31_chars_long_file_name_083
13526 a/b/one_31_chars_long_file_name_084
13527 a/b/one_31_chars_long_file_name_085
13528 a/b/one_31_chars_long_file_name_086
13529 a/b/one_31_chars_long_file_name_087
13530 a/b/one_31_chars_long_file_name_088
13531 a/b/one_31_chars_long_file_name_089
13532 a/b/one_31_chars_long_file_name_090
13533 a/b/one_31_chars_long_file_name_091
13534 a/b/one_31_chars_long_file_name_092
13535 a/b/one_31_chars_long_file_name_093
13536 a/b/one_31_chars_long_file_name_094
13537 a/b/one_31_chars_long_file_name_095
13538 a/b/one_31_chars_long_file_name_096
13539 a/b/one_31_chars_long_file_name_097
13540 a/b/one_31_chars_long_file_name_098
13541 a/b/one_31_chars_long_file_name_099
13542 a/b/one_31_chars_long_file_name_100
13543 a/b/one_31_chars_long_file_name_101
13544 a/b/one_31_chars_long_file_name_102
13545 a/b/one_31_chars_long_file_name_103
13546 a/b/one_31_chars_long_file_name_104
13547 a/b/one_31_chars_long_file_name_105
13548 a/b/one_31_chars_long_file_name_106
13549 a/b/one_31_chars_long_file_name_107
13550 a/b/one_31_chars_long_file_name_108
13551 a/b/one_31_chars_long_file_name_109
13552 a/b/one_31_chars_long_file_name_110
13553 a/b/one_31_chars_long_file_name_111
13554 a/b/one_31_chars_long_file_name_112
13555 a/b/one_31_chars_long_file_name_113
13556 a/b/one_31_chars_long_file_name_114
13557 a/b/one_31_chars_long_file_name_115
13558 a/b/one_31_chars_long_file_name_116
13559 a/b/one_31_chars_long_file_name_117
13560 a/b/one_31_chars_long_file_name_118
13561 a/b/one_31_chars_long_file_name_119
13562 a/b/one_31_chars_long_file_name_120
13563 a/b/one_31_chars_long_file_name_121
13564 a/b/one_31_chars_long_file_name_122
13565 a/b/one_31_chars_long_file_name_123
13566 a/b/one_31_chars_long_file_name_124
13567 a/b/one_31_chars_long_file_name_125
13568 a/b/one_31_chars_long_file_name_126
13569 a/b/one_31_chars_long_file_name_127
13570 a/b/one_31_chars_long_file_name_128
13571 a/b/one_31_chars_long_file_name_129
13572 a/b/one_31_chars_long_file_name_130
13573 a/b/one_31_chars_long_file_name_131
13574 a/b/one_31_chars_long_file_name_132
13575 a/b/one_31_chars_long_file_name_133
13576 a/b/one_31_chars_long_file_name_134
13577 a/b/one_31_chars_long_file_name_135
13578 a/b/one_31_chars_long_file_name_136
13579 a/b/one_31_chars_long_file_name_137
13580 a/b/one_31_chars_long_file_name_138
13581 a/b/one_31_chars_long_file_name_139
13582 a/b/one_31_chars_long_file_name_140
13583 a/b/one_31_chars_long_file_name_141
13584 a/b/one_31_chars_long_file_name_142
13585 Incremental dump
13586 a/
13587 a/c/
13588 " | $at_diff - "$at_stdout" || at_failed=:
13589 case $at_status in
13590    77) echo 77 > "$at_status_file"; exit 77;;
13591    0) ;;
13592    *) echo "$at_srcdir/incr04.at:34: exit code was $at_status, expected 0"
13593       at_failed=:;;
13594 esac
13595 if $at_failed; then
13596
13597
13598   echo 1 > "$at_status_file"
13599   exit 1
13600 fi
13601
13602 $at_traceon
13603 $at_traceoff
13604 echo "$at_srcdir/incr04.at:34:
13605 mkdir oldgnu
13606 (cd oldgnu
13607 TEST_TAR_FORMAT=oldgnu
13608 export TEST_TAR_FORMAT
13609 TAR_OPTIONS=\"-H oldgnu\"
13610 export TAR_OPTIONS
13611 rm -rf *
13612
13613
13614 install-sh -d a/b >/dev/null  || exit 77
13615 awk 'BEGIN {
13616   for (i=1;i<=142;i++)
13617     printf(\"a/b/one_31_chars_long_file_name_%03d\\n\", i);
13618   }' < /dev/null | genfile --files-from -
13619
13620 sleep 1
13621
13622 echo \"Initial dump\"
13623 tar cvf a0.tar -g a.sna a
13624 mv a/b a/c
13625 echo \"Incremental dump\"
13626 tar cvf a1.tar -g a.sna a
13627 )"
13628 echo incr04.at:34 >"$at_check_line_file"
13629
13630 at_trace_this=
13631 if test -n "$at_traceon"; then
13632     echo 'Not enabling shell tracing (command contains an embedded newline)'
13633 fi
13634
13635 if test -n "$at_trace_this"; then
13636     ( $at_traceon;
13637 mkdir oldgnu
13638 (cd oldgnu
13639 TEST_TAR_FORMAT=oldgnu
13640 export TEST_TAR_FORMAT
13641 TAR_OPTIONS="-H oldgnu"
13642 export TAR_OPTIONS
13643 rm -rf *
13644
13645
13646 install-sh -d a/b >/dev/null  || exit 77
13647 awk 'BEGIN {
13648   for (i=1;i<=142;i++)
13649     printf("a/b/one_31_chars_long_file_name_%03d\n", i);
13650   }' < /dev/null | genfile --files-from -
13651
13652 sleep 1
13653
13654 echo "Initial dump"
13655 tar cvf a0.tar -g a.sna a
13656 mv a/b a/c
13657 echo "Incremental dump"
13658 tar cvf a1.tar -g a.sna a
13659 ) ) >"$at_stdout" 2>"$at_stder1"
13660     at_status=$?
13661     grep '^ *+' "$at_stder1" >&2
13662     grep -v '^ *+' "$at_stder1" >"$at_stderr"
13663 else
13664     ( :;
13665 mkdir oldgnu
13666 (cd oldgnu
13667 TEST_TAR_FORMAT=oldgnu
13668 export TEST_TAR_FORMAT
13669 TAR_OPTIONS="-H oldgnu"
13670 export TAR_OPTIONS
13671 rm -rf *
13672
13673
13674 install-sh -d a/b >/dev/null  || exit 77
13675 awk 'BEGIN {
13676   for (i=1;i<=142;i++)
13677     printf("a/b/one_31_chars_long_file_name_%03d\n", i);
13678   }' < /dev/null | genfile --files-from -
13679
13680 sleep 1
13681
13682 echo "Initial dump"
13683 tar cvf a0.tar -g a.sna a
13684 mv a/b a/c
13685 echo "Incremental dump"
13686 tar cvf a1.tar -g a.sna a
13687 ) ) >"$at_stdout" 2>"$at_stderr"
13688     at_status=$?
13689 fi
13690
13691 at_failed=false
13692 echo >>"$at_stderr"; echo "tar: a/b: Directory is new
13693 tar: a/c: Directory has been renamed from \`a/b'
13694 " | $at_diff - "$at_stderr" || at_failed=:
13695 echo >>"$at_stdout"; echo "Initial dump
13696 a/
13697 a/b/
13698 a/b/one_31_chars_long_file_name_001
13699 a/b/one_31_chars_long_file_name_002
13700 a/b/one_31_chars_long_file_name_003
13701 a/b/one_31_chars_long_file_name_004
13702 a/b/one_31_chars_long_file_name_005
13703 a/b/one_31_chars_long_file_name_006
13704 a/b/one_31_chars_long_file_name_007
13705 a/b/one_31_chars_long_file_name_008
13706 a/b/one_31_chars_long_file_name_009
13707 a/b/one_31_chars_long_file_name_010
13708 a/b/one_31_chars_long_file_name_011
13709 a/b/one_31_chars_long_file_name_012
13710 a/b/one_31_chars_long_file_name_013
13711 a/b/one_31_chars_long_file_name_014
13712 a/b/one_31_chars_long_file_name_015
13713 a/b/one_31_chars_long_file_name_016
13714 a/b/one_31_chars_long_file_name_017
13715 a/b/one_31_chars_long_file_name_018
13716 a/b/one_31_chars_long_file_name_019
13717 a/b/one_31_chars_long_file_name_020
13718 a/b/one_31_chars_long_file_name_021
13719 a/b/one_31_chars_long_file_name_022
13720 a/b/one_31_chars_long_file_name_023
13721 a/b/one_31_chars_long_file_name_024
13722 a/b/one_31_chars_long_file_name_025
13723 a/b/one_31_chars_long_file_name_026
13724 a/b/one_31_chars_long_file_name_027
13725 a/b/one_31_chars_long_file_name_028
13726 a/b/one_31_chars_long_file_name_029
13727 a/b/one_31_chars_long_file_name_030
13728 a/b/one_31_chars_long_file_name_031
13729 a/b/one_31_chars_long_file_name_032
13730 a/b/one_31_chars_long_file_name_033
13731 a/b/one_31_chars_long_file_name_034
13732 a/b/one_31_chars_long_file_name_035
13733 a/b/one_31_chars_long_file_name_036
13734 a/b/one_31_chars_long_file_name_037
13735 a/b/one_31_chars_long_file_name_038
13736 a/b/one_31_chars_long_file_name_039
13737 a/b/one_31_chars_long_file_name_040
13738 a/b/one_31_chars_long_file_name_041
13739 a/b/one_31_chars_long_file_name_042
13740 a/b/one_31_chars_long_file_name_043
13741 a/b/one_31_chars_long_file_name_044
13742 a/b/one_31_chars_long_file_name_045
13743 a/b/one_31_chars_long_file_name_046
13744 a/b/one_31_chars_long_file_name_047
13745 a/b/one_31_chars_long_file_name_048
13746 a/b/one_31_chars_long_file_name_049
13747 a/b/one_31_chars_long_file_name_050
13748 a/b/one_31_chars_long_file_name_051
13749 a/b/one_31_chars_long_file_name_052
13750 a/b/one_31_chars_long_file_name_053
13751 a/b/one_31_chars_long_file_name_054
13752 a/b/one_31_chars_long_file_name_055
13753 a/b/one_31_chars_long_file_name_056
13754 a/b/one_31_chars_long_file_name_057
13755 a/b/one_31_chars_long_file_name_058
13756 a/b/one_31_chars_long_file_name_059
13757 a/b/one_31_chars_long_file_name_060
13758 a/b/one_31_chars_long_file_name_061
13759 a/b/one_31_chars_long_file_name_062
13760 a/b/one_31_chars_long_file_name_063
13761 a/b/one_31_chars_long_file_name_064
13762 a/b/one_31_chars_long_file_name_065
13763 a/b/one_31_chars_long_file_name_066
13764 a/b/one_31_chars_long_file_name_067
13765 a/b/one_31_chars_long_file_name_068
13766 a/b/one_31_chars_long_file_name_069
13767 a/b/one_31_chars_long_file_name_070
13768 a/b/one_31_chars_long_file_name_071
13769 a/b/one_31_chars_long_file_name_072
13770 a/b/one_31_chars_long_file_name_073
13771 a/b/one_31_chars_long_file_name_074
13772 a/b/one_31_chars_long_file_name_075
13773 a/b/one_31_chars_long_file_name_076
13774 a/b/one_31_chars_long_file_name_077
13775 a/b/one_31_chars_long_file_name_078
13776 a/b/one_31_chars_long_file_name_079
13777 a/b/one_31_chars_long_file_name_080
13778 a/b/one_31_chars_long_file_name_081
13779 a/b/one_31_chars_long_file_name_082
13780 a/b/one_31_chars_long_file_name_083
13781 a/b/one_31_chars_long_file_name_084
13782 a/b/one_31_chars_long_file_name_085
13783 a/b/one_31_chars_long_file_name_086
13784 a/b/one_31_chars_long_file_name_087
13785 a/b/one_31_chars_long_file_name_088
13786 a/b/one_31_chars_long_file_name_089
13787 a/b/one_31_chars_long_file_name_090
13788 a/b/one_31_chars_long_file_name_091
13789 a/b/one_31_chars_long_file_name_092
13790 a/b/one_31_chars_long_file_name_093
13791 a/b/one_31_chars_long_file_name_094
13792 a/b/one_31_chars_long_file_name_095
13793 a/b/one_31_chars_long_file_name_096
13794 a/b/one_31_chars_long_file_name_097
13795 a/b/one_31_chars_long_file_name_098
13796 a/b/one_31_chars_long_file_name_099
13797 a/b/one_31_chars_long_file_name_100
13798 a/b/one_31_chars_long_file_name_101
13799 a/b/one_31_chars_long_file_name_102
13800 a/b/one_31_chars_long_file_name_103
13801 a/b/one_31_chars_long_file_name_104
13802 a/b/one_31_chars_long_file_name_105
13803 a/b/one_31_chars_long_file_name_106
13804 a/b/one_31_chars_long_file_name_107
13805 a/b/one_31_chars_long_file_name_108
13806 a/b/one_31_chars_long_file_name_109
13807 a/b/one_31_chars_long_file_name_110
13808 a/b/one_31_chars_long_file_name_111
13809 a/b/one_31_chars_long_file_name_112
13810 a/b/one_31_chars_long_file_name_113
13811 a/b/one_31_chars_long_file_name_114
13812 a/b/one_31_chars_long_file_name_115
13813 a/b/one_31_chars_long_file_name_116
13814 a/b/one_31_chars_long_file_name_117
13815 a/b/one_31_chars_long_file_name_118
13816 a/b/one_31_chars_long_file_name_119
13817 a/b/one_31_chars_long_file_name_120
13818 a/b/one_31_chars_long_file_name_121
13819 a/b/one_31_chars_long_file_name_122
13820 a/b/one_31_chars_long_file_name_123
13821 a/b/one_31_chars_long_file_name_124
13822 a/b/one_31_chars_long_file_name_125
13823 a/b/one_31_chars_long_file_name_126
13824 a/b/one_31_chars_long_file_name_127
13825 a/b/one_31_chars_long_file_name_128
13826 a/b/one_31_chars_long_file_name_129
13827 a/b/one_31_chars_long_file_name_130
13828 a/b/one_31_chars_long_file_name_131
13829 a/b/one_31_chars_long_file_name_132
13830 a/b/one_31_chars_long_file_name_133
13831 a/b/one_31_chars_long_file_name_134
13832 a/b/one_31_chars_long_file_name_135
13833 a/b/one_31_chars_long_file_name_136
13834 a/b/one_31_chars_long_file_name_137
13835 a/b/one_31_chars_long_file_name_138
13836 a/b/one_31_chars_long_file_name_139
13837 a/b/one_31_chars_long_file_name_140
13838 a/b/one_31_chars_long_file_name_141
13839 a/b/one_31_chars_long_file_name_142
13840 Incremental dump
13841 a/
13842 a/c/
13843 " | $at_diff - "$at_stdout" || at_failed=:
13844 case $at_status in
13845    77) echo 77 > "$at_status_file"; exit 77;;
13846    0) ;;
13847    *) echo "$at_srcdir/incr04.at:34: exit code was $at_status, expected 0"
13848       at_failed=:;;
13849 esac
13850 if $at_failed; then
13851
13852
13853   echo 1 > "$at_status_file"
13854   exit 1
13855 fi
13856
13857 $at_traceon
13858 $at_traceoff
13859 echo "$at_srcdir/incr04.at:34:
13860 mkdir posix
13861 (cd posix
13862 TEST_TAR_FORMAT=posix
13863 export TEST_TAR_FORMAT
13864 TAR_OPTIONS=\"-H posix\"
13865 export TAR_OPTIONS
13866 rm -rf *
13867
13868
13869 install-sh -d a/b >/dev/null  || exit 77
13870 awk 'BEGIN {
13871   for (i=1;i<=142;i++)
13872     printf(\"a/b/one_31_chars_long_file_name_%03d\\n\", i);
13873   }' < /dev/null | genfile --files-from -
13874
13875 sleep 1
13876
13877 echo \"Initial dump\"
13878 tar cvf a0.tar -g a.sna a
13879 mv a/b a/c
13880 echo \"Incremental dump\"
13881 tar cvf a1.tar -g a.sna a
13882 )"
13883 echo incr04.at:34 >"$at_check_line_file"
13884
13885 at_trace_this=
13886 if test -n "$at_traceon"; then
13887     echo 'Not enabling shell tracing (command contains an embedded newline)'
13888 fi
13889
13890 if test -n "$at_trace_this"; then
13891     ( $at_traceon;
13892 mkdir posix
13893 (cd posix
13894 TEST_TAR_FORMAT=posix
13895 export TEST_TAR_FORMAT
13896 TAR_OPTIONS="-H posix"
13897 export TAR_OPTIONS
13898 rm -rf *
13899
13900
13901 install-sh -d a/b >/dev/null  || exit 77
13902 awk 'BEGIN {
13903   for (i=1;i<=142;i++)
13904     printf("a/b/one_31_chars_long_file_name_%03d\n", i);
13905   }' < /dev/null | genfile --files-from -
13906
13907 sleep 1
13908
13909 echo "Initial dump"
13910 tar cvf a0.tar -g a.sna a
13911 mv a/b a/c
13912 echo "Incremental dump"
13913 tar cvf a1.tar -g a.sna a
13914 ) ) >"$at_stdout" 2>"$at_stder1"
13915     at_status=$?
13916     grep '^ *+' "$at_stder1" >&2
13917     grep -v '^ *+' "$at_stder1" >"$at_stderr"
13918 else
13919     ( :;
13920 mkdir posix
13921 (cd posix
13922 TEST_TAR_FORMAT=posix
13923 export TEST_TAR_FORMAT
13924 TAR_OPTIONS="-H posix"
13925 export TAR_OPTIONS
13926 rm -rf *
13927
13928
13929 install-sh -d a/b >/dev/null  || exit 77
13930 awk 'BEGIN {
13931   for (i=1;i<=142;i++)
13932     printf("a/b/one_31_chars_long_file_name_%03d\n", i);
13933   }' < /dev/null | genfile --files-from -
13934
13935 sleep 1
13936
13937 echo "Initial dump"
13938 tar cvf a0.tar -g a.sna a
13939 mv a/b a/c
13940 echo "Incremental dump"
13941 tar cvf a1.tar -g a.sna a
13942 ) ) >"$at_stdout" 2>"$at_stderr"
13943     at_status=$?
13944 fi
13945
13946 at_failed=false
13947 echo >>"$at_stderr"; echo "tar: a/b: Directory is new
13948 tar: a/c: Directory has been renamed from \`a/b'
13949 " | $at_diff - "$at_stderr" || at_failed=:
13950 echo >>"$at_stdout"; echo "Initial dump
13951 a/
13952 a/b/
13953 a/b/one_31_chars_long_file_name_001
13954 a/b/one_31_chars_long_file_name_002
13955 a/b/one_31_chars_long_file_name_003
13956 a/b/one_31_chars_long_file_name_004
13957 a/b/one_31_chars_long_file_name_005
13958 a/b/one_31_chars_long_file_name_006
13959 a/b/one_31_chars_long_file_name_007
13960 a/b/one_31_chars_long_file_name_008
13961 a/b/one_31_chars_long_file_name_009
13962 a/b/one_31_chars_long_file_name_010
13963 a/b/one_31_chars_long_file_name_011
13964 a/b/one_31_chars_long_file_name_012
13965 a/b/one_31_chars_long_file_name_013
13966 a/b/one_31_chars_long_file_name_014
13967 a/b/one_31_chars_long_file_name_015
13968 a/b/one_31_chars_long_file_name_016
13969 a/b/one_31_chars_long_file_name_017
13970 a/b/one_31_chars_long_file_name_018
13971 a/b/one_31_chars_long_file_name_019
13972 a/b/one_31_chars_long_file_name_020
13973 a/b/one_31_chars_long_file_name_021
13974 a/b/one_31_chars_long_file_name_022
13975 a/b/one_31_chars_long_file_name_023
13976 a/b/one_31_chars_long_file_name_024
13977 a/b/one_31_chars_long_file_name_025
13978 a/b/one_31_chars_long_file_name_026
13979 a/b/one_31_chars_long_file_name_027
13980 a/b/one_31_chars_long_file_name_028
13981 a/b/one_31_chars_long_file_name_029
13982 a/b/one_31_chars_long_file_name_030
13983 a/b/one_31_chars_long_file_name_031
13984 a/b/one_31_chars_long_file_name_032
13985 a/b/one_31_chars_long_file_name_033
13986 a/b/one_31_chars_long_file_name_034
13987 a/b/one_31_chars_long_file_name_035
13988 a/b/one_31_chars_long_file_name_036
13989 a/b/one_31_chars_long_file_name_037
13990 a/b/one_31_chars_long_file_name_038
13991 a/b/one_31_chars_long_file_name_039
13992 a/b/one_31_chars_long_file_name_040
13993 a/b/one_31_chars_long_file_name_041
13994 a/b/one_31_chars_long_file_name_042
13995 a/b/one_31_chars_long_file_name_043
13996 a/b/one_31_chars_long_file_name_044
13997 a/b/one_31_chars_long_file_name_045
13998 a/b/one_31_chars_long_file_name_046
13999 a/b/one_31_chars_long_file_name_047
14000 a/b/one_31_chars_long_file_name_048
14001 a/b/one_31_chars_long_file_name_049
14002 a/b/one_31_chars_long_file_name_050
14003 a/b/one_31_chars_long_file_name_051
14004 a/b/one_31_chars_long_file_name_052
14005 a/b/one_31_chars_long_file_name_053
14006 a/b/one_31_chars_long_file_name_054
14007 a/b/one_31_chars_long_file_name_055
14008 a/b/one_31_chars_long_file_name_056
14009 a/b/one_31_chars_long_file_name_057
14010 a/b/one_31_chars_long_file_name_058
14011 a/b/one_31_chars_long_file_name_059
14012 a/b/one_31_chars_long_file_name_060
14013 a/b/one_31_chars_long_file_name_061
14014 a/b/one_31_chars_long_file_name_062
14015 a/b/one_31_chars_long_file_name_063
14016 a/b/one_31_chars_long_file_name_064
14017 a/b/one_31_chars_long_file_name_065
14018 a/b/one_31_chars_long_file_name_066
14019 a/b/one_31_chars_long_file_name_067
14020 a/b/one_31_chars_long_file_name_068
14021 a/b/one_31_chars_long_file_name_069
14022 a/b/one_31_chars_long_file_name_070
14023 a/b/one_31_chars_long_file_name_071
14024 a/b/one_31_chars_long_file_name_072
14025 a/b/one_31_chars_long_file_name_073
14026 a/b/one_31_chars_long_file_name_074
14027 a/b/one_31_chars_long_file_name_075
14028 a/b/one_31_chars_long_file_name_076
14029 a/b/one_31_chars_long_file_name_077
14030 a/b/one_31_chars_long_file_name_078
14031 a/b/one_31_chars_long_file_name_079
14032 a/b/one_31_chars_long_file_name_080
14033 a/b/one_31_chars_long_file_name_081
14034 a/b/one_31_chars_long_file_name_082
14035 a/b/one_31_chars_long_file_name_083
14036 a/b/one_31_chars_long_file_name_084
14037 a/b/one_31_chars_long_file_name_085
14038 a/b/one_31_chars_long_file_name_086
14039 a/b/one_31_chars_long_file_name_087
14040 a/b/one_31_chars_long_file_name_088
14041 a/b/one_31_chars_long_file_name_089
14042 a/b/one_31_chars_long_file_name_090
14043 a/b/one_31_chars_long_file_name_091
14044 a/b/one_31_chars_long_file_name_092
14045 a/b/one_31_chars_long_file_name_093
14046 a/b/one_31_chars_long_file_name_094
14047 a/b/one_31_chars_long_file_name_095
14048 a/b/one_31_chars_long_file_name_096
14049 a/b/one_31_chars_long_file_name_097
14050 a/b/one_31_chars_long_file_name_098
14051 a/b/one_31_chars_long_file_name_099
14052 a/b/one_31_chars_long_file_name_100
14053 a/b/one_31_chars_long_file_name_101
14054 a/b/one_31_chars_long_file_name_102
14055 a/b/one_31_chars_long_file_name_103
14056 a/b/one_31_chars_long_file_name_104
14057 a/b/one_31_chars_long_file_name_105
14058 a/b/one_31_chars_long_file_name_106
14059 a/b/one_31_chars_long_file_name_107
14060 a/b/one_31_chars_long_file_name_108
14061 a/b/one_31_chars_long_file_name_109
14062 a/b/one_31_chars_long_file_name_110
14063 a/b/one_31_chars_long_file_name_111
14064 a/b/one_31_chars_long_file_name_112
14065 a/b/one_31_chars_long_file_name_113
14066 a/b/one_31_chars_long_file_name_114
14067 a/b/one_31_chars_long_file_name_115
14068 a/b/one_31_chars_long_file_name_116
14069 a/b/one_31_chars_long_file_name_117
14070 a/b/one_31_chars_long_file_name_118
14071 a/b/one_31_chars_long_file_name_119
14072 a/b/one_31_chars_long_file_name_120
14073 a/b/one_31_chars_long_file_name_121
14074 a/b/one_31_chars_long_file_name_122
14075 a/b/one_31_chars_long_file_name_123
14076 a/b/one_31_chars_long_file_name_124
14077 a/b/one_31_chars_long_file_name_125
14078 a/b/one_31_chars_long_file_name_126
14079 a/b/one_31_chars_long_file_name_127
14080 a/b/one_31_chars_long_file_name_128
14081 a/b/one_31_chars_long_file_name_129
14082 a/b/one_31_chars_long_file_name_130
14083 a/b/one_31_chars_long_file_name_131
14084 a/b/one_31_chars_long_file_name_132
14085 a/b/one_31_chars_long_file_name_133
14086 a/b/one_31_chars_long_file_name_134
14087 a/b/one_31_chars_long_file_name_135
14088 a/b/one_31_chars_long_file_name_136
14089 a/b/one_31_chars_long_file_name_137
14090 a/b/one_31_chars_long_file_name_138
14091 a/b/one_31_chars_long_file_name_139
14092 a/b/one_31_chars_long_file_name_140
14093 a/b/one_31_chars_long_file_name_141
14094 a/b/one_31_chars_long_file_name_142
14095 Incremental dump
14096 a/
14097 a/c/
14098 " | $at_diff - "$at_stdout" || at_failed=:
14099 case $at_status in
14100    77) echo 77 > "$at_status_file"; exit 77;;
14101    0) ;;
14102    *) echo "$at_srcdir/incr04.at:34: exit code was $at_status, expected 0"
14103       at_failed=:;;
14104 esac
14105 if $at_failed; then
14106
14107
14108   echo 1 > "$at_status_file"
14109   exit 1
14110 fi
14111
14112 $at_traceon
14113
14114
14115
14116       $at_traceoff
14117       $at_times_p && times >"$at_times_file"
14118     ) 5>&1 2>&1 | eval $at_tee_pipe
14119     at_status=`cat "$at_status_file"`
14120     ;;
14121
14122   33 ) # 33. rename01.at:24: renamed dirs in incrementals
14123     at_setup_line='rename01.at:24'
14124     at_desc="renamed dirs in incrementals"
14125     $at_quiet $ECHO_N " 33: renamed dirs in incrementals                   $ECHO_C"
14126     at_xfail=no
14127       test -f $XFAILFILE && at_xfail=yes
14128     echo "#                             -*- compilation -*-" >> "$at_group_log"
14129     (
14130       echo "33. rename01.at:24: testing ..."
14131       $at_traceon
14132
14133
14134
14135
14136
14137   $at_traceoff
14138 echo "$at_srcdir/rename01.at:27:
14139 mkdir gnu
14140 (cd gnu
14141 TEST_TAR_FORMAT=gnu
14142 export TEST_TAR_FORMAT
14143 TAR_OPTIONS=\"-H gnu\"
14144 export TAR_OPTIONS
14145 rm -rf *
14146
14147
14148 test -z "`sort < /dev/null 2>&1`" || exit 77
14149
14150
14151 mkdir foo
14152 genfile --file foo/file1
14153 genfile --file foo/file2
14154 mkdir foo/bar
14155 genfile --file foo/bar/file
14156
14157 echo \"Creating base archive\"
14158 tar -g incr -cf arch.1 -v foo
14159
14160 mv foo/bar foo/baz
14161
14162 echo \"Creating incremental archive\"
14163 tar -g incr -cf arch.2 -v foo
14164
14165 mv foo old
14166
14167 tar xfg arch.1 /dev/null
14168
14169 echo \"Begin directory listing 1\"
14170 find foo | sort
14171 echo \"End directory listing 1\"
14172
14173 tar xfg arch.2 /dev/null
14174 echo Begin directory listing 2
14175 find foo | sort
14176 echo End directory listing 2
14177 )"
14178 echo rename01.at:27 >"$at_check_line_file"
14179
14180 at_trace_this=
14181 if test -n "$at_traceon"; then
14182     echo 'Not enabling shell tracing (command contains an embedded newline)'
14183 fi
14184
14185 if test -n "$at_trace_this"; then
14186     ( $at_traceon;
14187 mkdir gnu
14188 (cd gnu
14189 TEST_TAR_FORMAT=gnu
14190 export TEST_TAR_FORMAT
14191 TAR_OPTIONS="-H gnu"
14192 export TAR_OPTIONS
14193 rm -rf *
14194
14195
14196 test -z "`sort < /dev/null 2>&1`" || exit 77
14197
14198
14199 mkdir foo
14200 genfile --file foo/file1
14201 genfile --file foo/file2
14202 mkdir foo/bar
14203 genfile --file foo/bar/file
14204
14205 echo "Creating base archive"
14206 tar -g incr -cf arch.1 -v foo
14207
14208 mv foo/bar foo/baz
14209
14210 echo "Creating incremental archive"
14211 tar -g incr -cf arch.2 -v foo
14212
14213 mv foo old
14214
14215 tar xfg arch.1 /dev/null
14216
14217 echo "Begin directory listing 1"
14218 find foo | sort
14219 echo "End directory listing 1"
14220
14221 tar xfg arch.2 /dev/null
14222 echo Begin directory listing 2
14223 find foo | sort
14224 echo End directory listing 2
14225 ) ) >"$at_stdout" 2>"$at_stder1"
14226     at_status=$?
14227     grep '^ *+' "$at_stder1" >&2
14228     grep -v '^ *+' "$at_stder1" >"$at_stderr"
14229 else
14230     ( :;
14231 mkdir gnu
14232 (cd gnu
14233 TEST_TAR_FORMAT=gnu
14234 export TEST_TAR_FORMAT
14235 TAR_OPTIONS="-H gnu"
14236 export TAR_OPTIONS
14237 rm -rf *
14238
14239
14240 test -z "`sort < /dev/null 2>&1`" || exit 77
14241
14242
14243 mkdir foo
14244 genfile --file foo/file1
14245 genfile --file foo/file2
14246 mkdir foo/bar
14247 genfile --file foo/bar/file
14248
14249 echo "Creating base archive"
14250 tar -g incr -cf arch.1 -v foo
14251
14252 mv foo/bar foo/baz
14253
14254 echo "Creating incremental archive"
14255 tar -g incr -cf arch.2 -v foo
14256
14257 mv foo old
14258
14259 tar xfg arch.1 /dev/null
14260
14261 echo "Begin directory listing 1"
14262 find foo | sort
14263 echo "End directory listing 1"
14264
14265 tar xfg arch.2 /dev/null
14266 echo Begin directory listing 2
14267 find foo | sort
14268 echo End directory listing 2
14269 ) ) >"$at_stdout" 2>"$at_stderr"
14270     at_status=$?
14271 fi
14272
14273 at_failed=false
14274 echo >>"$at_stderr"; echo "tar: foo/bar: Directory is new
14275 tar: foo/baz: Directory has been renamed from \`foo/bar'
14276 " | $at_diff - "$at_stderr" || at_failed=:
14277 echo >>"$at_stdout"; echo "Creating base archive
14278 foo/
14279 foo/bar/
14280 foo/file1
14281 foo/file2
14282 foo/bar/file
14283 Creating incremental archive
14284 foo/
14285 foo/baz/
14286 Begin directory listing 1
14287 foo
14288 foo/bar
14289 foo/bar/file
14290 foo/file1
14291 foo/file2
14292 End directory listing 1
14293 Begin directory listing 2
14294 foo
14295 foo/baz
14296 foo/baz/file
14297 foo/file1
14298 foo/file2
14299 End directory listing 2
14300 " | $at_diff - "$at_stdout" || at_failed=:
14301 case $at_status in
14302    77) echo 77 > "$at_status_file"; exit 77;;
14303    0) ;;
14304    *) echo "$at_srcdir/rename01.at:27: exit code was $at_status, expected 0"
14305       at_failed=:;;
14306 esac
14307 if $at_failed; then
14308
14309
14310   echo 1 > "$at_status_file"
14311   exit 1
14312 fi
14313
14314 $at_traceon
14315 $at_traceoff
14316 echo "$at_srcdir/rename01.at:27:
14317 mkdir oldgnu
14318 (cd oldgnu
14319 TEST_TAR_FORMAT=oldgnu
14320 export TEST_TAR_FORMAT
14321 TAR_OPTIONS=\"-H oldgnu\"
14322 export TAR_OPTIONS
14323 rm -rf *
14324
14325
14326 test -z "`sort < /dev/null 2>&1`" || exit 77
14327
14328
14329 mkdir foo
14330 genfile --file foo/file1
14331 genfile --file foo/file2
14332 mkdir foo/bar
14333 genfile --file foo/bar/file
14334
14335 echo \"Creating base archive\"
14336 tar -g incr -cf arch.1 -v foo
14337
14338 mv foo/bar foo/baz
14339
14340 echo \"Creating incremental archive\"
14341 tar -g incr -cf arch.2 -v foo
14342
14343 mv foo old
14344
14345 tar xfg arch.1 /dev/null
14346
14347 echo \"Begin directory listing 1\"
14348 find foo | sort
14349 echo \"End directory listing 1\"
14350
14351 tar xfg arch.2 /dev/null
14352 echo Begin directory listing 2
14353 find foo | sort
14354 echo End directory listing 2
14355 )"
14356 echo rename01.at:27 >"$at_check_line_file"
14357
14358 at_trace_this=
14359 if test -n "$at_traceon"; then
14360     echo 'Not enabling shell tracing (command contains an embedded newline)'
14361 fi
14362
14363 if test -n "$at_trace_this"; then
14364     ( $at_traceon;
14365 mkdir oldgnu
14366 (cd oldgnu
14367 TEST_TAR_FORMAT=oldgnu
14368 export TEST_TAR_FORMAT
14369 TAR_OPTIONS="-H oldgnu"
14370 export TAR_OPTIONS
14371 rm -rf *
14372
14373
14374 test -z "`sort < /dev/null 2>&1`" || exit 77
14375
14376
14377 mkdir foo
14378 genfile --file foo/file1
14379 genfile --file foo/file2
14380 mkdir foo/bar
14381 genfile --file foo/bar/file
14382
14383 echo "Creating base archive"
14384 tar -g incr -cf arch.1 -v foo
14385
14386 mv foo/bar foo/baz
14387
14388 echo "Creating incremental archive"
14389 tar -g incr -cf arch.2 -v foo
14390
14391 mv foo old
14392
14393 tar xfg arch.1 /dev/null
14394
14395 echo "Begin directory listing 1"
14396 find foo | sort
14397 echo "End directory listing 1"
14398
14399 tar xfg arch.2 /dev/null
14400 echo Begin directory listing 2
14401 find foo | sort
14402 echo End directory listing 2
14403 ) ) >"$at_stdout" 2>"$at_stder1"
14404     at_status=$?
14405     grep '^ *+' "$at_stder1" >&2
14406     grep -v '^ *+' "$at_stder1" >"$at_stderr"
14407 else
14408     ( :;
14409 mkdir oldgnu
14410 (cd oldgnu
14411 TEST_TAR_FORMAT=oldgnu
14412 export TEST_TAR_FORMAT
14413 TAR_OPTIONS="-H oldgnu"
14414 export TAR_OPTIONS
14415 rm -rf *
14416
14417
14418 test -z "`sort < /dev/null 2>&1`" || exit 77
14419
14420
14421 mkdir foo
14422 genfile --file foo/file1
14423 genfile --file foo/file2
14424 mkdir foo/bar
14425 genfile --file foo/bar/file
14426
14427 echo "Creating base archive"
14428 tar -g incr -cf arch.1 -v foo
14429
14430 mv foo/bar foo/baz
14431
14432 echo "Creating incremental archive"
14433 tar -g incr -cf arch.2 -v foo
14434
14435 mv foo old
14436
14437 tar xfg arch.1 /dev/null
14438
14439 echo "Begin directory listing 1"
14440 find foo | sort
14441 echo "End directory listing 1"
14442
14443 tar xfg arch.2 /dev/null
14444 echo Begin directory listing 2
14445 find foo | sort
14446 echo End directory listing 2
14447 ) ) >"$at_stdout" 2>"$at_stderr"
14448     at_status=$?
14449 fi
14450
14451 at_failed=false
14452 echo >>"$at_stderr"; echo "tar: foo/bar: Directory is new
14453 tar: foo/baz: Directory has been renamed from \`foo/bar'
14454 " | $at_diff - "$at_stderr" || at_failed=:
14455 echo >>"$at_stdout"; echo "Creating base archive
14456 foo/
14457 foo/bar/
14458 foo/file1
14459 foo/file2
14460 foo/bar/file
14461 Creating incremental archive
14462 foo/
14463 foo/baz/
14464 Begin directory listing 1
14465 foo
14466 foo/bar
14467 foo/bar/file
14468 foo/file1
14469 foo/file2
14470 End directory listing 1
14471 Begin directory listing 2
14472 foo
14473 foo/baz
14474 foo/baz/file
14475 foo/file1
14476 foo/file2
14477 End directory listing 2
14478 " | $at_diff - "$at_stdout" || at_failed=:
14479 case $at_status in
14480    77) echo 77 > "$at_status_file"; exit 77;;
14481    0) ;;
14482    *) echo "$at_srcdir/rename01.at:27: exit code was $at_status, expected 0"
14483       at_failed=:;;
14484 esac
14485 if $at_failed; then
14486
14487
14488   echo 1 > "$at_status_file"
14489   exit 1
14490 fi
14491
14492 $at_traceon
14493 $at_traceoff
14494 echo "$at_srcdir/rename01.at:27:
14495 mkdir posix
14496 (cd posix
14497 TEST_TAR_FORMAT=posix
14498 export TEST_TAR_FORMAT
14499 TAR_OPTIONS=\"-H posix\"
14500 export TAR_OPTIONS
14501 rm -rf *
14502
14503
14504 test -z "`sort < /dev/null 2>&1`" || exit 77
14505
14506
14507 mkdir foo
14508 genfile --file foo/file1
14509 genfile --file foo/file2
14510 mkdir foo/bar
14511 genfile --file foo/bar/file
14512
14513 echo \"Creating base archive\"
14514 tar -g incr -cf arch.1 -v foo
14515
14516 mv foo/bar foo/baz
14517
14518 echo \"Creating incremental archive\"
14519 tar -g incr -cf arch.2 -v foo
14520
14521 mv foo old
14522
14523 tar xfg arch.1 /dev/null
14524
14525 echo \"Begin directory listing 1\"
14526 find foo | sort
14527 echo \"End directory listing 1\"
14528
14529 tar xfg arch.2 /dev/null
14530 echo Begin directory listing 2
14531 find foo | sort
14532 echo End directory listing 2
14533 )"
14534 echo rename01.at:27 >"$at_check_line_file"
14535
14536 at_trace_this=
14537 if test -n "$at_traceon"; then
14538     echo 'Not enabling shell tracing (command contains an embedded newline)'
14539 fi
14540
14541 if test -n "$at_trace_this"; then
14542     ( $at_traceon;
14543 mkdir posix
14544 (cd posix
14545 TEST_TAR_FORMAT=posix
14546 export TEST_TAR_FORMAT
14547 TAR_OPTIONS="-H posix"
14548 export TAR_OPTIONS
14549 rm -rf *
14550
14551
14552 test -z "`sort < /dev/null 2>&1`" || exit 77
14553
14554
14555 mkdir foo
14556 genfile --file foo/file1
14557 genfile --file foo/file2
14558 mkdir foo/bar
14559 genfile --file foo/bar/file
14560
14561 echo "Creating base archive"
14562 tar -g incr -cf arch.1 -v foo
14563
14564 mv foo/bar foo/baz
14565
14566 echo "Creating incremental archive"
14567 tar -g incr -cf arch.2 -v foo
14568
14569 mv foo old
14570
14571 tar xfg arch.1 /dev/null
14572
14573 echo "Begin directory listing 1"
14574 find foo | sort
14575 echo "End directory listing 1"
14576
14577 tar xfg arch.2 /dev/null
14578 echo Begin directory listing 2
14579 find foo | sort
14580 echo End directory listing 2
14581 ) ) >"$at_stdout" 2>"$at_stder1"
14582     at_status=$?
14583     grep '^ *+' "$at_stder1" >&2
14584     grep -v '^ *+' "$at_stder1" >"$at_stderr"
14585 else
14586     ( :;
14587 mkdir posix
14588 (cd posix
14589 TEST_TAR_FORMAT=posix
14590 export TEST_TAR_FORMAT
14591 TAR_OPTIONS="-H posix"
14592 export TAR_OPTIONS
14593 rm -rf *
14594
14595
14596 test -z "`sort < /dev/null 2>&1`" || exit 77
14597
14598
14599 mkdir foo
14600 genfile --file foo/file1
14601 genfile --file foo/file2
14602 mkdir foo/bar
14603 genfile --file foo/bar/file
14604
14605 echo "Creating base archive"
14606 tar -g incr -cf arch.1 -v foo
14607
14608 mv foo/bar foo/baz
14609
14610 echo "Creating incremental archive"
14611 tar -g incr -cf arch.2 -v foo
14612
14613 mv foo old
14614
14615 tar xfg arch.1 /dev/null
14616
14617 echo "Begin directory listing 1"
14618 find foo | sort
14619 echo "End directory listing 1"
14620
14621 tar xfg arch.2 /dev/null
14622 echo Begin directory listing 2
14623 find foo | sort
14624 echo End directory listing 2
14625 ) ) >"$at_stdout" 2>"$at_stderr"
14626     at_status=$?
14627 fi
14628
14629 at_failed=false
14630 echo >>"$at_stderr"; echo "tar: foo/bar: Directory is new
14631 tar: foo/baz: Directory has been renamed from \`foo/bar'
14632 " | $at_diff - "$at_stderr" || at_failed=:
14633 echo >>"$at_stdout"; echo "Creating base archive
14634 foo/
14635 foo/bar/
14636 foo/file1
14637 foo/file2
14638 foo/bar/file
14639 Creating incremental archive
14640 foo/
14641 foo/baz/
14642 Begin directory listing 1
14643 foo
14644 foo/bar
14645 foo/bar/file
14646 foo/file1
14647 foo/file2
14648 End directory listing 1
14649 Begin directory listing 2
14650 foo
14651 foo/baz
14652 foo/baz/file
14653 foo/file1
14654 foo/file2
14655 End directory listing 2
14656 " | $at_diff - "$at_stdout" || at_failed=:
14657 case $at_status in
14658    77) echo 77 > "$at_status_file"; exit 77;;
14659    0) ;;
14660    *) echo "$at_srcdir/rename01.at:27: exit code was $at_status, expected 0"
14661       at_failed=:;;
14662 esac
14663 if $at_failed; then
14664
14665
14666   echo 1 > "$at_status_file"
14667   exit 1
14668 fi
14669
14670 $at_traceon
14671
14672
14673
14674       $at_traceoff
14675       $at_times_p && times >"$at_times_file"
14676     ) 5>&1 2>&1 | eval $at_tee_pipe
14677     at_status=`cat "$at_status_file"`
14678     ;;
14679
14680   34 ) # 34. rename02.at:24: move between hierarchies
14681     at_setup_line='rename02.at:24'
14682     at_desc="move between hierarchies"
14683     $at_quiet $ECHO_N " 34: move between hierarchies                       $ECHO_C"
14684     at_xfail=no
14685       test -f $XFAILFILE && at_xfail=yes
14686     echo "#                             -*- compilation -*-" >> "$at_group_log"
14687     (
14688       echo "34. rename02.at:24: testing ..."
14689       $at_traceon
14690
14691
14692
14693
14694
14695   $at_traceoff
14696 echo "$at_srcdir/rename02.at:27:
14697 mkdir gnu
14698 (cd gnu
14699 TEST_TAR_FORMAT=gnu
14700 export TEST_TAR_FORMAT
14701 TAR_OPTIONS=\"-H gnu\"
14702 export TAR_OPTIONS
14703 rm -rf *
14704
14705
14706 test -z "`sort < /dev/null 2>&1`" || exit 77
14707
14708 mkdir foo
14709 genfile --file foo/file1
14710 genfile --file foo/file2
14711 mkdir foo/bar
14712 genfile --file foo/bar/file.r
14713 mkdir foo/bar/baz
14714 genfile --file foo/bar/baz/file.z
14715
14716 sleep 1
14717
14718 echo \"Creating base archive\"
14719 tar -g incr -cf arch.1 -v foo
14720
14721 mv foo/bar/baz foo
14722
14723 echo \"Creating incremental archive\"
14724 tar -g incr -cf arch.2 -v foo
14725
14726 mv foo old
14727
14728 tar xfg arch.1 /dev/null 2>tmperr
14729 sort tmperr >&2
14730
14731 echo \"Begin directory listing 1\"
14732 find foo | sort
14733 echo \"End directory listing 1\"
14734
14735 tar xfgv arch.2 /dev/null
14736 echo Begin directory listing 2
14737 find foo | sort
14738 echo End directory listing 2
14739 )"
14740 echo rename02.at:27 >"$at_check_line_file"
14741
14742 at_trace_this=
14743 if test -n "$at_traceon"; then
14744     echo 'Not enabling shell tracing (command contains an embedded newline)'
14745 fi
14746
14747 if test -n "$at_trace_this"; then
14748     ( $at_traceon;
14749 mkdir gnu
14750 (cd gnu
14751 TEST_TAR_FORMAT=gnu
14752 export TEST_TAR_FORMAT
14753 TAR_OPTIONS="-H gnu"
14754 export TAR_OPTIONS
14755 rm -rf *
14756
14757
14758 test -z "`sort < /dev/null 2>&1`" || exit 77
14759
14760 mkdir foo
14761 genfile --file foo/file1
14762 genfile --file foo/file2
14763 mkdir foo/bar
14764 genfile --file foo/bar/file.r
14765 mkdir foo/bar/baz
14766 genfile --file foo/bar/baz/file.z
14767
14768 sleep 1
14769
14770 echo "Creating base archive"
14771 tar -g incr -cf arch.1 -v foo
14772
14773 mv foo/bar/baz foo
14774
14775 echo "Creating incremental archive"
14776 tar -g incr -cf arch.2 -v foo
14777
14778 mv foo old
14779
14780 tar xfg arch.1 /dev/null 2>tmperr
14781 sort tmperr >&2
14782
14783 echo "Begin directory listing 1"
14784 find foo | sort
14785 echo "End directory listing 1"
14786
14787 tar xfgv arch.2 /dev/null
14788 echo Begin directory listing 2
14789 find foo | sort
14790 echo End directory listing 2
14791 ) ) >"$at_stdout" 2>"$at_stder1"
14792     at_status=$?
14793     grep '^ *+' "$at_stder1" >&2
14794     grep -v '^ *+' "$at_stder1" >"$at_stderr"
14795 else
14796     ( :;
14797 mkdir gnu
14798 (cd gnu
14799 TEST_TAR_FORMAT=gnu
14800 export TEST_TAR_FORMAT
14801 TAR_OPTIONS="-H gnu"
14802 export TAR_OPTIONS
14803 rm -rf *
14804
14805
14806 test -z "`sort < /dev/null 2>&1`" || exit 77
14807
14808 mkdir foo
14809 genfile --file foo/file1
14810 genfile --file foo/file2
14811 mkdir foo/bar
14812 genfile --file foo/bar/file.r
14813 mkdir foo/bar/baz
14814 genfile --file foo/bar/baz/file.z
14815
14816 sleep 1
14817
14818 echo "Creating base archive"
14819 tar -g incr -cf arch.1 -v foo
14820
14821 mv foo/bar/baz foo
14822
14823 echo "Creating incremental archive"
14824 tar -g incr -cf arch.2 -v foo
14825
14826 mv foo old
14827
14828 tar xfg arch.1 /dev/null 2>tmperr
14829 sort tmperr >&2
14830
14831 echo "Begin directory listing 1"
14832 find foo | sort
14833 echo "End directory listing 1"
14834
14835 tar xfgv arch.2 /dev/null
14836 echo Begin directory listing 2
14837 find foo | sort
14838 echo End directory listing 2
14839 ) ) >"$at_stdout" 2>"$at_stderr"
14840     at_status=$?
14841 fi
14842
14843 at_failed=false
14844 echo >>"$at_stderr"; echo "tar: foo/bar: Directory is new
14845 tar: foo/bar/baz: Directory is new
14846 tar: foo/baz: Directory has been renamed from \`foo/bar/baz'
14847 " | $at_diff - "$at_stderr" || at_failed=:
14848 echo >>"$at_stdout"; echo "Creating base archive
14849 foo/
14850 foo/bar/
14851 foo/bar/baz/
14852 foo/file1
14853 foo/file2
14854 foo/bar/file.r
14855 foo/bar/baz/file.z
14856 Creating incremental archive
14857 foo/
14858 foo/bar/
14859 foo/baz/
14860 Begin directory listing 1
14861 foo
14862 foo/bar
14863 foo/bar/baz
14864 foo/bar/baz/file.z
14865 foo/bar/file.r
14866 foo/file1
14867 foo/file2
14868 End directory listing 1
14869 foo/
14870 foo/bar/
14871 foo/baz/
14872 Begin directory listing 2
14873 foo
14874 foo/bar
14875 foo/bar/file.r
14876 foo/baz
14877 foo/baz/file.z
14878 foo/file1
14879 foo/file2
14880 End directory listing 2
14881 " | $at_diff - "$at_stdout" || at_failed=:
14882 case $at_status in
14883    77) echo 77 > "$at_status_file"; exit 77;;
14884    0) ;;
14885    *) echo "$at_srcdir/rename02.at:27: exit code was $at_status, expected 0"
14886       at_failed=:;;
14887 esac
14888 if $at_failed; then
14889
14890
14891   echo 1 > "$at_status_file"
14892   exit 1
14893 fi
14894
14895 $at_traceon
14896 $at_traceoff
14897 echo "$at_srcdir/rename02.at:27:
14898 mkdir oldgnu
14899 (cd oldgnu
14900 TEST_TAR_FORMAT=oldgnu
14901 export TEST_TAR_FORMAT
14902 TAR_OPTIONS=\"-H oldgnu\"
14903 export TAR_OPTIONS
14904 rm -rf *
14905
14906
14907 test -z "`sort < /dev/null 2>&1`" || exit 77
14908
14909 mkdir foo
14910 genfile --file foo/file1
14911 genfile --file foo/file2
14912 mkdir foo/bar
14913 genfile --file foo/bar/file.r
14914 mkdir foo/bar/baz
14915 genfile --file foo/bar/baz/file.z
14916
14917 sleep 1
14918
14919 echo \"Creating base archive\"
14920 tar -g incr -cf arch.1 -v foo
14921
14922 mv foo/bar/baz foo
14923
14924 echo \"Creating incremental archive\"
14925 tar -g incr -cf arch.2 -v foo
14926
14927 mv foo old
14928
14929 tar xfg arch.1 /dev/null 2>tmperr
14930 sort tmperr >&2
14931
14932 echo \"Begin directory listing 1\"
14933 find foo | sort
14934 echo \"End directory listing 1\"
14935
14936 tar xfgv arch.2 /dev/null
14937 echo Begin directory listing 2
14938 find foo | sort
14939 echo End directory listing 2
14940 )"
14941 echo rename02.at:27 >"$at_check_line_file"
14942
14943 at_trace_this=
14944 if test -n "$at_traceon"; then
14945     echo 'Not enabling shell tracing (command contains an embedded newline)'
14946 fi
14947
14948 if test -n "$at_trace_this"; then
14949     ( $at_traceon;
14950 mkdir oldgnu
14951 (cd oldgnu
14952 TEST_TAR_FORMAT=oldgnu
14953 export TEST_TAR_FORMAT
14954 TAR_OPTIONS="-H oldgnu"
14955 export TAR_OPTIONS
14956 rm -rf *
14957
14958
14959 test -z "`sort < /dev/null 2>&1`" || exit 77
14960
14961 mkdir foo
14962 genfile --file foo/file1
14963 genfile --file foo/file2
14964 mkdir foo/bar
14965 genfile --file foo/bar/file.r
14966 mkdir foo/bar/baz
14967 genfile --file foo/bar/baz/file.z
14968
14969 sleep 1
14970
14971 echo "Creating base archive"
14972 tar -g incr -cf arch.1 -v foo
14973
14974 mv foo/bar/baz foo
14975
14976 echo "Creating incremental archive"
14977 tar -g incr -cf arch.2 -v foo
14978
14979 mv foo old
14980
14981 tar xfg arch.1 /dev/null 2>tmperr
14982 sort tmperr >&2
14983
14984 echo "Begin directory listing 1"
14985 find foo | sort
14986 echo "End directory listing 1"
14987
14988 tar xfgv arch.2 /dev/null
14989 echo Begin directory listing 2
14990 find foo | sort
14991 echo End directory listing 2
14992 ) ) >"$at_stdout" 2>"$at_stder1"
14993     at_status=$?
14994     grep '^ *+' "$at_stder1" >&2
14995     grep -v '^ *+' "$at_stder1" >"$at_stderr"
14996 else
14997     ( :;
14998 mkdir oldgnu
14999 (cd oldgnu
15000 TEST_TAR_FORMAT=oldgnu
15001 export TEST_TAR_FORMAT
15002 TAR_OPTIONS="-H oldgnu"
15003 export TAR_OPTIONS
15004 rm -rf *
15005
15006
15007 test -z "`sort < /dev/null 2>&1`" || exit 77
15008
15009 mkdir foo
15010 genfile --file foo/file1
15011 genfile --file foo/file2
15012 mkdir foo/bar
15013 genfile --file foo/bar/file.r
15014 mkdir foo/bar/baz
15015 genfile --file foo/bar/baz/file.z
15016
15017 sleep 1
15018
15019 echo "Creating base archive"
15020 tar -g incr -cf arch.1 -v foo
15021
15022 mv foo/bar/baz foo
15023
15024 echo "Creating incremental archive"
15025 tar -g incr -cf arch.2 -v foo
15026
15027 mv foo old
15028
15029 tar xfg arch.1 /dev/null 2>tmperr
15030 sort tmperr >&2
15031
15032 echo "Begin directory listing 1"
15033 find foo | sort
15034 echo "End directory listing 1"
15035
15036 tar xfgv arch.2 /dev/null
15037 echo Begin directory listing 2
15038 find foo | sort
15039 echo End directory listing 2
15040 ) ) >"$at_stdout" 2>"$at_stderr"
15041     at_status=$?
15042 fi
15043
15044 at_failed=false
15045 echo >>"$at_stderr"; echo "tar: foo/bar: Directory is new
15046 tar: foo/bar/baz: Directory is new
15047 tar: foo/baz: Directory has been renamed from \`foo/bar/baz'
15048 " | $at_diff - "$at_stderr" || at_failed=:
15049 echo >>"$at_stdout"; echo "Creating base archive
15050 foo/
15051 foo/bar/
15052 foo/bar/baz/
15053 foo/file1
15054 foo/file2
15055 foo/bar/file.r
15056 foo/bar/baz/file.z
15057 Creating incremental archive
15058 foo/
15059 foo/bar/
15060 foo/baz/
15061 Begin directory listing 1
15062 foo
15063 foo/bar
15064 foo/bar/baz
15065 foo/bar/baz/file.z
15066 foo/bar/file.r
15067 foo/file1
15068 foo/file2
15069 End directory listing 1
15070 foo/
15071 foo/bar/
15072 foo/baz/
15073 Begin directory listing 2
15074 foo
15075 foo/bar
15076 foo/bar/file.r
15077 foo/baz
15078 foo/baz/file.z
15079 foo/file1
15080 foo/file2
15081 End directory listing 2
15082 " | $at_diff - "$at_stdout" || at_failed=:
15083 case $at_status in
15084    77) echo 77 > "$at_status_file"; exit 77;;
15085    0) ;;
15086    *) echo "$at_srcdir/rename02.at:27: exit code was $at_status, expected 0"
15087       at_failed=:;;
15088 esac
15089 if $at_failed; then
15090
15091
15092   echo 1 > "$at_status_file"
15093   exit 1
15094 fi
15095
15096 $at_traceon
15097 $at_traceoff
15098 echo "$at_srcdir/rename02.at:27:
15099 mkdir posix
15100 (cd posix
15101 TEST_TAR_FORMAT=posix
15102 export TEST_TAR_FORMAT
15103 TAR_OPTIONS=\"-H posix\"
15104 export TAR_OPTIONS
15105 rm -rf *
15106
15107
15108 test -z "`sort < /dev/null 2>&1`" || exit 77
15109
15110 mkdir foo
15111 genfile --file foo/file1
15112 genfile --file foo/file2
15113 mkdir foo/bar
15114 genfile --file foo/bar/file.r
15115 mkdir foo/bar/baz
15116 genfile --file foo/bar/baz/file.z
15117
15118 sleep 1
15119
15120 echo \"Creating base archive\"
15121 tar -g incr -cf arch.1 -v foo
15122
15123 mv foo/bar/baz foo
15124
15125 echo \"Creating incremental archive\"
15126 tar -g incr -cf arch.2 -v foo
15127
15128 mv foo old
15129
15130 tar xfg arch.1 /dev/null 2>tmperr
15131 sort tmperr >&2
15132
15133 echo \"Begin directory listing 1\"
15134 find foo | sort
15135 echo \"End directory listing 1\"
15136
15137 tar xfgv arch.2 /dev/null
15138 echo Begin directory listing 2
15139 find foo | sort
15140 echo End directory listing 2
15141 )"
15142 echo rename02.at:27 >"$at_check_line_file"
15143
15144 at_trace_this=
15145 if test -n "$at_traceon"; then
15146     echo 'Not enabling shell tracing (command contains an embedded newline)'
15147 fi
15148
15149 if test -n "$at_trace_this"; then
15150     ( $at_traceon;
15151 mkdir posix
15152 (cd posix
15153 TEST_TAR_FORMAT=posix
15154 export TEST_TAR_FORMAT
15155 TAR_OPTIONS="-H posix"
15156 export TAR_OPTIONS
15157 rm -rf *
15158
15159
15160 test -z "`sort < /dev/null 2>&1`" || exit 77
15161
15162 mkdir foo
15163 genfile --file foo/file1
15164 genfile --file foo/file2
15165 mkdir foo/bar
15166 genfile --file foo/bar/file.r
15167 mkdir foo/bar/baz
15168 genfile --file foo/bar/baz/file.z
15169
15170 sleep 1
15171
15172 echo "Creating base archive"
15173 tar -g incr -cf arch.1 -v foo
15174
15175 mv foo/bar/baz foo
15176
15177 echo "Creating incremental archive"
15178 tar -g incr -cf arch.2 -v foo
15179
15180 mv foo old
15181
15182 tar xfg arch.1 /dev/null 2>tmperr
15183 sort tmperr >&2
15184
15185 echo "Begin directory listing 1"
15186 find foo | sort
15187 echo "End directory listing 1"
15188
15189 tar xfgv arch.2 /dev/null
15190 echo Begin directory listing 2
15191 find foo | sort
15192 echo End directory listing 2
15193 ) ) >"$at_stdout" 2>"$at_stder1"
15194     at_status=$?
15195     grep '^ *+' "$at_stder1" >&2
15196     grep -v '^ *+' "$at_stder1" >"$at_stderr"
15197 else
15198     ( :;
15199 mkdir posix
15200 (cd posix
15201 TEST_TAR_FORMAT=posix
15202 export TEST_TAR_FORMAT
15203 TAR_OPTIONS="-H posix"
15204 export TAR_OPTIONS
15205 rm -rf *
15206
15207
15208 test -z "`sort < /dev/null 2>&1`" || exit 77
15209
15210 mkdir foo
15211 genfile --file foo/file1
15212 genfile --file foo/file2
15213 mkdir foo/bar
15214 genfile --file foo/bar/file.r
15215 mkdir foo/bar/baz
15216 genfile --file foo/bar/baz/file.z
15217
15218 sleep 1
15219
15220 echo "Creating base archive"
15221 tar -g incr -cf arch.1 -v foo
15222
15223 mv foo/bar/baz foo
15224
15225 echo "Creating incremental archive"
15226 tar -g incr -cf arch.2 -v foo
15227
15228 mv foo old
15229
15230 tar xfg arch.1 /dev/null 2>tmperr
15231 sort tmperr >&2
15232
15233 echo "Begin directory listing 1"
15234 find foo | sort
15235 echo "End directory listing 1"
15236
15237 tar xfgv arch.2 /dev/null
15238 echo Begin directory listing 2
15239 find foo | sort
15240 echo End directory listing 2
15241 ) ) >"$at_stdout" 2>"$at_stderr"
15242     at_status=$?
15243 fi
15244
15245 at_failed=false
15246 echo >>"$at_stderr"; echo "tar: foo/bar: Directory is new
15247 tar: foo/bar/baz: Directory is new
15248 tar: foo/baz: Directory has been renamed from \`foo/bar/baz'
15249 " | $at_diff - "$at_stderr" || at_failed=:
15250 echo >>"$at_stdout"; echo "Creating base archive
15251 foo/
15252 foo/bar/
15253 foo/bar/baz/
15254 foo/file1
15255 foo/file2
15256 foo/bar/file.r
15257 foo/bar/baz/file.z
15258 Creating incremental archive
15259 foo/
15260 foo/bar/
15261 foo/baz/
15262 Begin directory listing 1
15263 foo
15264 foo/bar
15265 foo/bar/baz
15266 foo/bar/baz/file.z
15267 foo/bar/file.r
15268 foo/file1
15269 foo/file2
15270 End directory listing 1
15271 foo/
15272 foo/bar/
15273 foo/baz/
15274 Begin directory listing 2
15275 foo
15276 foo/bar
15277 foo/bar/file.r
15278 foo/baz
15279 foo/baz/file.z
15280 foo/file1
15281 foo/file2
15282 End directory listing 2
15283 " | $at_diff - "$at_stdout" || at_failed=:
15284 case $at_status in
15285    77) echo 77 > "$at_status_file"; exit 77;;
15286    0) ;;
15287    *) echo "$at_srcdir/rename02.at:27: exit code was $at_status, expected 0"
15288       at_failed=:;;
15289 esac
15290 if $at_failed; then
15291
15292
15293   echo 1 > "$at_status_file"
15294   exit 1
15295 fi
15296
15297 $at_traceon
15298
15299
15300
15301       $at_traceoff
15302       $at_times_p && times >"$at_times_file"
15303     ) 5>&1 2>&1 | eval $at_tee_pipe
15304     at_status=`cat "$at_status_file"`
15305     ;;
15306
15307   35 ) # 35. rename03.at:23: cyclic renames
15308     at_setup_line='rename03.at:23'
15309     at_desc="cyclic renames"
15310     $at_quiet $ECHO_N " 35: cyclic renames                                 $ECHO_C"
15311     at_xfail=no
15312       test -f $XFAILFILE && at_xfail=yes
15313     echo "#                             -*- compilation -*-" >> "$at_group_log"
15314     (
15315       echo "35. rename03.at:23: testing ..."
15316       $at_traceon
15317
15318
15319
15320
15321
15322   $at_traceoff
15323 echo "$at_srcdir/rename03.at:26:
15324 mkdir gnu
15325 (cd gnu
15326 TEST_TAR_FORMAT=gnu
15327 export TEST_TAR_FORMAT
15328 TAR_OPTIONS=\"-H gnu\"
15329 export TAR_OPTIONS
15330 rm -rf *
15331
15332
15333 test -z "`sort < /dev/null 2>&1`" || exit 77
15334
15335
15336 mkdir foo
15337 genfile --file foo/file1
15338 genfile --file foo/file2
15339
15340 mkdir foo/a
15341 genfile --file foo/a/filea
15342
15343 mkdir foo/b
15344 genfile --file foo/b/fileb
15345
15346 mkdir foo/c
15347 genfile --file foo/c/filec
15348
15349 sleep 1
15350
15351 echo \"First dump\"
15352 echo \"First dump\">&2
15353 tar -g incr -cf arch.1 -v foo 2>tmperr
15354 sort tmperr >&2
15355
15356 # Shuffle directories:
15357 (cd foo
15358 mv a \$\$
15359 mv c a
15360 mv b c
15361 mv \$\$ b)
15362
15363 echo \"Second dump\"
15364 echo \"Second dump\" >&2
15365 tar -g incr -cf arch.2 -v foo 2>tmperr
15366 sort tmperr >&2
15367
15368 tar xfg arch.1 /dev/null
15369
15370 echo \"Begin directory listing 1\"
15371 find foo | sort
15372 echo \"End directory listing 1\"
15373
15374 tar xfgv arch.2 /dev/null
15375 echo Begin directory listing 2
15376 find foo | sort
15377 echo End directory listing 2
15378 )"
15379 echo rename03.at:26 >"$at_check_line_file"
15380
15381 at_trace_this=
15382 if test -n "$at_traceon"; then
15383     echo 'Not enabling shell tracing (command contains an embedded newline)'
15384 fi
15385
15386 if test -n "$at_trace_this"; then
15387     ( $at_traceon;
15388 mkdir gnu
15389 (cd gnu
15390 TEST_TAR_FORMAT=gnu
15391 export TEST_TAR_FORMAT
15392 TAR_OPTIONS="-H gnu"
15393 export TAR_OPTIONS
15394 rm -rf *
15395
15396
15397 test -z "`sort < /dev/null 2>&1`" || exit 77
15398
15399
15400 mkdir foo
15401 genfile --file foo/file1
15402 genfile --file foo/file2
15403
15404 mkdir foo/a
15405 genfile --file foo/a/filea
15406
15407 mkdir foo/b
15408 genfile --file foo/b/fileb
15409
15410 mkdir foo/c
15411 genfile --file foo/c/filec
15412
15413 sleep 1
15414
15415 echo "First dump"
15416 echo "First dump">&2
15417 tar -g incr -cf arch.1 -v foo 2>tmperr
15418 sort tmperr >&2
15419
15420 # Shuffle directories:
15421 (cd foo
15422 mv a $$
15423 mv c a
15424 mv b c
15425 mv $$ b)
15426
15427 echo "Second dump"
15428 echo "Second dump" >&2
15429 tar -g incr -cf arch.2 -v foo 2>tmperr
15430 sort tmperr >&2
15431
15432 tar xfg arch.1 /dev/null
15433
15434 echo "Begin directory listing 1"
15435 find foo | sort
15436 echo "End directory listing 1"
15437
15438 tar xfgv arch.2 /dev/null
15439 echo Begin directory listing 2
15440 find foo | sort
15441 echo End directory listing 2
15442 ) ) >"$at_stdout" 2>"$at_stder1"
15443     at_status=$?
15444     grep '^ *+' "$at_stder1" >&2
15445     grep -v '^ *+' "$at_stder1" >"$at_stderr"
15446 else
15447     ( :;
15448 mkdir gnu
15449 (cd gnu
15450 TEST_TAR_FORMAT=gnu
15451 export TEST_TAR_FORMAT
15452 TAR_OPTIONS="-H gnu"
15453 export TAR_OPTIONS
15454 rm -rf *
15455
15456
15457 test -z "`sort < /dev/null 2>&1`" || exit 77
15458
15459
15460 mkdir foo
15461 genfile --file foo/file1
15462 genfile --file foo/file2
15463
15464 mkdir foo/a
15465 genfile --file foo/a/filea
15466
15467 mkdir foo/b
15468 genfile --file foo/b/fileb
15469
15470 mkdir foo/c
15471 genfile --file foo/c/filec
15472
15473 sleep 1
15474
15475 echo "First dump"
15476 echo "First dump">&2
15477 tar -g incr -cf arch.1 -v foo 2>tmperr
15478 sort tmperr >&2
15479
15480 # Shuffle directories:
15481 (cd foo
15482 mv a $$
15483 mv c a
15484 mv b c
15485 mv $$ b)
15486
15487 echo "Second dump"
15488 echo "Second dump" >&2
15489 tar -g incr -cf arch.2 -v foo 2>tmperr
15490 sort tmperr >&2
15491
15492 tar xfg arch.1 /dev/null
15493
15494 echo "Begin directory listing 1"
15495 find foo | sort
15496 echo "End directory listing 1"
15497
15498 tar xfgv arch.2 /dev/null
15499 echo Begin directory listing 2
15500 find foo | sort
15501 echo End directory listing 2
15502 ) ) >"$at_stdout" 2>"$at_stderr"
15503     at_status=$?
15504 fi
15505
15506 at_failed=false
15507 echo >>"$at_stderr"; echo "First dump
15508 tar: foo/a: Directory is new
15509 tar: foo/b: Directory is new
15510 tar: foo/c: Directory is new
15511 Second dump
15512 tar: foo/a: Directory has been renamed from \`foo/c'
15513 tar: foo/b: Directory has been renamed from \`foo/a'
15514 tar: foo/c: Directory has been renamed from \`foo/b'
15515 " | $at_diff - "$at_stderr" || at_failed=:
15516 echo >>"$at_stdout"; echo "First dump
15517 foo/
15518 foo/a/
15519 foo/b/
15520 foo/c/
15521 foo/file1
15522 foo/file2
15523 foo/a/filea
15524 foo/b/fileb
15525 foo/c/filec
15526 Second dump
15527 foo/
15528 foo/a/
15529 foo/b/
15530 foo/c/
15531 Begin directory listing 1
15532 foo
15533 foo/a
15534 foo/a/filea
15535 foo/b
15536 foo/b/fileb
15537 foo/c
15538 foo/c/filec
15539 foo/file1
15540 foo/file2
15541 End directory listing 1
15542 foo/
15543 foo/a/
15544 foo/b/
15545 foo/c/
15546 Begin directory listing 2
15547 foo
15548 foo/a
15549 foo/a/filec
15550 foo/b
15551 foo/b/filea
15552 foo/c
15553 foo/c/fileb
15554 foo/file1
15555 foo/file2
15556 End directory listing 2
15557 " | $at_diff - "$at_stdout" || at_failed=:
15558 case $at_status in
15559    77) echo 77 > "$at_status_file"; exit 77;;
15560    0) ;;
15561    *) echo "$at_srcdir/rename03.at:26: exit code was $at_status, expected 0"
15562       at_failed=:;;
15563 esac
15564 if $at_failed; then
15565
15566
15567   echo 1 > "$at_status_file"
15568   exit 1
15569 fi
15570
15571 $at_traceon
15572 $at_traceoff
15573 echo "$at_srcdir/rename03.at:26:
15574 mkdir oldgnu
15575 (cd oldgnu
15576 TEST_TAR_FORMAT=oldgnu
15577 export TEST_TAR_FORMAT
15578 TAR_OPTIONS=\"-H oldgnu\"
15579 export TAR_OPTIONS
15580 rm -rf *
15581
15582
15583 test -z "`sort < /dev/null 2>&1`" || exit 77
15584
15585
15586 mkdir foo
15587 genfile --file foo/file1
15588 genfile --file foo/file2
15589
15590 mkdir foo/a
15591 genfile --file foo/a/filea
15592
15593 mkdir foo/b
15594 genfile --file foo/b/fileb
15595
15596 mkdir foo/c
15597 genfile --file foo/c/filec
15598
15599 sleep 1
15600
15601 echo \"First dump\"
15602 echo \"First dump\">&2
15603 tar -g incr -cf arch.1 -v foo 2>tmperr
15604 sort tmperr >&2
15605
15606 # Shuffle directories:
15607 (cd foo
15608 mv a \$\$
15609 mv c a
15610 mv b c
15611 mv \$\$ b)
15612
15613 echo \"Second dump\"
15614 echo \"Second dump\" >&2
15615 tar -g incr -cf arch.2 -v foo 2>tmperr
15616 sort tmperr >&2
15617
15618 tar xfg arch.1 /dev/null
15619
15620 echo \"Begin directory listing 1\"
15621 find foo | sort
15622 echo \"End directory listing 1\"
15623
15624 tar xfgv arch.2 /dev/null
15625 echo Begin directory listing 2
15626 find foo | sort
15627 echo End directory listing 2
15628 )"
15629 echo rename03.at:26 >"$at_check_line_file"
15630
15631 at_trace_this=
15632 if test -n "$at_traceon"; then
15633     echo 'Not enabling shell tracing (command contains an embedded newline)'
15634 fi
15635
15636 if test -n "$at_trace_this"; then
15637     ( $at_traceon;
15638 mkdir oldgnu
15639 (cd oldgnu
15640 TEST_TAR_FORMAT=oldgnu
15641 export TEST_TAR_FORMAT
15642 TAR_OPTIONS="-H oldgnu"
15643 export TAR_OPTIONS
15644 rm -rf *
15645
15646
15647 test -z "`sort < /dev/null 2>&1`" || exit 77
15648
15649
15650 mkdir foo
15651 genfile --file foo/file1
15652 genfile --file foo/file2
15653
15654 mkdir foo/a
15655 genfile --file foo/a/filea
15656
15657 mkdir foo/b
15658 genfile --file foo/b/fileb
15659
15660 mkdir foo/c
15661 genfile --file foo/c/filec
15662
15663 sleep 1
15664
15665 echo "First dump"
15666 echo "First dump">&2
15667 tar -g incr -cf arch.1 -v foo 2>tmperr
15668 sort tmperr >&2
15669
15670 # Shuffle directories:
15671 (cd foo
15672 mv a $$
15673 mv c a
15674 mv b c
15675 mv $$ b)
15676
15677 echo "Second dump"
15678 echo "Second dump" >&2
15679 tar -g incr -cf arch.2 -v foo 2>tmperr
15680 sort tmperr >&2
15681
15682 tar xfg arch.1 /dev/null
15683
15684 echo "Begin directory listing 1"
15685 find foo | sort
15686 echo "End directory listing 1"
15687
15688 tar xfgv arch.2 /dev/null
15689 echo Begin directory listing 2
15690 find foo | sort
15691 echo End directory listing 2
15692 ) ) >"$at_stdout" 2>"$at_stder1"
15693     at_status=$?
15694     grep '^ *+' "$at_stder1" >&2
15695     grep -v '^ *+' "$at_stder1" >"$at_stderr"
15696 else
15697     ( :;
15698 mkdir oldgnu
15699 (cd oldgnu
15700 TEST_TAR_FORMAT=oldgnu
15701 export TEST_TAR_FORMAT
15702 TAR_OPTIONS="-H oldgnu"
15703 export TAR_OPTIONS
15704 rm -rf *
15705
15706
15707 test -z "`sort < /dev/null 2>&1`" || exit 77
15708
15709
15710 mkdir foo
15711 genfile --file foo/file1
15712 genfile --file foo/file2
15713
15714 mkdir foo/a
15715 genfile --file foo/a/filea
15716
15717 mkdir foo/b
15718 genfile --file foo/b/fileb
15719
15720 mkdir foo/c
15721 genfile --file foo/c/filec
15722
15723 sleep 1
15724
15725 echo "First dump"
15726 echo "First dump">&2
15727 tar -g incr -cf arch.1 -v foo 2>tmperr
15728 sort tmperr >&2
15729
15730 # Shuffle directories:
15731 (cd foo
15732 mv a $$
15733 mv c a
15734 mv b c
15735 mv $$ b)
15736
15737 echo "Second dump"
15738 echo "Second dump" >&2
15739 tar -g incr -cf arch.2 -v foo 2>tmperr
15740 sort tmperr >&2
15741
15742 tar xfg arch.1 /dev/null
15743
15744 echo "Begin directory listing 1"
15745 find foo | sort
15746 echo "End directory listing 1"
15747
15748 tar xfgv arch.2 /dev/null
15749 echo Begin directory listing 2
15750 find foo | sort
15751 echo End directory listing 2
15752 ) ) >"$at_stdout" 2>"$at_stderr"
15753     at_status=$?
15754 fi
15755
15756 at_failed=false
15757 echo >>"$at_stderr"; echo "First dump
15758 tar: foo/a: Directory is new
15759 tar: foo/b: Directory is new
15760 tar: foo/c: Directory is new
15761 Second dump
15762 tar: foo/a: Directory has been renamed from \`foo/c'
15763 tar: foo/b: Directory has been renamed from \`foo/a'
15764 tar: foo/c: Directory has been renamed from \`foo/b'
15765 " | $at_diff - "$at_stderr" || at_failed=:
15766 echo >>"$at_stdout"; echo "First dump
15767 foo/
15768 foo/a/
15769 foo/b/
15770 foo/c/
15771 foo/file1
15772 foo/file2
15773 foo/a/filea
15774 foo/b/fileb
15775 foo/c/filec
15776 Second dump
15777 foo/
15778 foo/a/
15779 foo/b/
15780 foo/c/
15781 Begin directory listing 1
15782 foo
15783 foo/a
15784 foo/a/filea
15785 foo/b
15786 foo/b/fileb
15787 foo/c
15788 foo/c/filec
15789 foo/file1
15790 foo/file2
15791 End directory listing 1
15792 foo/
15793 foo/a/
15794 foo/b/
15795 foo/c/
15796 Begin directory listing 2
15797 foo
15798 foo/a
15799 foo/a/filec
15800 foo/b
15801 foo/b/filea
15802 foo/c
15803 foo/c/fileb
15804 foo/file1
15805 foo/file2
15806 End directory listing 2
15807 " | $at_diff - "$at_stdout" || at_failed=:
15808 case $at_status in
15809    77) echo 77 > "$at_status_file"; exit 77;;
15810    0) ;;
15811    *) echo "$at_srcdir/rename03.at:26: exit code was $at_status, expected 0"
15812       at_failed=:;;
15813 esac
15814 if $at_failed; then
15815
15816
15817   echo 1 > "$at_status_file"
15818   exit 1
15819 fi
15820
15821 $at_traceon
15822 $at_traceoff
15823 echo "$at_srcdir/rename03.at:26:
15824 mkdir posix
15825 (cd posix
15826 TEST_TAR_FORMAT=posix
15827 export TEST_TAR_FORMAT
15828 TAR_OPTIONS=\"-H posix\"
15829 export TAR_OPTIONS
15830 rm -rf *
15831
15832
15833 test -z "`sort < /dev/null 2>&1`" || exit 77
15834
15835
15836 mkdir foo
15837 genfile --file foo/file1
15838 genfile --file foo/file2
15839
15840 mkdir foo/a
15841 genfile --file foo/a/filea
15842
15843 mkdir foo/b
15844 genfile --file foo/b/fileb
15845
15846 mkdir foo/c
15847 genfile --file foo/c/filec
15848
15849 sleep 1
15850
15851 echo \"First dump\"
15852 echo \"First dump\">&2
15853 tar -g incr -cf arch.1 -v foo 2>tmperr
15854 sort tmperr >&2
15855
15856 # Shuffle directories:
15857 (cd foo
15858 mv a \$\$
15859 mv c a
15860 mv b c
15861 mv \$\$ b)
15862
15863 echo \"Second dump\"
15864 echo \"Second dump\" >&2
15865 tar -g incr -cf arch.2 -v foo 2>tmperr
15866 sort tmperr >&2
15867
15868 tar xfg arch.1 /dev/null
15869
15870 echo \"Begin directory listing 1\"
15871 find foo | sort
15872 echo \"End directory listing 1\"
15873
15874 tar xfgv arch.2 /dev/null
15875 echo Begin directory listing 2
15876 find foo | sort
15877 echo End directory listing 2
15878 )"
15879 echo rename03.at:26 >"$at_check_line_file"
15880
15881 at_trace_this=
15882 if test -n "$at_traceon"; then
15883     echo 'Not enabling shell tracing (command contains an embedded newline)'
15884 fi
15885
15886 if test -n "$at_trace_this"; then
15887     ( $at_traceon;
15888 mkdir posix
15889 (cd posix
15890 TEST_TAR_FORMAT=posix
15891 export TEST_TAR_FORMAT
15892 TAR_OPTIONS="-H posix"
15893 export TAR_OPTIONS
15894 rm -rf *
15895
15896
15897 test -z "`sort < /dev/null 2>&1`" || exit 77
15898
15899
15900 mkdir foo
15901 genfile --file foo/file1
15902 genfile --file foo/file2
15903
15904 mkdir foo/a
15905 genfile --file foo/a/filea
15906
15907 mkdir foo/b
15908 genfile --file foo/b/fileb
15909
15910 mkdir foo/c
15911 genfile --file foo/c/filec
15912
15913 sleep 1
15914
15915 echo "First dump"
15916 echo "First dump">&2
15917 tar -g incr -cf arch.1 -v foo 2>tmperr
15918 sort tmperr >&2
15919
15920 # Shuffle directories:
15921 (cd foo
15922 mv a $$
15923 mv c a
15924 mv b c
15925 mv $$ b)
15926
15927 echo "Second dump"
15928 echo "Second dump" >&2
15929 tar -g incr -cf arch.2 -v foo 2>tmperr
15930 sort tmperr >&2
15931
15932 tar xfg arch.1 /dev/null
15933
15934 echo "Begin directory listing 1"
15935 find foo | sort
15936 echo "End directory listing 1"
15937
15938 tar xfgv arch.2 /dev/null
15939 echo Begin directory listing 2
15940 find foo | sort
15941 echo End directory listing 2
15942 ) ) >"$at_stdout" 2>"$at_stder1"
15943     at_status=$?
15944     grep '^ *+' "$at_stder1" >&2
15945     grep -v '^ *+' "$at_stder1" >"$at_stderr"
15946 else
15947     ( :;
15948 mkdir posix
15949 (cd posix
15950 TEST_TAR_FORMAT=posix
15951 export TEST_TAR_FORMAT
15952 TAR_OPTIONS="-H posix"
15953 export TAR_OPTIONS
15954 rm -rf *
15955
15956
15957 test -z "`sort < /dev/null 2>&1`" || exit 77
15958
15959
15960 mkdir foo
15961 genfile --file foo/file1
15962 genfile --file foo/file2
15963
15964 mkdir foo/a
15965 genfile --file foo/a/filea
15966
15967 mkdir foo/b
15968 genfile --file foo/b/fileb
15969
15970 mkdir foo/c
15971 genfile --file foo/c/filec
15972
15973 sleep 1
15974
15975 echo "First dump"
15976 echo "First dump">&2
15977 tar -g incr -cf arch.1 -v foo 2>tmperr
15978 sort tmperr >&2
15979
15980 # Shuffle directories:
15981 (cd foo
15982 mv a $$
15983 mv c a
15984 mv b c
15985 mv $$ b)
15986
15987 echo "Second dump"
15988 echo "Second dump" >&2
15989 tar -g incr -cf arch.2 -v foo 2>tmperr
15990 sort tmperr >&2
15991
15992 tar xfg arch.1 /dev/null
15993
15994 echo "Begin directory listing 1"
15995 find foo | sort
15996 echo "End directory listing 1"
15997
15998 tar xfgv arch.2 /dev/null
15999 echo Begin directory listing 2
16000 find foo | sort
16001 echo End directory listing 2
16002 ) ) >"$at_stdout" 2>"$at_stderr"
16003     at_status=$?
16004 fi
16005
16006 at_failed=false
16007 echo >>"$at_stderr"; echo "First dump
16008 tar: foo/a: Directory is new
16009 tar: foo/b: Directory is new
16010 tar: foo/c: Directory is new
16011 Second dump
16012 tar: foo/a: Directory has been renamed from \`foo/c'
16013 tar: foo/b: Directory has been renamed from \`foo/a'
16014 tar: foo/c: Directory has been renamed from \`foo/b'
16015 " | $at_diff - "$at_stderr" || at_failed=:
16016 echo >>"$at_stdout"; echo "First dump
16017 foo/
16018 foo/a/
16019 foo/b/
16020 foo/c/
16021 foo/file1
16022 foo/file2
16023 foo/a/filea
16024 foo/b/fileb
16025 foo/c/filec
16026 Second dump
16027 foo/
16028 foo/a/
16029 foo/b/
16030 foo/c/
16031 Begin directory listing 1
16032 foo
16033 foo/a
16034 foo/a/filea
16035 foo/b
16036 foo/b/fileb
16037 foo/c
16038 foo/c/filec
16039 foo/file1
16040 foo/file2
16041 End directory listing 1
16042 foo/
16043 foo/a/
16044 foo/b/
16045 foo/c/
16046 Begin directory listing 2
16047 foo
16048 foo/a
16049 foo/a/filec
16050 foo/b
16051 foo/b/filea
16052 foo/c
16053 foo/c/fileb
16054 foo/file1
16055 foo/file2
16056 End directory listing 2
16057 " | $at_diff - "$at_stdout" || at_failed=:
16058 case $at_status in
16059    77) echo 77 > "$at_status_file"; exit 77;;
16060    0) ;;
16061    *) echo "$at_srcdir/rename03.at:26: exit code was $at_status, expected 0"
16062       at_failed=:;;
16063 esac
16064 if $at_failed; then
16065
16066
16067   echo 1 > "$at_status_file"
16068   exit 1
16069 fi
16070
16071 $at_traceon
16072
16073
16074
16075       $at_traceoff
16076       $at_times_p && times >"$at_times_file"
16077     ) 5>&1 2>&1 | eval $at_tee_pipe
16078     at_status=`cat "$at_status_file"`
16079     ;;
16080
16081   36 ) # 36. rename04.at:27: renamed directory containing subdirectories
16082     at_setup_line='rename04.at:27'
16083     at_desc="renamed directory containing subdirectories"
16084     $at_quiet $ECHO_N " 36: renamed directory containing subdirectories    $ECHO_C"
16085     at_xfail=no
16086       test -f $XFAILFILE && at_xfail=yes
16087     echo "#                             -*- compilation -*-" >> "$at_group_log"
16088     (
16089       echo "36. rename04.at:27: testing ..."
16090       $at_traceon
16091
16092
16093
16094
16095
16096   $at_traceoff
16097 echo "$at_srcdir/rename04.at:30:
16098 mkdir gnu
16099 (cd gnu
16100 TEST_TAR_FORMAT=gnu
16101 export TEST_TAR_FORMAT
16102 TAR_OPTIONS=\"-H gnu\"
16103 export TAR_OPTIONS
16104 rm -rf *
16105
16106
16107 test -z "`sort < /dev/null 2>&1`" || exit 77
16108
16109
16110 decho Creating directory structure
16111 mkdir directory
16112 mkdir directory/subdir
16113 genfile --file=directory/file
16114
16115 decho Creating initial archive
16116 tar -cf archive.1 -g db.1 directory
16117
16118 decho Renaming
16119 mv directory dir
16120
16121 decho Creating incremental archive
16122 cp db.1 db.2
16123 tar -cf archive.2 -g db.2 dir
16124
16125 mv dir orig
16126
16127 decho First restore
16128 tar -xf archive.1 -g db.1
16129 find directory | sort
16130
16131 decho Second restore
16132 tar -xf archive.2 -g db.2
16133 find dir | sort
16134 )"
16135 echo rename04.at:30 >"$at_check_line_file"
16136
16137 at_trace_this=
16138 if test -n "$at_traceon"; then
16139     echo 'Not enabling shell tracing (command contains an embedded newline)'
16140 fi
16141
16142 if test -n "$at_trace_this"; then
16143     ( $at_traceon;
16144 mkdir gnu
16145 (cd gnu
16146 TEST_TAR_FORMAT=gnu
16147 export TEST_TAR_FORMAT
16148 TAR_OPTIONS="-H gnu"
16149 export TAR_OPTIONS
16150 rm -rf *
16151
16152
16153 test -z "`sort < /dev/null 2>&1`" || exit 77
16154
16155
16156 decho Creating directory structure
16157 mkdir directory
16158 mkdir directory/subdir
16159 genfile --file=directory/file
16160
16161 decho Creating initial archive
16162 tar -cf archive.1 -g db.1 directory
16163
16164 decho Renaming
16165 mv directory dir
16166
16167 decho Creating incremental archive
16168 cp db.1 db.2
16169 tar -cf archive.2 -g db.2 dir
16170
16171 mv dir orig
16172
16173 decho First restore
16174 tar -xf archive.1 -g db.1
16175 find directory | sort
16176
16177 decho Second restore
16178 tar -xf archive.2 -g db.2
16179 find dir | sort
16180 ) ) >"$at_stdout" 2>"$at_stder1"
16181     at_status=$?
16182     grep '^ *+' "$at_stder1" >&2
16183     grep -v '^ *+' "$at_stder1" >"$at_stderr"
16184 else
16185     ( :;
16186 mkdir gnu
16187 (cd gnu
16188 TEST_TAR_FORMAT=gnu
16189 export TEST_TAR_FORMAT
16190 TAR_OPTIONS="-H gnu"
16191 export TAR_OPTIONS
16192 rm -rf *
16193
16194
16195 test -z "`sort < /dev/null 2>&1`" || exit 77
16196
16197
16198 decho Creating directory structure
16199 mkdir directory
16200 mkdir directory/subdir
16201 genfile --file=directory/file
16202
16203 decho Creating initial archive
16204 tar -cf archive.1 -g db.1 directory
16205
16206 decho Renaming
16207 mv directory dir
16208
16209 decho Creating incremental archive
16210 cp db.1 db.2
16211 tar -cf archive.2 -g db.2 dir
16212
16213 mv dir orig
16214
16215 decho First restore
16216 tar -xf archive.1 -g db.1
16217 find directory | sort
16218
16219 decho Second restore
16220 tar -xf archive.2 -g db.2
16221 find dir | sort
16222 ) ) >"$at_stdout" 2>"$at_stderr"
16223     at_status=$?
16224 fi
16225
16226 at_failed=false
16227 echo >>"$at_stderr"; echo "Creating directory structure
16228 Creating initial archive
16229 Renaming
16230 Creating incremental archive
16231 First restore
16232 Second restore
16233 " | $at_diff - "$at_stderr" || at_failed=:
16234 echo >>"$at_stdout"; echo "Creating directory structure
16235 Creating initial archive
16236 Renaming
16237 Creating incremental archive
16238 First restore
16239 directory
16240 directory/file
16241 directory/subdir
16242 Second restore
16243 dir
16244 dir/subdir
16245 " | $at_diff - "$at_stdout" || at_failed=:
16246 case $at_status in
16247    77) echo 77 > "$at_status_file"; exit 77;;
16248    0) ;;
16249    *) echo "$at_srcdir/rename04.at:30: exit code was $at_status, expected 0"
16250       at_failed=:;;
16251 esac
16252 if $at_failed; then
16253
16254
16255   echo 1 > "$at_status_file"
16256   exit 1
16257 fi
16258
16259 $at_traceon
16260 $at_traceoff
16261 echo "$at_srcdir/rename04.at:30:
16262 mkdir oldgnu
16263 (cd oldgnu
16264 TEST_TAR_FORMAT=oldgnu
16265 export TEST_TAR_FORMAT
16266 TAR_OPTIONS=\"-H oldgnu\"
16267 export TAR_OPTIONS
16268 rm -rf *
16269
16270
16271 test -z "`sort < /dev/null 2>&1`" || exit 77
16272
16273
16274 decho Creating directory structure
16275 mkdir directory
16276 mkdir directory/subdir
16277 genfile --file=directory/file
16278
16279 decho Creating initial archive
16280 tar -cf archive.1 -g db.1 directory
16281
16282 decho Renaming
16283 mv directory dir
16284
16285 decho Creating incremental archive
16286 cp db.1 db.2
16287 tar -cf archive.2 -g db.2 dir
16288
16289 mv dir orig
16290
16291 decho First restore
16292 tar -xf archive.1 -g db.1
16293 find directory | sort
16294
16295 decho Second restore
16296 tar -xf archive.2 -g db.2
16297 find dir | sort
16298 )"
16299 echo rename04.at:30 >"$at_check_line_file"
16300
16301 at_trace_this=
16302 if test -n "$at_traceon"; then
16303     echo 'Not enabling shell tracing (command contains an embedded newline)'
16304 fi
16305
16306 if test -n "$at_trace_this"; then
16307     ( $at_traceon;
16308 mkdir oldgnu
16309 (cd oldgnu
16310 TEST_TAR_FORMAT=oldgnu
16311 export TEST_TAR_FORMAT
16312 TAR_OPTIONS="-H oldgnu"
16313 export TAR_OPTIONS
16314 rm -rf *
16315
16316
16317 test -z "`sort < /dev/null 2>&1`" || exit 77
16318
16319
16320 decho Creating directory structure
16321 mkdir directory
16322 mkdir directory/subdir
16323 genfile --file=directory/file
16324
16325 decho Creating initial archive
16326 tar -cf archive.1 -g db.1 directory
16327
16328 decho Renaming
16329 mv directory dir
16330
16331 decho Creating incremental archive
16332 cp db.1 db.2
16333 tar -cf archive.2 -g db.2 dir
16334
16335 mv dir orig
16336
16337 decho First restore
16338 tar -xf archive.1 -g db.1
16339 find directory | sort
16340
16341 decho Second restore
16342 tar -xf archive.2 -g db.2
16343 find dir | sort
16344 ) ) >"$at_stdout" 2>"$at_stder1"
16345     at_status=$?
16346     grep '^ *+' "$at_stder1" >&2
16347     grep -v '^ *+' "$at_stder1" >"$at_stderr"
16348 else
16349     ( :;
16350 mkdir oldgnu
16351 (cd oldgnu
16352 TEST_TAR_FORMAT=oldgnu
16353 export TEST_TAR_FORMAT
16354 TAR_OPTIONS="-H oldgnu"
16355 export TAR_OPTIONS
16356 rm -rf *
16357
16358
16359 test -z "`sort < /dev/null 2>&1`" || exit 77
16360
16361
16362 decho Creating directory structure
16363 mkdir directory
16364 mkdir directory/subdir
16365 genfile --file=directory/file
16366
16367 decho Creating initial archive
16368 tar -cf archive.1 -g db.1 directory
16369
16370 decho Renaming
16371 mv directory dir
16372
16373 decho Creating incremental archive
16374 cp db.1 db.2
16375 tar -cf archive.2 -g db.2 dir
16376
16377 mv dir orig
16378
16379 decho First restore
16380 tar -xf archive.1 -g db.1
16381 find directory | sort
16382
16383 decho Second restore
16384 tar -xf archive.2 -g db.2
16385 find dir | sort
16386 ) ) >"$at_stdout" 2>"$at_stderr"
16387     at_status=$?
16388 fi
16389
16390 at_failed=false
16391 echo >>"$at_stderr"; echo "Creating directory structure
16392 Creating initial archive
16393 Renaming
16394 Creating incremental archive
16395 First restore
16396 Second restore
16397 " | $at_diff - "$at_stderr" || at_failed=:
16398 echo >>"$at_stdout"; echo "Creating directory structure
16399 Creating initial archive
16400 Renaming
16401 Creating incremental archive
16402 First restore
16403 directory
16404 directory/file
16405 directory/subdir
16406 Second restore
16407 dir
16408 dir/subdir
16409 " | $at_diff - "$at_stdout" || at_failed=:
16410 case $at_status in
16411    77) echo 77 > "$at_status_file"; exit 77;;
16412    0) ;;
16413    *) echo "$at_srcdir/rename04.at:30: exit code was $at_status, expected 0"
16414       at_failed=:;;
16415 esac
16416 if $at_failed; then
16417
16418
16419   echo 1 > "$at_status_file"
16420   exit 1
16421 fi
16422
16423 $at_traceon
16424 $at_traceoff
16425 echo "$at_srcdir/rename04.at:30:
16426 mkdir posix
16427 (cd posix
16428 TEST_TAR_FORMAT=posix
16429 export TEST_TAR_FORMAT
16430 TAR_OPTIONS=\"-H posix\"
16431 export TAR_OPTIONS
16432 rm -rf *
16433
16434
16435 test -z "`sort < /dev/null 2>&1`" || exit 77
16436
16437
16438 decho Creating directory structure
16439 mkdir directory
16440 mkdir directory/subdir
16441 genfile --file=directory/file
16442
16443 decho Creating initial archive
16444 tar -cf archive.1 -g db.1 directory
16445
16446 decho Renaming
16447 mv directory dir
16448
16449 decho Creating incremental archive
16450 cp db.1 db.2
16451 tar -cf archive.2 -g db.2 dir
16452
16453 mv dir orig
16454
16455 decho First restore
16456 tar -xf archive.1 -g db.1
16457 find directory | sort
16458
16459 decho Second restore
16460 tar -xf archive.2 -g db.2
16461 find dir | sort
16462 )"
16463 echo rename04.at:30 >"$at_check_line_file"
16464
16465 at_trace_this=
16466 if test -n "$at_traceon"; then
16467     echo 'Not enabling shell tracing (command contains an embedded newline)'
16468 fi
16469
16470 if test -n "$at_trace_this"; then
16471     ( $at_traceon;
16472 mkdir posix
16473 (cd posix
16474 TEST_TAR_FORMAT=posix
16475 export TEST_TAR_FORMAT
16476 TAR_OPTIONS="-H posix"
16477 export TAR_OPTIONS
16478 rm -rf *
16479
16480
16481 test -z "`sort < /dev/null 2>&1`" || exit 77
16482
16483
16484 decho Creating directory structure
16485 mkdir directory
16486 mkdir directory/subdir
16487 genfile --file=directory/file
16488
16489 decho Creating initial archive
16490 tar -cf archive.1 -g db.1 directory
16491
16492 decho Renaming
16493 mv directory dir
16494
16495 decho Creating incremental archive
16496 cp db.1 db.2
16497 tar -cf archive.2 -g db.2 dir
16498
16499 mv dir orig
16500
16501 decho First restore
16502 tar -xf archive.1 -g db.1
16503 find directory | sort
16504
16505 decho Second restore
16506 tar -xf archive.2 -g db.2
16507 find dir | sort
16508 ) ) >"$at_stdout" 2>"$at_stder1"
16509     at_status=$?
16510     grep '^ *+' "$at_stder1" >&2
16511     grep -v '^ *+' "$at_stder1" >"$at_stderr"
16512 else
16513     ( :;
16514 mkdir posix
16515 (cd posix
16516 TEST_TAR_FORMAT=posix
16517 export TEST_TAR_FORMAT
16518 TAR_OPTIONS="-H posix"
16519 export TAR_OPTIONS
16520 rm -rf *
16521
16522
16523 test -z "`sort < /dev/null 2>&1`" || exit 77
16524
16525
16526 decho Creating directory structure
16527 mkdir directory
16528 mkdir directory/subdir
16529 genfile --file=directory/file
16530
16531 decho Creating initial archive
16532 tar -cf archive.1 -g db.1 directory
16533
16534 decho Renaming
16535 mv directory dir
16536
16537 decho Creating incremental archive
16538 cp db.1 db.2
16539 tar -cf archive.2 -g db.2 dir
16540
16541 mv dir orig
16542
16543 decho First restore
16544 tar -xf archive.1 -g db.1
16545 find directory | sort
16546
16547 decho Second restore
16548 tar -xf archive.2 -g db.2
16549 find dir | sort
16550 ) ) >"$at_stdout" 2>"$at_stderr"
16551     at_status=$?
16552 fi
16553
16554 at_failed=false
16555 echo >>"$at_stderr"; echo "Creating directory structure
16556 Creating initial archive
16557 Renaming
16558 Creating incremental archive
16559 First restore
16560 Second restore
16561 " | $at_diff - "$at_stderr" || at_failed=:
16562 echo >>"$at_stdout"; echo "Creating directory structure
16563 Creating initial archive
16564 Renaming
16565 Creating incremental archive
16566 First restore
16567 directory
16568 directory/file
16569 directory/subdir
16570 Second restore
16571 dir
16572 dir/subdir
16573 " | $at_diff - "$at_stdout" || at_failed=:
16574 case $at_status in
16575    77) echo 77 > "$at_status_file"; exit 77;;
16576    0) ;;
16577    *) echo "$at_srcdir/rename04.at:30: exit code was $at_status, expected 0"
16578       at_failed=:;;
16579 esac
16580 if $at_failed; then
16581
16582
16583   echo 1 > "$at_status_file"
16584   exit 1
16585 fi
16586
16587 $at_traceon
16588
16589
16590
16591       $at_traceoff
16592       $at_times_p && times >"$at_times_file"
16593     ) 5>&1 2>&1 | eval $at_tee_pipe
16594     at_status=`cat "$at_status_file"`
16595     ;;
16596
16597   37 ) # 37. rename05.at:24: renamed subdirectories
16598     at_setup_line='rename05.at:24'
16599     at_desc="renamed subdirectories"
16600     $at_quiet $ECHO_N " 37: renamed subdirectories                         $ECHO_C"
16601     at_xfail=no
16602       test -f $XFAILFILE && at_xfail=yes
16603     echo "#                             -*- compilation -*-" >> "$at_group_log"
16604     (
16605       echo "37. rename05.at:24: testing ..."
16606       $at_traceon
16607
16608
16609
16610
16611
16612   $at_traceoff
16613 echo "$at_srcdir/rename05.at:27:
16614 mkdir gnu
16615 (cd gnu
16616 TEST_TAR_FORMAT=gnu
16617 export TEST_TAR_FORMAT
16618 TAR_OPTIONS=\"-H gnu\"
16619 export TAR_OPTIONS
16620 rm -rf *
16621
16622
16623 test -z "`sort < /dev/null 2>&1`" || exit 77
16624
16625
16626 decho Creating directory structure
16627 mkdir directory
16628 mkdir directory/subdir
16629 genfile --file=directory/file
16630
16631 decho Creating initial archive
16632 tar -cf archive.1 -g db.1 directory
16633
16634 decho Renaming
16635 mv directory/subdir directory/subdir.0
16636 mv directory dir
16637
16638 decho Creating incremental archive
16639 cp db.1 db.2
16640 tar -cf archive.2 -g db.2 dir
16641
16642 mv dir orig
16643
16644 decho First restore
16645 tar -xf archive.1 -g db.1
16646 find directory | sort
16647
16648 decho Second restore
16649 tar -xf archive.2 -g db.2
16650 find dir | sort
16651 )"
16652 echo rename05.at:27 >"$at_check_line_file"
16653
16654 at_trace_this=
16655 if test -n "$at_traceon"; then
16656     echo 'Not enabling shell tracing (command contains an embedded newline)'
16657 fi
16658
16659 if test -n "$at_trace_this"; then
16660     ( $at_traceon;
16661 mkdir gnu
16662 (cd gnu
16663 TEST_TAR_FORMAT=gnu
16664 export TEST_TAR_FORMAT
16665 TAR_OPTIONS="-H gnu"
16666 export TAR_OPTIONS
16667 rm -rf *
16668
16669
16670 test -z "`sort < /dev/null 2>&1`" || exit 77
16671
16672
16673 decho Creating directory structure
16674 mkdir directory
16675 mkdir directory/subdir
16676 genfile --file=directory/file
16677
16678 decho Creating initial archive
16679 tar -cf archive.1 -g db.1 directory
16680
16681 decho Renaming
16682 mv directory/subdir directory/subdir.0
16683 mv directory dir
16684
16685 decho Creating incremental archive
16686 cp db.1 db.2
16687 tar -cf archive.2 -g db.2 dir
16688
16689 mv dir orig
16690
16691 decho First restore
16692 tar -xf archive.1 -g db.1
16693 find directory | sort
16694
16695 decho Second restore
16696 tar -xf archive.2 -g db.2
16697 find dir | sort
16698 ) ) >"$at_stdout" 2>"$at_stder1"
16699     at_status=$?
16700     grep '^ *+' "$at_stder1" >&2
16701     grep -v '^ *+' "$at_stder1" >"$at_stderr"
16702 else
16703     ( :;
16704 mkdir gnu
16705 (cd gnu
16706 TEST_TAR_FORMAT=gnu
16707 export TEST_TAR_FORMAT
16708 TAR_OPTIONS="-H gnu"
16709 export TAR_OPTIONS
16710 rm -rf *
16711
16712
16713 test -z "`sort < /dev/null 2>&1`" || exit 77
16714
16715
16716 decho Creating directory structure
16717 mkdir directory
16718 mkdir directory/subdir
16719 genfile --file=directory/file
16720
16721 decho Creating initial archive
16722 tar -cf archive.1 -g db.1 directory
16723
16724 decho Renaming
16725 mv directory/subdir directory/subdir.0
16726 mv directory dir
16727
16728 decho Creating incremental archive
16729 cp db.1 db.2
16730 tar -cf archive.2 -g db.2 dir
16731
16732 mv dir orig
16733
16734 decho First restore
16735 tar -xf archive.1 -g db.1
16736 find directory | sort
16737
16738 decho Second restore
16739 tar -xf archive.2 -g db.2
16740 find dir | sort
16741 ) ) >"$at_stdout" 2>"$at_stderr"
16742     at_status=$?
16743 fi
16744
16745 at_failed=false
16746 echo >>"$at_stderr"; echo "Creating directory structure
16747 Creating initial archive
16748 Renaming
16749 Creating incremental archive
16750 First restore
16751 Second restore
16752 " | $at_diff - "$at_stderr" || at_failed=:
16753 echo >>"$at_stdout"; echo "Creating directory structure
16754 Creating initial archive
16755 Renaming
16756 Creating incremental archive
16757 First restore
16758 directory
16759 directory/file
16760 directory/subdir
16761 Second restore
16762 dir
16763 dir/subdir.0
16764 " | $at_diff - "$at_stdout" || at_failed=:
16765 case $at_status in
16766    77) echo 77 > "$at_status_file"; exit 77;;
16767    0) ;;
16768    *) echo "$at_srcdir/rename05.at:27: exit code was $at_status, expected 0"
16769       at_failed=:;;
16770 esac
16771 if $at_failed; then
16772
16773
16774   echo 1 > "$at_status_file"
16775   exit 1
16776 fi
16777
16778 $at_traceon
16779 $at_traceoff
16780 echo "$at_srcdir/rename05.at:27:
16781 mkdir oldgnu
16782 (cd oldgnu
16783 TEST_TAR_FORMAT=oldgnu
16784 export TEST_TAR_FORMAT
16785 TAR_OPTIONS=\"-H oldgnu\"
16786 export TAR_OPTIONS
16787 rm -rf *
16788
16789
16790 test -z "`sort < /dev/null 2>&1`" || exit 77
16791
16792
16793 decho Creating directory structure
16794 mkdir directory
16795 mkdir directory/subdir
16796 genfile --file=directory/file
16797
16798 decho Creating initial archive
16799 tar -cf archive.1 -g db.1 directory
16800
16801 decho Renaming
16802 mv directory/subdir directory/subdir.0
16803 mv directory dir
16804
16805 decho Creating incremental archive
16806 cp db.1 db.2
16807 tar -cf archive.2 -g db.2 dir
16808
16809 mv dir orig
16810
16811 decho First restore
16812 tar -xf archive.1 -g db.1
16813 find directory | sort
16814
16815 decho Second restore
16816 tar -xf archive.2 -g db.2
16817 find dir | sort
16818 )"
16819 echo rename05.at:27 >"$at_check_line_file"
16820
16821 at_trace_this=
16822 if test -n "$at_traceon"; then
16823     echo 'Not enabling shell tracing (command contains an embedded newline)'
16824 fi
16825
16826 if test -n "$at_trace_this"; then
16827     ( $at_traceon;
16828 mkdir oldgnu
16829 (cd oldgnu
16830 TEST_TAR_FORMAT=oldgnu
16831 export TEST_TAR_FORMAT
16832 TAR_OPTIONS="-H oldgnu"
16833 export TAR_OPTIONS
16834 rm -rf *
16835
16836
16837 test -z "`sort < /dev/null 2>&1`" || exit 77
16838
16839
16840 decho Creating directory structure
16841 mkdir directory
16842 mkdir directory/subdir
16843 genfile --file=directory/file
16844
16845 decho Creating initial archive
16846 tar -cf archive.1 -g db.1 directory
16847
16848 decho Renaming
16849 mv directory/subdir directory/subdir.0
16850 mv directory dir
16851
16852 decho Creating incremental archive
16853 cp db.1 db.2
16854 tar -cf archive.2 -g db.2 dir
16855
16856 mv dir orig
16857
16858 decho First restore
16859 tar -xf archive.1 -g db.1
16860 find directory | sort
16861
16862 decho Second restore
16863 tar -xf archive.2 -g db.2
16864 find dir | sort
16865 ) ) >"$at_stdout" 2>"$at_stder1"
16866     at_status=$?
16867     grep '^ *+' "$at_stder1" >&2
16868     grep -v '^ *+' "$at_stder1" >"$at_stderr"
16869 else
16870     ( :;
16871 mkdir oldgnu
16872 (cd oldgnu
16873 TEST_TAR_FORMAT=oldgnu
16874 export TEST_TAR_FORMAT
16875 TAR_OPTIONS="-H oldgnu"
16876 export TAR_OPTIONS
16877 rm -rf *
16878
16879
16880 test -z "`sort < /dev/null 2>&1`" || exit 77
16881
16882
16883 decho Creating directory structure
16884 mkdir directory
16885 mkdir directory/subdir
16886 genfile --file=directory/file
16887
16888 decho Creating initial archive
16889 tar -cf archive.1 -g db.1 directory
16890
16891 decho Renaming
16892 mv directory/subdir directory/subdir.0
16893 mv directory dir
16894
16895 decho Creating incremental archive
16896 cp db.1 db.2
16897 tar -cf archive.2 -g db.2 dir
16898
16899 mv dir orig
16900
16901 decho First restore
16902 tar -xf archive.1 -g db.1
16903 find directory | sort
16904
16905 decho Second restore
16906 tar -xf archive.2 -g db.2
16907 find dir | sort
16908 ) ) >"$at_stdout" 2>"$at_stderr"
16909     at_status=$?
16910 fi
16911
16912 at_failed=false
16913 echo >>"$at_stderr"; echo "Creating directory structure
16914 Creating initial archive
16915 Renaming
16916 Creating incremental archive
16917 First restore
16918 Second restore
16919 " | $at_diff - "$at_stderr" || at_failed=:
16920 echo >>"$at_stdout"; echo "Creating directory structure
16921 Creating initial archive
16922 Renaming
16923 Creating incremental archive
16924 First restore
16925 directory
16926 directory/file
16927 directory/subdir
16928 Second restore
16929 dir
16930 dir/subdir.0
16931 " | $at_diff - "$at_stdout" || at_failed=:
16932 case $at_status in
16933    77) echo 77 > "$at_status_file"; exit 77;;
16934    0) ;;
16935    *) echo "$at_srcdir/rename05.at:27: exit code was $at_status, expected 0"
16936       at_failed=:;;
16937 esac
16938 if $at_failed; then
16939
16940
16941   echo 1 > "$at_status_file"
16942   exit 1
16943 fi
16944
16945 $at_traceon
16946 $at_traceoff
16947 echo "$at_srcdir/rename05.at:27:
16948 mkdir posix
16949 (cd posix
16950 TEST_TAR_FORMAT=posix
16951 export TEST_TAR_FORMAT
16952 TAR_OPTIONS=\"-H posix\"
16953 export TAR_OPTIONS
16954 rm -rf *
16955
16956
16957 test -z "`sort < /dev/null 2>&1`" || exit 77
16958
16959
16960 decho Creating directory structure
16961 mkdir directory
16962 mkdir directory/subdir
16963 genfile --file=directory/file
16964
16965 decho Creating initial archive
16966 tar -cf archive.1 -g db.1 directory
16967
16968 decho Renaming
16969 mv directory/subdir directory/subdir.0
16970 mv directory dir
16971
16972 decho Creating incremental archive
16973 cp db.1 db.2
16974 tar -cf archive.2 -g db.2 dir
16975
16976 mv dir orig
16977
16978 decho First restore
16979 tar -xf archive.1 -g db.1
16980 find directory | sort
16981
16982 decho Second restore
16983 tar -xf archive.2 -g db.2
16984 find dir | sort
16985 )"
16986 echo rename05.at:27 >"$at_check_line_file"
16987
16988 at_trace_this=
16989 if test -n "$at_traceon"; then
16990     echo 'Not enabling shell tracing (command contains an embedded newline)'
16991 fi
16992
16993 if test -n "$at_trace_this"; then
16994     ( $at_traceon;
16995 mkdir posix
16996 (cd posix
16997 TEST_TAR_FORMAT=posix
16998 export TEST_TAR_FORMAT
16999 TAR_OPTIONS="-H posix"
17000 export TAR_OPTIONS
17001 rm -rf *
17002
17003
17004 test -z "`sort < /dev/null 2>&1`" || exit 77
17005
17006
17007 decho Creating directory structure
17008 mkdir directory
17009 mkdir directory/subdir
17010 genfile --file=directory/file
17011
17012 decho Creating initial archive
17013 tar -cf archive.1 -g db.1 directory
17014
17015 decho Renaming
17016 mv directory/subdir directory/subdir.0
17017 mv directory dir
17018
17019 decho Creating incremental archive
17020 cp db.1 db.2
17021 tar -cf archive.2 -g db.2 dir
17022
17023 mv dir orig
17024
17025 decho First restore
17026 tar -xf archive.1 -g db.1
17027 find directory | sort
17028
17029 decho Second restore
17030 tar -xf archive.2 -g db.2
17031 find dir | sort
17032 ) ) >"$at_stdout" 2>"$at_stder1"
17033     at_status=$?
17034     grep '^ *+' "$at_stder1" >&2
17035     grep -v '^ *+' "$at_stder1" >"$at_stderr"
17036 else
17037     ( :;
17038 mkdir posix
17039 (cd posix
17040 TEST_TAR_FORMAT=posix
17041 export TEST_TAR_FORMAT
17042 TAR_OPTIONS="-H posix"
17043 export TAR_OPTIONS
17044 rm -rf *
17045
17046
17047 test -z "`sort < /dev/null 2>&1`" || exit 77
17048
17049
17050 decho Creating directory structure
17051 mkdir directory
17052 mkdir directory/subdir
17053 genfile --file=directory/file
17054
17055 decho Creating initial archive
17056 tar -cf archive.1 -g db.1 directory
17057
17058 decho Renaming
17059 mv directory/subdir directory/subdir.0
17060 mv directory dir
17061
17062 decho Creating incremental archive
17063 cp db.1 db.2
17064 tar -cf archive.2 -g db.2 dir
17065
17066 mv dir orig
17067
17068 decho First restore
17069 tar -xf archive.1 -g db.1
17070 find directory | sort
17071
17072 decho Second restore
17073 tar -xf archive.2 -g db.2
17074 find dir | sort
17075 ) ) >"$at_stdout" 2>"$at_stderr"
17076     at_status=$?
17077 fi
17078
17079 at_failed=false
17080 echo >>"$at_stderr"; echo "Creating directory structure
17081 Creating initial archive
17082 Renaming
17083 Creating incremental archive
17084 First restore
17085 Second restore
17086 " | $at_diff - "$at_stderr" || at_failed=:
17087 echo >>"$at_stdout"; echo "Creating directory structure
17088 Creating initial archive
17089 Renaming
17090 Creating incremental archive
17091 First restore
17092 directory
17093 directory/file
17094 directory/subdir
17095 Second restore
17096 dir
17097 dir/subdir.0
17098 " | $at_diff - "$at_stdout" || at_failed=:
17099 case $at_status in
17100    77) echo 77 > "$at_status_file"; exit 77;;
17101    0) ;;
17102    *) echo "$at_srcdir/rename05.at:27: exit code was $at_status, expected 0"
17103       at_failed=:;;
17104 esac
17105 if $at_failed; then
17106
17107
17108   echo 1 > "$at_status_file"
17109   exit 1
17110 fi
17111
17112 $at_traceon
17113
17114
17115
17116       $at_traceoff
17117       $at_times_p && times >"$at_times_file"
17118     ) 5>&1 2>&1 | eval $at_tee_pipe
17119     at_status=`cat "$at_status_file"`
17120     ;;
17121
17122   38 ) # 38. chtype.at:27: changed file types in incrementals
17123     at_setup_line='chtype.at:27'
17124     at_desc="changed file types in incrementals"
17125     $at_quiet $ECHO_N " 38: changed file types in incrementals             $ECHO_C"
17126     at_xfail=no
17127       test -f $XFAILFILE && at_xfail=yes
17128     echo "#                             -*- compilation -*-" >> "$at_group_log"
17129     (
17130       echo "38. chtype.at:27: testing ..."
17131       $at_traceon
17132
17133
17134
17135
17136
17137   $at_traceoff
17138 echo "$at_srcdir/chtype.at:30:
17139 mkdir gnu
17140 (cd gnu
17141 TEST_TAR_FORMAT=gnu
17142 export TEST_TAR_FORMAT
17143 TAR_OPTIONS=\"-H gnu\"
17144 export TAR_OPTIONS
17145 rm -rf *
17146
17147
17148 test -z "`sort < /dev/null 2>&1`" || exit 77
17149
17150
17151 install-sh -d directory/b/c >/dev/null && genfile --file directory/b/c/x || exit 77
17152 mkdir directory/a
17153 genfile --file directory/a/a
17154
17155 echo First backup
17156 tar --create --file=archive.1 --listed-incremental=db.1 directory
17157
17158 sleep 2
17159
17160 # Remove directory b and create a file with this name.
17161 # Previous versions were not able to restore over this file.
17162 rm -r directory/b
17163 genfile --file directory/b
17164 genfile --file directory/a/b
17165
17166 echo Second backup
17167 tar --create --file=archive.2 --listed-incremental=db.2 directory
17168
17169 # Delete a
17170 rm -r directory
17171
17172 echo Restore archive.1
17173 tar -xf archive.1 --listed-incremental=/dev/null
17174 echo Restore archive.2
17175 tar -xf archive.2 --listed-incremental=/dev/null
17176 find directory | sort
17177 )"
17178 echo chtype.at:30 >"$at_check_line_file"
17179
17180 at_trace_this=
17181 if test -n "$at_traceon"; then
17182     echo 'Not enabling shell tracing (command contains an embedded newline)'
17183 fi
17184
17185 if test -n "$at_trace_this"; then
17186     ( $at_traceon;
17187 mkdir gnu
17188 (cd gnu
17189 TEST_TAR_FORMAT=gnu
17190 export TEST_TAR_FORMAT
17191 TAR_OPTIONS="-H gnu"
17192 export TAR_OPTIONS
17193 rm -rf *
17194
17195
17196 test -z "`sort < /dev/null 2>&1`" || exit 77
17197
17198
17199 install-sh -d directory/b/c >/dev/null && genfile --file directory/b/c/x || exit 77
17200 mkdir directory/a
17201 genfile --file directory/a/a
17202
17203 echo First backup
17204 tar --create --file=archive.1 --listed-incremental=db.1 directory
17205
17206 sleep 2
17207
17208 # Remove directory b and create a file with this name.
17209 # Previous versions were not able to restore over this file.
17210 rm -r directory/b
17211 genfile --file directory/b
17212 genfile --file directory/a/b
17213
17214 echo Second backup
17215 tar --create --file=archive.2 --listed-incremental=db.2 directory
17216
17217 # Delete a
17218 rm -r directory
17219
17220 echo Restore archive.1
17221 tar -xf archive.1 --listed-incremental=/dev/null
17222 echo Restore archive.2
17223 tar -xf archive.2 --listed-incremental=/dev/null
17224 find directory | sort
17225 ) ) >"$at_stdout" 2>"$at_stder1"
17226     at_status=$?
17227     grep '^ *+' "$at_stder1" >&2
17228     grep -v '^ *+' "$at_stder1" >"$at_stderr"
17229 else
17230     ( :;
17231 mkdir gnu
17232 (cd gnu
17233 TEST_TAR_FORMAT=gnu
17234 export TEST_TAR_FORMAT
17235 TAR_OPTIONS="-H gnu"
17236 export TAR_OPTIONS
17237 rm -rf *
17238
17239
17240 test -z "`sort < /dev/null 2>&1`" || exit 77
17241
17242
17243 install-sh -d directory/b/c >/dev/null && genfile --file directory/b/c/x || exit 77
17244 mkdir directory/a
17245 genfile --file directory/a/a
17246
17247 echo First backup
17248 tar --create --file=archive.1 --listed-incremental=db.1 directory
17249
17250 sleep 2
17251
17252 # Remove directory b and create a file with this name.
17253 # Previous versions were not able to restore over this file.
17254 rm -r directory/b
17255 genfile --file directory/b
17256 genfile --file directory/a/b
17257
17258 echo Second backup
17259 tar --create --file=archive.2 --listed-incremental=db.2 directory
17260
17261 # Delete a
17262 rm -r directory
17263
17264 echo Restore archive.1
17265 tar -xf archive.1 --listed-incremental=/dev/null
17266 echo Restore archive.2
17267 tar -xf archive.2 --listed-incremental=/dev/null
17268 find directory | sort
17269 ) ) >"$at_stdout" 2>"$at_stderr"
17270     at_status=$?
17271 fi
17272
17273 at_failed=false
17274 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
17275 echo >>"$at_stdout"; echo "First backup
17276 Second backup
17277 Restore archive.1
17278 Restore archive.2
17279 directory
17280 directory/a
17281 directory/a/a
17282 directory/a/b
17283 directory/b
17284 " | $at_diff - "$at_stdout" || at_failed=:
17285 case $at_status in
17286    77) echo 77 > "$at_status_file"; exit 77;;
17287    0) ;;
17288    *) echo "$at_srcdir/chtype.at:30: exit code was $at_status, expected 0"
17289       at_failed=:;;
17290 esac
17291 if $at_failed; then
17292
17293
17294   echo 1 > "$at_status_file"
17295   exit 1
17296 fi
17297
17298 $at_traceon
17299 $at_traceoff
17300 echo "$at_srcdir/chtype.at:30:
17301 mkdir oldgnu
17302 (cd oldgnu
17303 TEST_TAR_FORMAT=oldgnu
17304 export TEST_TAR_FORMAT
17305 TAR_OPTIONS=\"-H oldgnu\"
17306 export TAR_OPTIONS
17307 rm -rf *
17308
17309
17310 test -z "`sort < /dev/null 2>&1`" || exit 77
17311
17312
17313 install-sh -d directory/b/c >/dev/null && genfile --file directory/b/c/x || exit 77
17314 mkdir directory/a
17315 genfile --file directory/a/a
17316
17317 echo First backup
17318 tar --create --file=archive.1 --listed-incremental=db.1 directory
17319
17320 sleep 2
17321
17322 # Remove directory b and create a file with this name.
17323 # Previous versions were not able to restore over this file.
17324 rm -r directory/b
17325 genfile --file directory/b
17326 genfile --file directory/a/b
17327
17328 echo Second backup
17329 tar --create --file=archive.2 --listed-incremental=db.2 directory
17330
17331 # Delete a
17332 rm -r directory
17333
17334 echo Restore archive.1
17335 tar -xf archive.1 --listed-incremental=/dev/null
17336 echo Restore archive.2
17337 tar -xf archive.2 --listed-incremental=/dev/null
17338 find directory | sort
17339 )"
17340 echo chtype.at:30 >"$at_check_line_file"
17341
17342 at_trace_this=
17343 if test -n "$at_traceon"; then
17344     echo 'Not enabling shell tracing (command contains an embedded newline)'
17345 fi
17346
17347 if test -n "$at_trace_this"; then
17348     ( $at_traceon;
17349 mkdir oldgnu
17350 (cd oldgnu
17351 TEST_TAR_FORMAT=oldgnu
17352 export TEST_TAR_FORMAT
17353 TAR_OPTIONS="-H oldgnu"
17354 export TAR_OPTIONS
17355 rm -rf *
17356
17357
17358 test -z "`sort < /dev/null 2>&1`" || exit 77
17359
17360
17361 install-sh -d directory/b/c >/dev/null && genfile --file directory/b/c/x || exit 77
17362 mkdir directory/a
17363 genfile --file directory/a/a
17364
17365 echo First backup
17366 tar --create --file=archive.1 --listed-incremental=db.1 directory
17367
17368 sleep 2
17369
17370 # Remove directory b and create a file with this name.
17371 # Previous versions were not able to restore over this file.
17372 rm -r directory/b
17373 genfile --file directory/b
17374 genfile --file directory/a/b
17375
17376 echo Second backup
17377 tar --create --file=archive.2 --listed-incremental=db.2 directory
17378
17379 # Delete a
17380 rm -r directory
17381
17382 echo Restore archive.1
17383 tar -xf archive.1 --listed-incremental=/dev/null
17384 echo Restore archive.2
17385 tar -xf archive.2 --listed-incremental=/dev/null
17386 find directory | sort
17387 ) ) >"$at_stdout" 2>"$at_stder1"
17388     at_status=$?
17389     grep '^ *+' "$at_stder1" >&2
17390     grep -v '^ *+' "$at_stder1" >"$at_stderr"
17391 else
17392     ( :;
17393 mkdir oldgnu
17394 (cd oldgnu
17395 TEST_TAR_FORMAT=oldgnu
17396 export TEST_TAR_FORMAT
17397 TAR_OPTIONS="-H oldgnu"
17398 export TAR_OPTIONS
17399 rm -rf *
17400
17401
17402 test -z "`sort < /dev/null 2>&1`" || exit 77
17403
17404
17405 install-sh -d directory/b/c >/dev/null && genfile --file directory/b/c/x || exit 77
17406 mkdir directory/a
17407 genfile --file directory/a/a
17408
17409 echo First backup
17410 tar --create --file=archive.1 --listed-incremental=db.1 directory
17411
17412 sleep 2
17413
17414 # Remove directory b and create a file with this name.
17415 # Previous versions were not able to restore over this file.
17416 rm -r directory/b
17417 genfile --file directory/b
17418 genfile --file directory/a/b
17419
17420 echo Second backup
17421 tar --create --file=archive.2 --listed-incremental=db.2 directory
17422
17423 # Delete a
17424 rm -r directory
17425
17426 echo Restore archive.1
17427 tar -xf archive.1 --listed-incremental=/dev/null
17428 echo Restore archive.2
17429 tar -xf archive.2 --listed-incremental=/dev/null
17430 find directory | sort
17431 ) ) >"$at_stdout" 2>"$at_stderr"
17432     at_status=$?
17433 fi
17434
17435 at_failed=false
17436 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
17437 echo >>"$at_stdout"; echo "First backup
17438 Second backup
17439 Restore archive.1
17440 Restore archive.2
17441 directory
17442 directory/a
17443 directory/a/a
17444 directory/a/b
17445 directory/b
17446 " | $at_diff - "$at_stdout" || at_failed=:
17447 case $at_status in
17448    77) echo 77 > "$at_status_file"; exit 77;;
17449    0) ;;
17450    *) echo "$at_srcdir/chtype.at:30: exit code was $at_status, expected 0"
17451       at_failed=:;;
17452 esac
17453 if $at_failed; then
17454
17455
17456   echo 1 > "$at_status_file"
17457   exit 1
17458 fi
17459
17460 $at_traceon
17461 $at_traceoff
17462 echo "$at_srcdir/chtype.at:30:
17463 mkdir posix
17464 (cd posix
17465 TEST_TAR_FORMAT=posix
17466 export TEST_TAR_FORMAT
17467 TAR_OPTIONS=\"-H posix\"
17468 export TAR_OPTIONS
17469 rm -rf *
17470
17471
17472 test -z "`sort < /dev/null 2>&1`" || exit 77
17473
17474
17475 install-sh -d directory/b/c >/dev/null && genfile --file directory/b/c/x || exit 77
17476 mkdir directory/a
17477 genfile --file directory/a/a
17478
17479 echo First backup
17480 tar --create --file=archive.1 --listed-incremental=db.1 directory
17481
17482 sleep 2
17483
17484 # Remove directory b and create a file with this name.
17485 # Previous versions were not able to restore over this file.
17486 rm -r directory/b
17487 genfile --file directory/b
17488 genfile --file directory/a/b
17489
17490 echo Second backup
17491 tar --create --file=archive.2 --listed-incremental=db.2 directory
17492
17493 # Delete a
17494 rm -r directory
17495
17496 echo Restore archive.1
17497 tar -xf archive.1 --listed-incremental=/dev/null
17498 echo Restore archive.2
17499 tar -xf archive.2 --listed-incremental=/dev/null
17500 find directory | sort
17501 )"
17502 echo chtype.at:30 >"$at_check_line_file"
17503
17504 at_trace_this=
17505 if test -n "$at_traceon"; then
17506     echo 'Not enabling shell tracing (command contains an embedded newline)'
17507 fi
17508
17509 if test -n "$at_trace_this"; then
17510     ( $at_traceon;
17511 mkdir posix
17512 (cd posix
17513 TEST_TAR_FORMAT=posix
17514 export TEST_TAR_FORMAT
17515 TAR_OPTIONS="-H posix"
17516 export TAR_OPTIONS
17517 rm -rf *
17518
17519
17520 test -z "`sort < /dev/null 2>&1`" || exit 77
17521
17522
17523 install-sh -d directory/b/c >/dev/null && genfile --file directory/b/c/x || exit 77
17524 mkdir directory/a
17525 genfile --file directory/a/a
17526
17527 echo First backup
17528 tar --create --file=archive.1 --listed-incremental=db.1 directory
17529
17530 sleep 2
17531
17532 # Remove directory b and create a file with this name.
17533 # Previous versions were not able to restore over this file.
17534 rm -r directory/b
17535 genfile --file directory/b
17536 genfile --file directory/a/b
17537
17538 echo Second backup
17539 tar --create --file=archive.2 --listed-incremental=db.2 directory
17540
17541 # Delete a
17542 rm -r directory
17543
17544 echo Restore archive.1
17545 tar -xf archive.1 --listed-incremental=/dev/null
17546 echo Restore archive.2
17547 tar -xf archive.2 --listed-incremental=/dev/null
17548 find directory | sort
17549 ) ) >"$at_stdout" 2>"$at_stder1"
17550     at_status=$?
17551     grep '^ *+' "$at_stder1" >&2
17552     grep -v '^ *+' "$at_stder1" >"$at_stderr"
17553 else
17554     ( :;
17555 mkdir posix
17556 (cd posix
17557 TEST_TAR_FORMAT=posix
17558 export TEST_TAR_FORMAT
17559 TAR_OPTIONS="-H posix"
17560 export TAR_OPTIONS
17561 rm -rf *
17562
17563
17564 test -z "`sort < /dev/null 2>&1`" || exit 77
17565
17566
17567 install-sh -d directory/b/c >/dev/null && genfile --file directory/b/c/x || exit 77
17568 mkdir directory/a
17569 genfile --file directory/a/a
17570
17571 echo First backup
17572 tar --create --file=archive.1 --listed-incremental=db.1 directory
17573
17574 sleep 2
17575
17576 # Remove directory b and create a file with this name.
17577 # Previous versions were not able to restore over this file.
17578 rm -r directory/b
17579 genfile --file directory/b
17580 genfile --file directory/a/b
17581
17582 echo Second backup
17583 tar --create --file=archive.2 --listed-incremental=db.2 directory
17584
17585 # Delete a
17586 rm -r directory
17587
17588 echo Restore archive.1
17589 tar -xf archive.1 --listed-incremental=/dev/null
17590 echo Restore archive.2
17591 tar -xf archive.2 --listed-incremental=/dev/null
17592 find directory | sort
17593 ) ) >"$at_stdout" 2>"$at_stderr"
17594     at_status=$?
17595 fi
17596
17597 at_failed=false
17598 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
17599 echo >>"$at_stdout"; echo "First backup
17600 Second backup
17601 Restore archive.1
17602 Restore archive.2
17603 directory
17604 directory/a
17605 directory/a/a
17606 directory/a/b
17607 directory/b
17608 " | $at_diff - "$at_stdout" || at_failed=:
17609 case $at_status in
17610    77) echo 77 > "$at_status_file"; exit 77;;
17611    0) ;;
17612    *) echo "$at_srcdir/chtype.at:30: exit code was $at_status, expected 0"
17613       at_failed=:;;
17614 esac
17615 if $at_failed; then
17616
17617
17618   echo 1 > "$at_status_file"
17619   exit 1
17620 fi
17621
17622 $at_traceon
17623
17624
17625
17626       $at_traceoff
17627       $at_times_p && times >"$at_times_file"
17628     ) 5>&1 2>&1 | eval $at_tee_pipe
17629     at_status=`cat "$at_status_file"`
17630     ;;
17631
17632   39 ) # 39. ignfail.at:23: ignfail
17633     at_setup_line='ignfail.at:23'
17634     at_desc="ignfail"
17635     $at_quiet $ECHO_N " 39: ignfail                                        $ECHO_C"
17636     at_xfail=no
17637       test -f $XFAILFILE && at_xfail=yes
17638     echo "#                             -*- compilation -*-" >> "$at_group_log"
17639     (
17640       echo "39. ignfail.at:23: testing ..."
17641       $at_traceon
17642
17643
17644
17645
17646
17647   $at_traceoff
17648 echo "$at_srcdir/ignfail.at:26:
17649 mkdir v7
17650 (cd v7
17651 TEST_TAR_FORMAT=v7
17652 export TEST_TAR_FORMAT
17653 TAR_OPTIONS=\"-H v7\"
17654 export TAR_OPTIONS
17655 rm -rf *
17656
17657 # The test is meaningless for super-user.
17658
17659 echo "test" > $$
17660 chmod 0 $$
17661 cat $$ > /dev/null 2>&1
17662 result=$?
17663 rm -f $$
17664 test $result -eq 0 && exit 77
17665
17666
17667 touch file
17668 mkdir directory
17669 touch directory/file
17670
17671 echo 1>&2 -----
17672 chmod 000 file
17673 tar cf archive file
17674 status=\$?
17675 chmod 600 file
17676 test \$status = 2 || exit 1
17677
17678 echo 1>&2 -----
17679 chmod 000 file
17680 tar cf archive --ignore-failed-read file || exit 1
17681 status=\$?
17682 chmod 600 file
17683 test \$status = 0 || exit 1
17684
17685 echo 1>&2 -----
17686 chmod 000 directory
17687 tar cf archive directory
17688 status=\$?
17689 chmod 700 directory
17690 test \$status = 2 || exit 1
17691
17692 echo 1>&2 -----
17693 chmod 000 directory
17694 tar cf archive --ignore-failed-read directory || exit 1
17695 status=\$?
17696 chmod 700 directory
17697 test \$status = 0
17698 )"
17699 echo ignfail.at:26 >"$at_check_line_file"
17700
17701 at_trace_this=
17702 if test -n "$at_traceon"; then
17703     echo 'Not enabling shell tracing (command contains an embedded newline)'
17704 fi
17705
17706 if test -n "$at_trace_this"; then
17707     ( $at_traceon;
17708 mkdir v7
17709 (cd v7
17710 TEST_TAR_FORMAT=v7
17711 export TEST_TAR_FORMAT
17712 TAR_OPTIONS="-H v7"
17713 export TAR_OPTIONS
17714 rm -rf *
17715
17716 # The test is meaningless for super-user.
17717
17718 echo "test" > $$
17719 chmod 0 $$
17720 cat $$ > /dev/null 2>&1
17721 result=$?
17722 rm -f $$
17723 test $result -eq 0 && exit 77
17724
17725
17726 touch file
17727 mkdir directory
17728 touch directory/file
17729
17730 echo 1>&2 -----
17731 chmod 000 file
17732 tar cf archive file
17733 status=$?
17734 chmod 600 file
17735 test $status = 2 || exit 1
17736
17737 echo 1>&2 -----
17738 chmod 000 file
17739 tar cf archive --ignore-failed-read file || exit 1
17740 status=$?
17741 chmod 600 file
17742 test $status = 0 || exit 1
17743
17744 echo 1>&2 -----
17745 chmod 000 directory
17746 tar cf archive directory
17747 status=$?
17748 chmod 700 directory
17749 test $status = 2 || exit 1
17750
17751 echo 1>&2 -----
17752 chmod 000 directory
17753 tar cf archive --ignore-failed-read directory || exit 1
17754 status=$?
17755 chmod 700 directory
17756 test $status = 0
17757 ) ) >"$at_stdout" 2>"$at_stder1"
17758     at_status=$?
17759     grep '^ *+' "$at_stder1" >&2
17760     grep -v '^ *+' "$at_stder1" >"$at_stderr"
17761 else
17762     ( :;
17763 mkdir v7
17764 (cd v7
17765 TEST_TAR_FORMAT=v7
17766 export TEST_TAR_FORMAT
17767 TAR_OPTIONS="-H v7"
17768 export TAR_OPTIONS
17769 rm -rf *
17770
17771 # The test is meaningless for super-user.
17772
17773 echo "test" > $$
17774 chmod 0 $$
17775 cat $$ > /dev/null 2>&1
17776 result=$?
17777 rm -f $$
17778 test $result -eq 0 && exit 77
17779
17780
17781 touch file
17782 mkdir directory
17783 touch directory/file
17784
17785 echo 1>&2 -----
17786 chmod 000 file
17787 tar cf archive file
17788 status=$?
17789 chmod 600 file
17790 test $status = 2 || exit 1
17791
17792 echo 1>&2 -----
17793 chmod 000 file
17794 tar cf archive --ignore-failed-read file || exit 1
17795 status=$?
17796 chmod 600 file
17797 test $status = 0 || exit 1
17798
17799 echo 1>&2 -----
17800 chmod 000 directory
17801 tar cf archive directory
17802 status=$?
17803 chmod 700 directory
17804 test $status = 2 || exit 1
17805
17806 echo 1>&2 -----
17807 chmod 000 directory
17808 tar cf archive --ignore-failed-read directory || exit 1
17809 status=$?
17810 chmod 700 directory
17811 test $status = 0
17812 ) ) >"$at_stdout" 2>"$at_stderr"
17813     at_status=$?
17814 fi
17815
17816 at_failed=false
17817 echo >>"$at_stderr"; echo "-----
17818 tar: file: Cannot open: Permission denied
17819 tar: Exiting with failure status due to previous errors
17820 -----
17821 tar: file: Warning: Cannot open: Permission denied
17822 -----
17823 tar: directory: Cannot open: Permission denied
17824 tar: Exiting with failure status due to previous errors
17825 -----
17826 tar: directory: Warning: Cannot open: Permission denied
17827 " | $at_diff - "$at_stderr" || at_failed=:
17828 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
17829 case $at_status in
17830    77) echo 77 > "$at_status_file"; exit 77;;
17831    0) ;;
17832    *) echo "$at_srcdir/ignfail.at:26: exit code was $at_status, expected 0"
17833       at_failed=:;;
17834 esac
17835 if $at_failed; then
17836
17837
17838   echo 1 > "$at_status_file"
17839   exit 1
17840 fi
17841
17842 $at_traceon
17843 $at_traceoff
17844 echo "$at_srcdir/ignfail.at:26:
17845 mkdir oldgnu
17846 (cd oldgnu
17847 TEST_TAR_FORMAT=oldgnu
17848 export TEST_TAR_FORMAT
17849 TAR_OPTIONS=\"-H oldgnu\"
17850 export TAR_OPTIONS
17851 rm -rf *
17852
17853 # The test is meaningless for super-user.
17854
17855 echo "test" > $$
17856 chmod 0 $$
17857 cat $$ > /dev/null 2>&1
17858 result=$?
17859 rm -f $$
17860 test $result -eq 0 && exit 77
17861
17862
17863 touch file
17864 mkdir directory
17865 touch directory/file
17866
17867 echo 1>&2 -----
17868 chmod 000 file
17869 tar cf archive file
17870 status=\$?
17871 chmod 600 file
17872 test \$status = 2 || exit 1
17873
17874 echo 1>&2 -----
17875 chmod 000 file
17876 tar cf archive --ignore-failed-read file || exit 1
17877 status=\$?
17878 chmod 600 file
17879 test \$status = 0 || exit 1
17880
17881 echo 1>&2 -----
17882 chmod 000 directory
17883 tar cf archive directory
17884 status=\$?
17885 chmod 700 directory
17886 test \$status = 2 || exit 1
17887
17888 echo 1>&2 -----
17889 chmod 000 directory
17890 tar cf archive --ignore-failed-read directory || exit 1
17891 status=\$?
17892 chmod 700 directory
17893 test \$status = 0
17894 )"
17895 echo ignfail.at:26 >"$at_check_line_file"
17896
17897 at_trace_this=
17898 if test -n "$at_traceon"; then
17899     echo 'Not enabling shell tracing (command contains an embedded newline)'
17900 fi
17901
17902 if test -n "$at_trace_this"; then
17903     ( $at_traceon;
17904 mkdir oldgnu
17905 (cd oldgnu
17906 TEST_TAR_FORMAT=oldgnu
17907 export TEST_TAR_FORMAT
17908 TAR_OPTIONS="-H oldgnu"
17909 export TAR_OPTIONS
17910 rm -rf *
17911
17912 # The test is meaningless for super-user.
17913
17914 echo "test" > $$
17915 chmod 0 $$
17916 cat $$ > /dev/null 2>&1
17917 result=$?
17918 rm -f $$
17919 test $result -eq 0 && exit 77
17920
17921
17922 touch file
17923 mkdir directory
17924 touch directory/file
17925
17926 echo 1>&2 -----
17927 chmod 000 file
17928 tar cf archive file
17929 status=$?
17930 chmod 600 file
17931 test $status = 2 || exit 1
17932
17933 echo 1>&2 -----
17934 chmod 000 file
17935 tar cf archive --ignore-failed-read file || exit 1
17936 status=$?
17937 chmod 600 file
17938 test $status = 0 || exit 1
17939
17940 echo 1>&2 -----
17941 chmod 000 directory
17942 tar cf archive directory
17943 status=$?
17944 chmod 700 directory
17945 test $status = 2 || exit 1
17946
17947 echo 1>&2 -----
17948 chmod 000 directory
17949 tar cf archive --ignore-failed-read directory || exit 1
17950 status=$?
17951 chmod 700 directory
17952 test $status = 0
17953 ) ) >"$at_stdout" 2>"$at_stder1"
17954     at_status=$?
17955     grep '^ *+' "$at_stder1" >&2
17956     grep -v '^ *+' "$at_stder1" >"$at_stderr"
17957 else
17958     ( :;
17959 mkdir oldgnu
17960 (cd oldgnu
17961 TEST_TAR_FORMAT=oldgnu
17962 export TEST_TAR_FORMAT
17963 TAR_OPTIONS="-H oldgnu"
17964 export TAR_OPTIONS
17965 rm -rf *
17966
17967 # The test is meaningless for super-user.
17968
17969 echo "test" > $$
17970 chmod 0 $$
17971 cat $$ > /dev/null 2>&1
17972 result=$?
17973 rm -f $$
17974 test $result -eq 0 && exit 77
17975
17976
17977 touch file
17978 mkdir directory
17979 touch directory/file
17980
17981 echo 1>&2 -----
17982 chmod 000 file
17983 tar cf archive file
17984 status=$?
17985 chmod 600 file
17986 test $status = 2 || exit 1
17987
17988 echo 1>&2 -----
17989 chmod 000 file
17990 tar cf archive --ignore-failed-read file || exit 1
17991 status=$?
17992 chmod 600 file
17993 test $status = 0 || exit 1
17994
17995 echo 1>&2 -----
17996 chmod 000 directory
17997 tar cf archive directory
17998 status=$?
17999 chmod 700 directory
18000 test $status = 2 || exit 1
18001
18002 echo 1>&2 -----
18003 chmod 000 directory
18004 tar cf archive --ignore-failed-read directory || exit 1
18005 status=$?
18006 chmod 700 directory
18007 test $status = 0
18008 ) ) >"$at_stdout" 2>"$at_stderr"
18009     at_status=$?
18010 fi
18011
18012 at_failed=false
18013 echo >>"$at_stderr"; echo "-----
18014 tar: file: Cannot open: Permission denied
18015 tar: Exiting with failure status due to previous errors
18016 -----
18017 tar: file: Warning: Cannot open: Permission denied
18018 -----
18019 tar: directory: Cannot open: Permission denied
18020 tar: Exiting with failure status due to previous errors
18021 -----
18022 tar: directory: Warning: Cannot open: Permission denied
18023 " | $at_diff - "$at_stderr" || at_failed=:
18024 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
18025 case $at_status in
18026    77) echo 77 > "$at_status_file"; exit 77;;
18027    0) ;;
18028    *) echo "$at_srcdir/ignfail.at:26: exit code was $at_status, expected 0"
18029       at_failed=:;;
18030 esac
18031 if $at_failed; then
18032
18033
18034   echo 1 > "$at_status_file"
18035   exit 1
18036 fi
18037
18038 $at_traceon
18039 $at_traceoff
18040 echo "$at_srcdir/ignfail.at:26:
18041 mkdir ustar
18042 (cd ustar
18043 TEST_TAR_FORMAT=ustar
18044 export TEST_TAR_FORMAT
18045 TAR_OPTIONS=\"-H ustar\"
18046 export TAR_OPTIONS
18047 rm -rf *
18048
18049 # The test is meaningless for super-user.
18050
18051 echo "test" > $$
18052 chmod 0 $$
18053 cat $$ > /dev/null 2>&1
18054 result=$?
18055 rm -f $$
18056 test $result -eq 0 && exit 77
18057
18058
18059 touch file
18060 mkdir directory
18061 touch directory/file
18062
18063 echo 1>&2 -----
18064 chmod 000 file
18065 tar cf archive file
18066 status=\$?
18067 chmod 600 file
18068 test \$status = 2 || exit 1
18069
18070 echo 1>&2 -----
18071 chmod 000 file
18072 tar cf archive --ignore-failed-read file || exit 1
18073 status=\$?
18074 chmod 600 file
18075 test \$status = 0 || exit 1
18076
18077 echo 1>&2 -----
18078 chmod 000 directory
18079 tar cf archive directory
18080 status=\$?
18081 chmod 700 directory
18082 test \$status = 2 || exit 1
18083
18084 echo 1>&2 -----
18085 chmod 000 directory
18086 tar cf archive --ignore-failed-read directory || exit 1
18087 status=\$?
18088 chmod 700 directory
18089 test \$status = 0
18090 )"
18091 echo ignfail.at:26 >"$at_check_line_file"
18092
18093 at_trace_this=
18094 if test -n "$at_traceon"; then
18095     echo 'Not enabling shell tracing (command contains an embedded newline)'
18096 fi
18097
18098 if test -n "$at_trace_this"; then
18099     ( $at_traceon;
18100 mkdir ustar
18101 (cd ustar
18102 TEST_TAR_FORMAT=ustar
18103 export TEST_TAR_FORMAT
18104 TAR_OPTIONS="-H ustar"
18105 export TAR_OPTIONS
18106 rm -rf *
18107
18108 # The test is meaningless for super-user.
18109
18110 echo "test" > $$
18111 chmod 0 $$
18112 cat $$ > /dev/null 2>&1
18113 result=$?
18114 rm -f $$
18115 test $result -eq 0 && exit 77
18116
18117
18118 touch file
18119 mkdir directory
18120 touch directory/file
18121
18122 echo 1>&2 -----
18123 chmod 000 file
18124 tar cf archive file
18125 status=$?
18126 chmod 600 file
18127 test $status = 2 || exit 1
18128
18129 echo 1>&2 -----
18130 chmod 000 file
18131 tar cf archive --ignore-failed-read file || exit 1
18132 status=$?
18133 chmod 600 file
18134 test $status = 0 || exit 1
18135
18136 echo 1>&2 -----
18137 chmod 000 directory
18138 tar cf archive directory
18139 status=$?
18140 chmod 700 directory
18141 test $status = 2 || exit 1
18142
18143 echo 1>&2 -----
18144 chmod 000 directory
18145 tar cf archive --ignore-failed-read directory || exit 1
18146 status=$?
18147 chmod 700 directory
18148 test $status = 0
18149 ) ) >"$at_stdout" 2>"$at_stder1"
18150     at_status=$?
18151     grep '^ *+' "$at_stder1" >&2
18152     grep -v '^ *+' "$at_stder1" >"$at_stderr"
18153 else
18154     ( :;
18155 mkdir ustar
18156 (cd ustar
18157 TEST_TAR_FORMAT=ustar
18158 export TEST_TAR_FORMAT
18159 TAR_OPTIONS="-H ustar"
18160 export TAR_OPTIONS
18161 rm -rf *
18162
18163 # The test is meaningless for super-user.
18164
18165 echo "test" > $$
18166 chmod 0 $$
18167 cat $$ > /dev/null 2>&1
18168 result=$?
18169 rm -f $$
18170 test $result -eq 0 && exit 77
18171
18172
18173 touch file
18174 mkdir directory
18175 touch directory/file
18176
18177 echo 1>&2 -----
18178 chmod 000 file
18179 tar cf archive file
18180 status=$?
18181 chmod 600 file
18182 test $status = 2 || exit 1
18183
18184 echo 1>&2 -----
18185 chmod 000 file
18186 tar cf archive --ignore-failed-read file || exit 1
18187 status=$?
18188 chmod 600 file
18189 test $status = 0 || exit 1
18190
18191 echo 1>&2 -----
18192 chmod 000 directory
18193 tar cf archive directory
18194 status=$?
18195 chmod 700 directory
18196 test $status = 2 || exit 1
18197
18198 echo 1>&2 -----
18199 chmod 000 directory
18200 tar cf archive --ignore-failed-read directory || exit 1
18201 status=$?
18202 chmod 700 directory
18203 test $status = 0
18204 ) ) >"$at_stdout" 2>"$at_stderr"
18205     at_status=$?
18206 fi
18207
18208 at_failed=false
18209 echo >>"$at_stderr"; echo "-----
18210 tar: file: Cannot open: Permission denied
18211 tar: Exiting with failure status due to previous errors
18212 -----
18213 tar: file: Warning: Cannot open: Permission denied
18214 -----
18215 tar: directory: Cannot open: Permission denied
18216 tar: Exiting with failure status due to previous errors
18217 -----
18218 tar: directory: Warning: Cannot open: Permission denied
18219 " | $at_diff - "$at_stderr" || at_failed=:
18220 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
18221 case $at_status in
18222    77) echo 77 > "$at_status_file"; exit 77;;
18223    0) ;;
18224    *) echo "$at_srcdir/ignfail.at:26: exit code was $at_status, expected 0"
18225       at_failed=:;;
18226 esac
18227 if $at_failed; then
18228
18229
18230   echo 1 > "$at_status_file"
18231   exit 1
18232 fi
18233
18234 $at_traceon
18235 $at_traceoff
18236 echo "$at_srcdir/ignfail.at:26:
18237 mkdir posix
18238 (cd posix
18239 TEST_TAR_FORMAT=posix
18240 export TEST_TAR_FORMAT
18241 TAR_OPTIONS=\"-H posix\"
18242 export TAR_OPTIONS
18243 rm -rf *
18244
18245 # The test is meaningless for super-user.
18246
18247 echo "test" > $$
18248 chmod 0 $$
18249 cat $$ > /dev/null 2>&1
18250 result=$?
18251 rm -f $$
18252 test $result -eq 0 && exit 77
18253
18254
18255 touch file
18256 mkdir directory
18257 touch directory/file
18258
18259 echo 1>&2 -----
18260 chmod 000 file
18261 tar cf archive file
18262 status=\$?
18263 chmod 600 file
18264 test \$status = 2 || exit 1
18265
18266 echo 1>&2 -----
18267 chmod 000 file
18268 tar cf archive --ignore-failed-read file || exit 1
18269 status=\$?
18270 chmod 600 file
18271 test \$status = 0 || exit 1
18272
18273 echo 1>&2 -----
18274 chmod 000 directory
18275 tar cf archive directory
18276 status=\$?
18277 chmod 700 directory
18278 test \$status = 2 || exit 1
18279
18280 echo 1>&2 -----
18281 chmod 000 directory
18282 tar cf archive --ignore-failed-read directory || exit 1
18283 status=\$?
18284 chmod 700 directory
18285 test \$status = 0
18286 )"
18287 echo ignfail.at:26 >"$at_check_line_file"
18288
18289 at_trace_this=
18290 if test -n "$at_traceon"; then
18291     echo 'Not enabling shell tracing (command contains an embedded newline)'
18292 fi
18293
18294 if test -n "$at_trace_this"; then
18295     ( $at_traceon;
18296 mkdir posix
18297 (cd posix
18298 TEST_TAR_FORMAT=posix
18299 export TEST_TAR_FORMAT
18300 TAR_OPTIONS="-H posix"
18301 export TAR_OPTIONS
18302 rm -rf *
18303
18304 # The test is meaningless for super-user.
18305
18306 echo "test" > $$
18307 chmod 0 $$
18308 cat $$ > /dev/null 2>&1
18309 result=$?
18310 rm -f $$
18311 test $result -eq 0 && exit 77
18312
18313
18314 touch file
18315 mkdir directory
18316 touch directory/file
18317
18318 echo 1>&2 -----
18319 chmod 000 file
18320 tar cf archive file
18321 status=$?
18322 chmod 600 file
18323 test $status = 2 || exit 1
18324
18325 echo 1>&2 -----
18326 chmod 000 file
18327 tar cf archive --ignore-failed-read file || exit 1
18328 status=$?
18329 chmod 600 file
18330 test $status = 0 || exit 1
18331
18332 echo 1>&2 -----
18333 chmod 000 directory
18334 tar cf archive directory
18335 status=$?
18336 chmod 700 directory
18337 test $status = 2 || exit 1
18338
18339 echo 1>&2 -----
18340 chmod 000 directory
18341 tar cf archive --ignore-failed-read directory || exit 1
18342 status=$?
18343 chmod 700 directory
18344 test $status = 0
18345 ) ) >"$at_stdout" 2>"$at_stder1"
18346     at_status=$?
18347     grep '^ *+' "$at_stder1" >&2
18348     grep -v '^ *+' "$at_stder1" >"$at_stderr"
18349 else
18350     ( :;
18351 mkdir posix
18352 (cd posix
18353 TEST_TAR_FORMAT=posix
18354 export TEST_TAR_FORMAT
18355 TAR_OPTIONS="-H posix"
18356 export TAR_OPTIONS
18357 rm -rf *
18358
18359 # The test is meaningless for super-user.
18360
18361 echo "test" > $$
18362 chmod 0 $$
18363 cat $$ > /dev/null 2>&1
18364 result=$?
18365 rm -f $$
18366 test $result -eq 0 && exit 77
18367
18368
18369 touch file
18370 mkdir directory
18371 touch directory/file
18372
18373 echo 1>&2 -----
18374 chmod 000 file
18375 tar cf archive file
18376 status=$?
18377 chmod 600 file
18378 test $status = 2 || exit 1
18379
18380 echo 1>&2 -----
18381 chmod 000 file
18382 tar cf archive --ignore-failed-read file || exit 1
18383 status=$?
18384 chmod 600 file
18385 test $status = 0 || exit 1
18386
18387 echo 1>&2 -----
18388 chmod 000 directory
18389 tar cf archive directory
18390 status=$?
18391 chmod 700 directory
18392 test $status = 2 || exit 1
18393
18394 echo 1>&2 -----
18395 chmod 000 directory
18396 tar cf archive --ignore-failed-read directory || exit 1
18397 status=$?
18398 chmod 700 directory
18399 test $status = 0
18400 ) ) >"$at_stdout" 2>"$at_stderr"
18401     at_status=$?
18402 fi
18403
18404 at_failed=false
18405 echo >>"$at_stderr"; echo "-----
18406 tar: file: Cannot open: Permission denied
18407 tar: Exiting with failure status due to previous errors
18408 -----
18409 tar: file: Warning: Cannot open: Permission denied
18410 -----
18411 tar: directory: Cannot open: Permission denied
18412 tar: Exiting with failure status due to previous errors
18413 -----
18414 tar: directory: Warning: Cannot open: Permission denied
18415 " | $at_diff - "$at_stderr" || at_failed=:
18416 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
18417 case $at_status in
18418    77) echo 77 > "$at_status_file"; exit 77;;
18419    0) ;;
18420    *) echo "$at_srcdir/ignfail.at:26: exit code was $at_status, expected 0"
18421       at_failed=:;;
18422 esac
18423 if $at_failed; then
18424
18425
18426   echo 1 > "$at_status_file"
18427   exit 1
18428 fi
18429
18430 $at_traceon
18431 $at_traceoff
18432 echo "$at_srcdir/ignfail.at:26:
18433 mkdir gnu
18434 (cd gnu
18435 TEST_TAR_FORMAT=gnu
18436 export TEST_TAR_FORMAT
18437 TAR_OPTIONS=\"-H gnu\"
18438 export TAR_OPTIONS
18439 rm -rf *
18440
18441 # The test is meaningless for super-user.
18442
18443 echo "test" > $$
18444 chmod 0 $$
18445 cat $$ > /dev/null 2>&1
18446 result=$?
18447 rm -f $$
18448 test $result -eq 0 && exit 77
18449
18450
18451 touch file
18452 mkdir directory
18453 touch directory/file
18454
18455 echo 1>&2 -----
18456 chmod 000 file
18457 tar cf archive file
18458 status=\$?
18459 chmod 600 file
18460 test \$status = 2 || exit 1
18461
18462 echo 1>&2 -----
18463 chmod 000 file
18464 tar cf archive --ignore-failed-read file || exit 1
18465 status=\$?
18466 chmod 600 file
18467 test \$status = 0 || exit 1
18468
18469 echo 1>&2 -----
18470 chmod 000 directory
18471 tar cf archive directory
18472 status=\$?
18473 chmod 700 directory
18474 test \$status = 2 || exit 1
18475
18476 echo 1>&2 -----
18477 chmod 000 directory
18478 tar cf archive --ignore-failed-read directory || exit 1
18479 status=\$?
18480 chmod 700 directory
18481 test \$status = 0
18482 )"
18483 echo ignfail.at:26 >"$at_check_line_file"
18484
18485 at_trace_this=
18486 if test -n "$at_traceon"; then
18487     echo 'Not enabling shell tracing (command contains an embedded newline)'
18488 fi
18489
18490 if test -n "$at_trace_this"; then
18491     ( $at_traceon;
18492 mkdir gnu
18493 (cd gnu
18494 TEST_TAR_FORMAT=gnu
18495 export TEST_TAR_FORMAT
18496 TAR_OPTIONS="-H gnu"
18497 export TAR_OPTIONS
18498 rm -rf *
18499
18500 # The test is meaningless for super-user.
18501
18502 echo "test" > $$
18503 chmod 0 $$
18504 cat $$ > /dev/null 2>&1
18505 result=$?
18506 rm -f $$
18507 test $result -eq 0 && exit 77
18508
18509
18510 touch file
18511 mkdir directory
18512 touch directory/file
18513
18514 echo 1>&2 -----
18515 chmod 000 file
18516 tar cf archive file
18517 status=$?
18518 chmod 600 file
18519 test $status = 2 || exit 1
18520
18521 echo 1>&2 -----
18522 chmod 000 file
18523 tar cf archive --ignore-failed-read file || exit 1
18524 status=$?
18525 chmod 600 file
18526 test $status = 0 || exit 1
18527
18528 echo 1>&2 -----
18529 chmod 000 directory
18530 tar cf archive directory
18531 status=$?
18532 chmod 700 directory
18533 test $status = 2 || exit 1
18534
18535 echo 1>&2 -----
18536 chmod 000 directory
18537 tar cf archive --ignore-failed-read directory || exit 1
18538 status=$?
18539 chmod 700 directory
18540 test $status = 0
18541 ) ) >"$at_stdout" 2>"$at_stder1"
18542     at_status=$?
18543     grep '^ *+' "$at_stder1" >&2
18544     grep -v '^ *+' "$at_stder1" >"$at_stderr"
18545 else
18546     ( :;
18547 mkdir gnu
18548 (cd gnu
18549 TEST_TAR_FORMAT=gnu
18550 export TEST_TAR_FORMAT
18551 TAR_OPTIONS="-H gnu"
18552 export TAR_OPTIONS
18553 rm -rf *
18554
18555 # The test is meaningless for super-user.
18556
18557 echo "test" > $$
18558 chmod 0 $$
18559 cat $$ > /dev/null 2>&1
18560 result=$?
18561 rm -f $$
18562 test $result -eq 0 && exit 77
18563
18564
18565 touch file
18566 mkdir directory
18567 touch directory/file
18568
18569 echo 1>&2 -----
18570 chmod 000 file
18571 tar cf archive file
18572 status=$?
18573 chmod 600 file
18574 test $status = 2 || exit 1
18575
18576 echo 1>&2 -----
18577 chmod 000 file
18578 tar cf archive --ignore-failed-read file || exit 1
18579 status=$?
18580 chmod 600 file
18581 test $status = 0 || exit 1
18582
18583 echo 1>&2 -----
18584 chmod 000 directory
18585 tar cf archive directory
18586 status=$?
18587 chmod 700 directory
18588 test $status = 2 || exit 1
18589
18590 echo 1>&2 -----
18591 chmod 000 directory
18592 tar cf archive --ignore-failed-read directory || exit 1
18593 status=$?
18594 chmod 700 directory
18595 test $status = 0
18596 ) ) >"$at_stdout" 2>"$at_stderr"
18597     at_status=$?
18598 fi
18599
18600 at_failed=false
18601 echo >>"$at_stderr"; echo "-----
18602 tar: file: Cannot open: Permission denied
18603 tar: Exiting with failure status due to previous errors
18604 -----
18605 tar: file: Warning: Cannot open: Permission denied
18606 -----
18607 tar: directory: Cannot open: Permission denied
18608 tar: Exiting with failure status due to previous errors
18609 -----
18610 tar: directory: Warning: Cannot open: Permission denied
18611 " | $at_diff - "$at_stderr" || at_failed=:
18612 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
18613 case $at_status in
18614    77) echo 77 > "$at_status_file"; exit 77;;
18615    0) ;;
18616    *) echo "$at_srcdir/ignfail.at:26: exit code was $at_status, expected 0"
18617       at_failed=:;;
18618 esac
18619 if $at_failed; then
18620
18621
18622   echo 1 > "$at_status_file"
18623   exit 1
18624 fi
18625
18626 $at_traceon
18627
18628
18629
18630       $at_traceoff
18631       $at_times_p && times >"$at_times_file"
18632     ) 5>&1 2>&1 | eval $at_tee_pipe
18633     at_status=`cat "$at_status_file"`
18634     ;;
18635
18636   40 ) # 40. link01.at:33: link count gt 2
18637     at_setup_line='link01.at:33'
18638     at_desc="link count gt 2"
18639     $at_quiet $ECHO_N " 40: link count gt 2                                $ECHO_C"
18640     at_xfail=no
18641       test -f $XFAILFILE && at_xfail=yes
18642     echo "#                             -*- compilation -*-" >> "$at_group_log"
18643     (
18644       echo "40. link01.at:33: testing ..."
18645       $at_traceon
18646
18647
18648
18649
18650
18651   $at_traceoff
18652 echo "$at_srcdir/link01.at:36:
18653 mkdir v7
18654 (cd v7
18655 TEST_TAR_FORMAT=v7
18656 export TEST_TAR_FORMAT
18657 TAR_OPTIONS=\"-H v7\"
18658 export TAR_OPTIONS
18659 rm -rf *
18660
18661 mkdir directory
18662 mkdir directory/test1
18663 mkdir directory/test2
18664
18665 echo TEST > directory/test1/test.txt
18666 ln directory/test1/test.txt directory/test2/test.txt || exit 77
18667
18668 tar cf archive directory/test1/test.txt directory/test1/test.txt
18669
18670 rm -r directory
18671 tar xf archive
18672
18673 ls directory/test1
18674 )"
18675 echo link01.at:36 >"$at_check_line_file"
18676
18677 at_trace_this=
18678 if test -n "$at_traceon"; then
18679     echo 'Not enabling shell tracing (command contains an embedded newline)'
18680 fi
18681
18682 if test -n "$at_trace_this"; then
18683     ( $at_traceon;
18684 mkdir v7
18685 (cd v7
18686 TEST_TAR_FORMAT=v7
18687 export TEST_TAR_FORMAT
18688 TAR_OPTIONS="-H v7"
18689 export TAR_OPTIONS
18690 rm -rf *
18691
18692 mkdir directory
18693 mkdir directory/test1
18694 mkdir directory/test2
18695
18696 echo TEST > directory/test1/test.txt
18697 ln directory/test1/test.txt directory/test2/test.txt || exit 77
18698
18699 tar cf archive directory/test1/test.txt directory/test1/test.txt
18700
18701 rm -r directory
18702 tar xf archive
18703
18704 ls directory/test1
18705 ) ) >"$at_stdout" 2>"$at_stder1"
18706     at_status=$?
18707     grep '^ *+' "$at_stder1" >&2
18708     grep -v '^ *+' "$at_stder1" >"$at_stderr"
18709 else
18710     ( :;
18711 mkdir v7
18712 (cd v7
18713 TEST_TAR_FORMAT=v7
18714 export TEST_TAR_FORMAT
18715 TAR_OPTIONS="-H v7"
18716 export TAR_OPTIONS
18717 rm -rf *
18718
18719 mkdir directory
18720 mkdir directory/test1
18721 mkdir directory/test2
18722
18723 echo TEST > directory/test1/test.txt
18724 ln directory/test1/test.txt directory/test2/test.txt || exit 77
18725
18726 tar cf archive directory/test1/test.txt directory/test1/test.txt
18727
18728 rm -r directory
18729 tar xf archive
18730
18731 ls directory/test1
18732 ) ) >"$at_stdout" 2>"$at_stderr"
18733     at_status=$?
18734 fi
18735
18736 at_failed=false
18737 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
18738 echo >>"$at_stdout"; echo "test.txt
18739 " | $at_diff - "$at_stdout" || at_failed=:
18740 case $at_status in
18741    77) echo 77 > "$at_status_file"; exit 77;;
18742    0) ;;
18743    *) echo "$at_srcdir/link01.at:36: exit code was $at_status, expected 0"
18744       at_failed=:;;
18745 esac
18746 if $at_failed; then
18747
18748
18749   echo 1 > "$at_status_file"
18750   exit 1
18751 fi
18752
18753 $at_traceon
18754 $at_traceoff
18755 echo "$at_srcdir/link01.at:36:
18756 mkdir oldgnu
18757 (cd oldgnu
18758 TEST_TAR_FORMAT=oldgnu
18759 export TEST_TAR_FORMAT
18760 TAR_OPTIONS=\"-H oldgnu\"
18761 export TAR_OPTIONS
18762 rm -rf *
18763
18764 mkdir directory
18765 mkdir directory/test1
18766 mkdir directory/test2
18767
18768 echo TEST > directory/test1/test.txt
18769 ln directory/test1/test.txt directory/test2/test.txt || exit 77
18770
18771 tar cf archive directory/test1/test.txt directory/test1/test.txt
18772
18773 rm -r directory
18774 tar xf archive
18775
18776 ls directory/test1
18777 )"
18778 echo link01.at:36 >"$at_check_line_file"
18779
18780 at_trace_this=
18781 if test -n "$at_traceon"; then
18782     echo 'Not enabling shell tracing (command contains an embedded newline)'
18783 fi
18784
18785 if test -n "$at_trace_this"; then
18786     ( $at_traceon;
18787 mkdir oldgnu
18788 (cd oldgnu
18789 TEST_TAR_FORMAT=oldgnu
18790 export TEST_TAR_FORMAT
18791 TAR_OPTIONS="-H oldgnu"
18792 export TAR_OPTIONS
18793 rm -rf *
18794
18795 mkdir directory
18796 mkdir directory/test1
18797 mkdir directory/test2
18798
18799 echo TEST > directory/test1/test.txt
18800 ln directory/test1/test.txt directory/test2/test.txt || exit 77
18801
18802 tar cf archive directory/test1/test.txt directory/test1/test.txt
18803
18804 rm -r directory
18805 tar xf archive
18806
18807 ls directory/test1
18808 ) ) >"$at_stdout" 2>"$at_stder1"
18809     at_status=$?
18810     grep '^ *+' "$at_stder1" >&2
18811     grep -v '^ *+' "$at_stder1" >"$at_stderr"
18812 else
18813     ( :;
18814 mkdir oldgnu
18815 (cd oldgnu
18816 TEST_TAR_FORMAT=oldgnu
18817 export TEST_TAR_FORMAT
18818 TAR_OPTIONS="-H oldgnu"
18819 export TAR_OPTIONS
18820 rm -rf *
18821
18822 mkdir directory
18823 mkdir directory/test1
18824 mkdir directory/test2
18825
18826 echo TEST > directory/test1/test.txt
18827 ln directory/test1/test.txt directory/test2/test.txt || exit 77
18828
18829 tar cf archive directory/test1/test.txt directory/test1/test.txt
18830
18831 rm -r directory
18832 tar xf archive
18833
18834 ls directory/test1
18835 ) ) >"$at_stdout" 2>"$at_stderr"
18836     at_status=$?
18837 fi
18838
18839 at_failed=false
18840 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
18841 echo >>"$at_stdout"; echo "test.txt
18842 " | $at_diff - "$at_stdout" || at_failed=:
18843 case $at_status in
18844    77) echo 77 > "$at_status_file"; exit 77;;
18845    0) ;;
18846    *) echo "$at_srcdir/link01.at:36: exit code was $at_status, expected 0"
18847       at_failed=:;;
18848 esac
18849 if $at_failed; then
18850
18851
18852   echo 1 > "$at_status_file"
18853   exit 1
18854 fi
18855
18856 $at_traceon
18857 $at_traceoff
18858 echo "$at_srcdir/link01.at:36:
18859 mkdir ustar
18860 (cd ustar
18861 TEST_TAR_FORMAT=ustar
18862 export TEST_TAR_FORMAT
18863 TAR_OPTIONS=\"-H ustar\"
18864 export TAR_OPTIONS
18865 rm -rf *
18866
18867 mkdir directory
18868 mkdir directory/test1
18869 mkdir directory/test2
18870
18871 echo TEST > directory/test1/test.txt
18872 ln directory/test1/test.txt directory/test2/test.txt || exit 77
18873
18874 tar cf archive directory/test1/test.txt directory/test1/test.txt
18875
18876 rm -r directory
18877 tar xf archive
18878
18879 ls directory/test1
18880 )"
18881 echo link01.at:36 >"$at_check_line_file"
18882
18883 at_trace_this=
18884 if test -n "$at_traceon"; then
18885     echo 'Not enabling shell tracing (command contains an embedded newline)'
18886 fi
18887
18888 if test -n "$at_trace_this"; then
18889     ( $at_traceon;
18890 mkdir ustar
18891 (cd ustar
18892 TEST_TAR_FORMAT=ustar
18893 export TEST_TAR_FORMAT
18894 TAR_OPTIONS="-H ustar"
18895 export TAR_OPTIONS
18896 rm -rf *
18897
18898 mkdir directory
18899 mkdir directory/test1
18900 mkdir directory/test2
18901
18902 echo TEST > directory/test1/test.txt
18903 ln directory/test1/test.txt directory/test2/test.txt || exit 77
18904
18905 tar cf archive directory/test1/test.txt directory/test1/test.txt
18906
18907 rm -r directory
18908 tar xf archive
18909
18910 ls directory/test1
18911 ) ) >"$at_stdout" 2>"$at_stder1"
18912     at_status=$?
18913     grep '^ *+' "$at_stder1" >&2
18914     grep -v '^ *+' "$at_stder1" >"$at_stderr"
18915 else
18916     ( :;
18917 mkdir ustar
18918 (cd ustar
18919 TEST_TAR_FORMAT=ustar
18920 export TEST_TAR_FORMAT
18921 TAR_OPTIONS="-H ustar"
18922 export TAR_OPTIONS
18923 rm -rf *
18924
18925 mkdir directory
18926 mkdir directory/test1
18927 mkdir directory/test2
18928
18929 echo TEST > directory/test1/test.txt
18930 ln directory/test1/test.txt directory/test2/test.txt || exit 77
18931
18932 tar cf archive directory/test1/test.txt directory/test1/test.txt
18933
18934 rm -r directory
18935 tar xf archive
18936
18937 ls directory/test1
18938 ) ) >"$at_stdout" 2>"$at_stderr"
18939     at_status=$?
18940 fi
18941
18942 at_failed=false
18943 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
18944 echo >>"$at_stdout"; echo "test.txt
18945 " | $at_diff - "$at_stdout" || at_failed=:
18946 case $at_status in
18947    77) echo 77 > "$at_status_file"; exit 77;;
18948    0) ;;
18949    *) echo "$at_srcdir/link01.at:36: exit code was $at_status, expected 0"
18950       at_failed=:;;
18951 esac
18952 if $at_failed; then
18953
18954
18955   echo 1 > "$at_status_file"
18956   exit 1
18957 fi
18958
18959 $at_traceon
18960 $at_traceoff
18961 echo "$at_srcdir/link01.at:36:
18962 mkdir posix
18963 (cd posix
18964 TEST_TAR_FORMAT=posix
18965 export TEST_TAR_FORMAT
18966 TAR_OPTIONS=\"-H posix\"
18967 export TAR_OPTIONS
18968 rm -rf *
18969
18970 mkdir directory
18971 mkdir directory/test1
18972 mkdir directory/test2
18973
18974 echo TEST > directory/test1/test.txt
18975 ln directory/test1/test.txt directory/test2/test.txt || exit 77
18976
18977 tar cf archive directory/test1/test.txt directory/test1/test.txt
18978
18979 rm -r directory
18980 tar xf archive
18981
18982 ls directory/test1
18983 )"
18984 echo link01.at:36 >"$at_check_line_file"
18985
18986 at_trace_this=
18987 if test -n "$at_traceon"; then
18988     echo 'Not enabling shell tracing (command contains an embedded newline)'
18989 fi
18990
18991 if test -n "$at_trace_this"; then
18992     ( $at_traceon;
18993 mkdir posix
18994 (cd posix
18995 TEST_TAR_FORMAT=posix
18996 export TEST_TAR_FORMAT
18997 TAR_OPTIONS="-H posix"
18998 export TAR_OPTIONS
18999 rm -rf *
19000
19001 mkdir directory
19002 mkdir directory/test1
19003 mkdir directory/test2
19004
19005 echo TEST > directory/test1/test.txt
19006 ln directory/test1/test.txt directory/test2/test.txt || exit 77
19007
19008 tar cf archive directory/test1/test.txt directory/test1/test.txt
19009
19010 rm -r directory
19011 tar xf archive
19012
19013 ls directory/test1
19014 ) ) >"$at_stdout" 2>"$at_stder1"
19015     at_status=$?
19016     grep '^ *+' "$at_stder1" >&2
19017     grep -v '^ *+' "$at_stder1" >"$at_stderr"
19018 else
19019     ( :;
19020 mkdir posix
19021 (cd posix
19022 TEST_TAR_FORMAT=posix
19023 export TEST_TAR_FORMAT
19024 TAR_OPTIONS="-H posix"
19025 export TAR_OPTIONS
19026 rm -rf *
19027
19028 mkdir directory
19029 mkdir directory/test1
19030 mkdir directory/test2
19031
19032 echo TEST > directory/test1/test.txt
19033 ln directory/test1/test.txt directory/test2/test.txt || exit 77
19034
19035 tar cf archive directory/test1/test.txt directory/test1/test.txt
19036
19037 rm -r directory
19038 tar xf archive
19039
19040 ls directory/test1
19041 ) ) >"$at_stdout" 2>"$at_stderr"
19042     at_status=$?
19043 fi
19044
19045 at_failed=false
19046 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
19047 echo >>"$at_stdout"; echo "test.txt
19048 " | $at_diff - "$at_stdout" || at_failed=:
19049 case $at_status in
19050    77) echo 77 > "$at_status_file"; exit 77;;
19051    0) ;;
19052    *) echo "$at_srcdir/link01.at:36: exit code was $at_status, expected 0"
19053       at_failed=:;;
19054 esac
19055 if $at_failed; then
19056
19057
19058   echo 1 > "$at_status_file"
19059   exit 1
19060 fi
19061
19062 $at_traceon
19063 $at_traceoff
19064 echo "$at_srcdir/link01.at:36:
19065 mkdir gnu
19066 (cd gnu
19067 TEST_TAR_FORMAT=gnu
19068 export TEST_TAR_FORMAT
19069 TAR_OPTIONS=\"-H gnu\"
19070 export TAR_OPTIONS
19071 rm -rf *
19072
19073 mkdir directory
19074 mkdir directory/test1
19075 mkdir directory/test2
19076
19077 echo TEST > directory/test1/test.txt
19078 ln directory/test1/test.txt directory/test2/test.txt || exit 77
19079
19080 tar cf archive directory/test1/test.txt directory/test1/test.txt
19081
19082 rm -r directory
19083 tar xf archive
19084
19085 ls directory/test1
19086 )"
19087 echo link01.at:36 >"$at_check_line_file"
19088
19089 at_trace_this=
19090 if test -n "$at_traceon"; then
19091     echo 'Not enabling shell tracing (command contains an embedded newline)'
19092 fi
19093
19094 if test -n "$at_trace_this"; then
19095     ( $at_traceon;
19096 mkdir gnu
19097 (cd gnu
19098 TEST_TAR_FORMAT=gnu
19099 export TEST_TAR_FORMAT
19100 TAR_OPTIONS="-H gnu"
19101 export TAR_OPTIONS
19102 rm -rf *
19103
19104 mkdir directory
19105 mkdir directory/test1
19106 mkdir directory/test2
19107
19108 echo TEST > directory/test1/test.txt
19109 ln directory/test1/test.txt directory/test2/test.txt || exit 77
19110
19111 tar cf archive directory/test1/test.txt directory/test1/test.txt
19112
19113 rm -r directory
19114 tar xf archive
19115
19116 ls directory/test1
19117 ) ) >"$at_stdout" 2>"$at_stder1"
19118     at_status=$?
19119     grep '^ *+' "$at_stder1" >&2
19120     grep -v '^ *+' "$at_stder1" >"$at_stderr"
19121 else
19122     ( :;
19123 mkdir gnu
19124 (cd gnu
19125 TEST_TAR_FORMAT=gnu
19126 export TEST_TAR_FORMAT
19127 TAR_OPTIONS="-H gnu"
19128 export TAR_OPTIONS
19129 rm -rf *
19130
19131 mkdir directory
19132 mkdir directory/test1
19133 mkdir directory/test2
19134
19135 echo TEST > directory/test1/test.txt
19136 ln directory/test1/test.txt directory/test2/test.txt || exit 77
19137
19138 tar cf archive directory/test1/test.txt directory/test1/test.txt
19139
19140 rm -r directory
19141 tar xf archive
19142
19143 ls directory/test1
19144 ) ) >"$at_stdout" 2>"$at_stderr"
19145     at_status=$?
19146 fi
19147
19148 at_failed=false
19149 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
19150 echo >>"$at_stdout"; echo "test.txt
19151 " | $at_diff - "$at_stdout" || at_failed=:
19152 case $at_status in
19153    77) echo 77 > "$at_status_file"; exit 77;;
19154    0) ;;
19155    *) echo "$at_srcdir/link01.at:36: exit code was $at_status, expected 0"
19156       at_failed=:;;
19157 esac
19158 if $at_failed; then
19159
19160
19161   echo 1 > "$at_status_file"
19162   exit 1
19163 fi
19164
19165 $at_traceon
19166
19167
19168
19169       $at_traceoff
19170       $at_times_p && times >"$at_times_file"
19171     ) 5>&1 2>&1 | eval $at_tee_pipe
19172     at_status=`cat "$at_status_file"`
19173     ;;
19174
19175   41 ) # 41. longv7.at:24: long names in V7 archives
19176     at_setup_line='longv7.at:24'
19177     at_desc="long names in V7 archives"
19178     $at_quiet $ECHO_N " 41: long names in V7 archives                      $ECHO_C"
19179     at_xfail=no
19180       test -f $XFAILFILE && at_xfail=yes
19181     echo "#                             -*- compilation -*-" >> "$at_group_log"
19182     (
19183       echo "41. longv7.at:24: testing ..."
19184       $at_traceon
19185
19186
19187
19188
19189
19190
19191
19192
19193   $at_traceoff
19194 echo "$at_srcdir/longv7.at:30:
19195 mkdir v7
19196 (cd v7
19197 TEST_TAR_FORMAT=v7
19198 export TEST_TAR_FORMAT
19199 TAR_OPTIONS=\"-H v7\"
19200 export TAR_OPTIONS
19201 rm -rf *
19202
19203 mkdir this_is_a_very_long_name_for_a_directory_which_causes_problems
19204 touch this_is_a_very_long_name_for_a_directory_which_causes_problems/this_is_a_very_long_file_name_which_raises_issues.c
19205
19206 tar cf archive this_is_a_very_long_name_for_a_directory_which_causes_problems
19207 echo separator
19208 tar tf archive
19209 )"
19210 echo longv7.at:30 >"$at_check_line_file"
19211
19212 at_trace_this=
19213 if test -n "$at_traceon"; then
19214     echo 'Not enabling shell tracing (command contains an embedded newline)'
19215 fi
19216
19217 if test -n "$at_trace_this"; then
19218     ( $at_traceon;
19219 mkdir v7
19220 (cd v7
19221 TEST_TAR_FORMAT=v7
19222 export TEST_TAR_FORMAT
19223 TAR_OPTIONS="-H v7"
19224 export TAR_OPTIONS
19225 rm -rf *
19226
19227 mkdir this_is_a_very_long_name_for_a_directory_which_causes_problems
19228 touch this_is_a_very_long_name_for_a_directory_which_causes_problems/this_is_a_very_long_file_name_which_raises_issues.c
19229
19230 tar cf archive this_is_a_very_long_name_for_a_directory_which_causes_problems
19231 echo separator
19232 tar tf archive
19233 ) ) >"$at_stdout" 2>"$at_stder1"
19234     at_status=$?
19235     grep '^ *+' "$at_stder1" >&2
19236     grep -v '^ *+' "$at_stder1" >"$at_stderr"
19237 else
19238     ( :;
19239 mkdir v7
19240 (cd v7
19241 TEST_TAR_FORMAT=v7
19242 export TEST_TAR_FORMAT
19243 TAR_OPTIONS="-H v7"
19244 export TAR_OPTIONS
19245 rm -rf *
19246
19247 mkdir this_is_a_very_long_name_for_a_directory_which_causes_problems
19248 touch this_is_a_very_long_name_for_a_directory_which_causes_problems/this_is_a_very_long_file_name_which_raises_issues.c
19249
19250 tar cf archive this_is_a_very_long_name_for_a_directory_which_causes_problems
19251 echo separator
19252 tar tf archive
19253 ) ) >"$at_stdout" 2>"$at_stderr"
19254     at_status=$?
19255 fi
19256
19257 at_failed=false
19258 echo >>"$at_stderr"; echo "tar: this_is_a_very_long_name_for_a_directory_which_causes_problems/this_is_a_very_long_file_name_which_raises_issues.c: file name is too long (max 99); not dumped
19259 tar: Exiting with failure status due to previous errors
19260 " | $at_diff - "$at_stderr" || at_failed=:
19261 echo >>"$at_stdout"; echo "separator
19262 this_is_a_very_long_name_for_a_directory_which_causes_problems/
19263 " | $at_diff - "$at_stdout" || at_failed=:
19264 case $at_status in
19265    77) echo 77 > "$at_status_file"; exit 77;;
19266    0) ;;
19267    *) echo "$at_srcdir/longv7.at:30: exit code was $at_status, expected 0"
19268       at_failed=:;;
19269 esac
19270 if $at_failed; then
19271
19272
19273   echo 1 > "$at_status_file"
19274   exit 1
19275 fi
19276
19277 $at_traceon
19278
19279
19280
19281       $at_traceoff
19282       $at_times_p && times >"$at_times_file"
19283     ) 5>&1 2>&1 | eval $at_tee_pipe
19284     at_status=`cat "$at_status_file"`
19285     ;;
19286
19287   42 ) # 42. long01.at:28: long file names divisible by block size
19288     at_setup_line='long01.at:28'
19289     at_desc="long file names divisible by block size"
19290     $at_quiet $ECHO_N " 42: long file names divisible by block size        $ECHO_C"
19291     at_xfail=no
19292       test -f $XFAILFILE && at_xfail=yes
19293     echo "#                             -*- compilation -*-" >> "$at_group_log"
19294     (
19295       echo "42. long01.at:28: testing ..."
19296       $at_traceon
19297
19298
19299
19300
19301
19302
19303
19304
19305
19306   $at_traceoff
19307 echo "$at_srcdir/long01.at:36:
19308 mkdir gnu
19309 (cd gnu
19310 TEST_TAR_FORMAT=gnu
19311 export TEST_TAR_FORMAT
19312 TAR_OPTIONS=\"-H gnu\"
19313 export TAR_OPTIONS
19314 rm -rf *
19315
19316
19317 install-sh -d 0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde >/dev/null && genfile --file 0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde || exit 77
19318 echo test > endfile
19319
19320 tar cf archive 0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde endfile
19321 tar tf archive)"
19322 echo long01.at:36 >"$at_check_line_file"
19323
19324 at_trace_this=
19325 if test -n "$at_traceon"; then
19326     echo 'Not enabling shell tracing (command contains an embedded newline)'
19327 fi
19328
19329 if test -n "$at_trace_this"; then
19330     ( $at_traceon;
19331 mkdir gnu
19332 (cd gnu
19333 TEST_TAR_FORMAT=gnu
19334 export TEST_TAR_FORMAT
19335 TAR_OPTIONS="-H gnu"
19336 export TAR_OPTIONS
19337 rm -rf *
19338
19339
19340 install-sh -d 0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde >/dev/null && genfile --file 0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde || exit 77
19341 echo test > endfile
19342
19343 tar cf archive 0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde endfile
19344 tar tf archive) ) >"$at_stdout" 2>"$at_stder1"
19345     at_status=$?
19346     grep '^ *+' "$at_stder1" >&2
19347     grep -v '^ *+' "$at_stder1" >"$at_stderr"
19348 else
19349     ( :;
19350 mkdir gnu
19351 (cd gnu
19352 TEST_TAR_FORMAT=gnu
19353 export TEST_TAR_FORMAT
19354 TAR_OPTIONS="-H gnu"
19355 export TAR_OPTIONS
19356 rm -rf *
19357
19358
19359 install-sh -d 0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde >/dev/null && genfile --file 0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde || exit 77
19360 echo test > endfile
19361
19362 tar cf archive 0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde endfile
19363 tar tf archive) ) >"$at_stdout" 2>"$at_stderr"
19364     at_status=$?
19365 fi
19366
19367 at_failed=false
19368 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
19369 echo >>"$at_stdout"; echo "0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde
19370 endfile
19371 " | $at_diff - "$at_stdout" || at_failed=:
19372 case $at_status in
19373    77) echo 77 > "$at_status_file"; exit 77;;
19374    0) ;;
19375    *) echo "$at_srcdir/long01.at:36: exit code was $at_status, expected 0"
19376       at_failed=:;;
19377 esac
19378 if $at_failed; then
19379
19380
19381   echo 1 > "$at_status_file"
19382   exit 1
19383 fi
19384
19385 $at_traceon
19386 $at_traceoff
19387 echo "$at_srcdir/long01.at:36:
19388 mkdir oldgnu
19389 (cd oldgnu
19390 TEST_TAR_FORMAT=oldgnu
19391 export TEST_TAR_FORMAT
19392 TAR_OPTIONS=\"-H oldgnu\"
19393 export TAR_OPTIONS
19394 rm -rf *
19395
19396
19397 install-sh -d 0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde >/dev/null && genfile --file 0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde || exit 77
19398 echo test > endfile
19399
19400 tar cf archive 0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde endfile
19401 tar tf archive)"
19402 echo long01.at:36 >"$at_check_line_file"
19403
19404 at_trace_this=
19405 if test -n "$at_traceon"; then
19406     echo 'Not enabling shell tracing (command contains an embedded newline)'
19407 fi
19408
19409 if test -n "$at_trace_this"; then
19410     ( $at_traceon;
19411 mkdir oldgnu
19412 (cd oldgnu
19413 TEST_TAR_FORMAT=oldgnu
19414 export TEST_TAR_FORMAT
19415 TAR_OPTIONS="-H oldgnu"
19416 export TAR_OPTIONS
19417 rm -rf *
19418
19419
19420 install-sh -d 0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde >/dev/null && genfile --file 0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde || exit 77
19421 echo test > endfile
19422
19423 tar cf archive 0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde endfile
19424 tar tf archive) ) >"$at_stdout" 2>"$at_stder1"
19425     at_status=$?
19426     grep '^ *+' "$at_stder1" >&2
19427     grep -v '^ *+' "$at_stder1" >"$at_stderr"
19428 else
19429     ( :;
19430 mkdir oldgnu
19431 (cd oldgnu
19432 TEST_TAR_FORMAT=oldgnu
19433 export TEST_TAR_FORMAT
19434 TAR_OPTIONS="-H oldgnu"
19435 export TAR_OPTIONS
19436 rm -rf *
19437
19438
19439 install-sh -d 0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde >/dev/null && genfile --file 0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde || exit 77
19440 echo test > endfile
19441
19442 tar cf archive 0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde endfile
19443 tar tf archive) ) >"$at_stdout" 2>"$at_stderr"
19444     at_status=$?
19445 fi
19446
19447 at_failed=false
19448 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
19449 echo >>"$at_stdout"; echo "0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde/0123456789abcde
19450 endfile
19451 " | $at_diff - "$at_stdout" || at_failed=:
19452 case $at_status in
19453    77) echo 77 > "$at_status_file"; exit 77;;
19454    0) ;;
19455    *) echo "$at_srcdir/long01.at:36: exit code was $at_status, expected 0"
19456       at_failed=:;;
19457 esac
19458 if $at_failed; then
19459
19460
19461   echo 1 > "$at_status_file"
19462   exit 1
19463 fi
19464
19465 $at_traceon
19466
19467
19468
19469       $at_traceoff
19470       $at_times_p && times >"$at_times_file"
19471     ) 5>&1 2>&1 | eval $at_tee_pipe
19472     at_status=`cat "$at_status_file"`
19473     ;;
19474
19475   43 ) # 43. lustar01.at:21: ustar: unsplittable file name
19476     at_setup_line='lustar01.at:21'
19477     at_desc="ustar: unsplittable file name"
19478     $at_quiet $ECHO_N " 43: ustar: unsplittable file name                  $ECHO_C"
19479     at_xfail=no
19480       test -f $XFAILFILE && at_xfail=yes
19481     echo "#                             -*- compilation -*-" >> "$at_group_log"
19482     (
19483       echo "43. lustar01.at:21: testing ..."
19484       $at_traceon
19485
19486
19487
19488
19489
19490
19491
19492   $at_traceoff
19493 echo "$at_srcdir/lustar01.at:27:
19494 mkdir ustar
19495 (cd ustar
19496 TEST_TAR_FORMAT=ustar
19497 export TEST_TAR_FORMAT
19498 TAR_OPTIONS=\"-H ustar\"
19499 export TAR_OPTIONS
19500 rm -rf *
19501
19502 genfile --file=this_is_a_very_long_name_for_a_file_designed_to_test_generation_of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_between_name_and_prefix || exit 77
19503 tar cf archive this_is_a_very_long_name_for_a_file_designed_to_test_generation_of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_between_name_and_prefix
19504 )"
19505 echo lustar01.at:27 >"$at_check_line_file"
19506
19507 at_trace_this=
19508 if test -n "$at_traceon"; then
19509     echo 'Not enabling shell tracing (command contains an embedded newline)'
19510 fi
19511
19512 if test -n "$at_trace_this"; then
19513     ( $at_traceon;
19514 mkdir ustar
19515 (cd ustar
19516 TEST_TAR_FORMAT=ustar
19517 export TEST_TAR_FORMAT
19518 TAR_OPTIONS="-H ustar"
19519 export TAR_OPTIONS
19520 rm -rf *
19521
19522 genfile --file=this_is_a_very_long_name_for_a_file_designed_to_test_generation_of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_between_name_and_prefix || exit 77
19523 tar cf archive this_is_a_very_long_name_for_a_file_designed_to_test_generation_of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_between_name_and_prefix
19524 ) ) >"$at_stdout" 2>"$at_stder1"
19525     at_status=$?
19526     grep '^ *+' "$at_stder1" >&2
19527     grep -v '^ *+' "$at_stder1" >"$at_stderr"
19528 else
19529     ( :;
19530 mkdir ustar
19531 (cd ustar
19532 TEST_TAR_FORMAT=ustar
19533 export TEST_TAR_FORMAT
19534 TAR_OPTIONS="-H ustar"
19535 export TAR_OPTIONS
19536 rm -rf *
19537
19538 genfile --file=this_is_a_very_long_name_for_a_file_designed_to_test_generation_of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_between_name_and_prefix || exit 77
19539 tar cf archive this_is_a_very_long_name_for_a_file_designed_to_test_generation_of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_between_name_and_prefix
19540 ) ) >"$at_stdout" 2>"$at_stderr"
19541     at_status=$?
19542 fi
19543
19544 at_failed=false
19545 echo >>"$at_stderr"; echo "tar: this_is_a_very_long_name_for_a_file_designed_to_test_generation_of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_between_name_and_prefix: file name is too long (cannot be split); not dumped
19546 tar: Exiting with failure status due to previous errors
19547 " | $at_diff - "$at_stderr" || at_failed=:
19548 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
19549 case $at_status in
19550    77) echo 77 > "$at_status_file"; exit 77;;
19551    2) ;;
19552    *) echo "$at_srcdir/lustar01.at:27: exit code was $at_status, expected 2"
19553       at_failed=:;;
19554 esac
19555 if $at_failed; then
19556
19557
19558   echo 1 > "$at_status_file"
19559   exit 1
19560 fi
19561
19562 $at_traceon
19563
19564
19565
19566       $at_traceoff
19567       $at_times_p && times >"$at_times_file"
19568     ) 5>&1 2>&1 | eval $at_tee_pipe
19569     at_status=`cat "$at_status_file"`
19570     ;;
19571
19572   44 ) # 44. lustar02.at:21: ustar: unsplittable path name
19573     at_setup_line='lustar02.at:21'
19574     at_desc="ustar: unsplittable path name"
19575     $at_quiet $ECHO_N " 44: ustar: unsplittable path name                  $ECHO_C"
19576     at_xfail=no
19577       test -f $XFAILFILE && at_xfail=yes
19578     echo "#                             -*- compilation -*-" >> "$at_group_log"
19579     (
19580       echo "44. lustar02.at:21: testing ..."
19581       $at_traceon
19582
19583
19584
19585
19586
19587
19588
19589
19590
19591
19592
19593   $at_traceoff
19594 echo "$at_srcdir/lustar02.at:32:
19595 mkdir ustar
19596 (cd ustar
19597 TEST_TAR_FORMAT=ustar
19598 export TEST_TAR_FORMAT
19599 TAR_OPTIONS=\"-H ustar\"
19600 export TAR_OPTIONS
19601 rm -rf *
19602
19603
19604 install-sh -d this_is_a_very_long_name_for_a_file_designed_to_test_generation_of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be >/dev/null && genfile --file this_is_a_very_long_name_for_a_file_designed_to_test_generation_of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be/tween_name_and_prefix || exit 77
19605 tar cf archive this_is_a_very_long_name_for_a_file_designed_to_test_generation_of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be
19606 )"
19607 echo lustar02.at:32 >"$at_check_line_file"
19608
19609 at_trace_this=
19610 if test -n "$at_traceon"; then
19611     echo 'Not enabling shell tracing (command contains an embedded newline)'
19612 fi
19613
19614 if test -n "$at_trace_this"; then
19615     ( $at_traceon;
19616 mkdir ustar
19617 (cd ustar
19618 TEST_TAR_FORMAT=ustar
19619 export TEST_TAR_FORMAT
19620 TAR_OPTIONS="-H ustar"
19621 export TAR_OPTIONS
19622 rm -rf *
19623
19624
19625 install-sh -d this_is_a_very_long_name_for_a_file_designed_to_test_generation_of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be >/dev/null && genfile --file this_is_a_very_long_name_for_a_file_designed_to_test_generation_of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be/tween_name_and_prefix || exit 77
19626 tar cf archive this_is_a_very_long_name_for_a_file_designed_to_test_generation_of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be
19627 ) ) >"$at_stdout" 2>"$at_stder1"
19628     at_status=$?
19629     grep '^ *+' "$at_stder1" >&2
19630     grep -v '^ *+' "$at_stder1" >"$at_stderr"
19631 else
19632     ( :;
19633 mkdir ustar
19634 (cd ustar
19635 TEST_TAR_FORMAT=ustar
19636 export TEST_TAR_FORMAT
19637 TAR_OPTIONS="-H ustar"
19638 export TAR_OPTIONS
19639 rm -rf *
19640
19641
19642 install-sh -d this_is_a_very_long_name_for_a_file_designed_to_test_generation_of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be >/dev/null && genfile --file this_is_a_very_long_name_for_a_file_designed_to_test_generation_of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be/tween_name_and_prefix || exit 77
19643 tar cf archive this_is_a_very_long_name_for_a_file_designed_to_test_generation_of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be
19644 ) ) >"$at_stdout" 2>"$at_stderr"
19645     at_status=$?
19646 fi
19647
19648 at_failed=false
19649 echo >>"$at_stderr"; echo "tar: this_is_a_very_long_name_for_a_file_designed_to_test_generation_of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be/: file name is too long (cannot be split); not dumped
19650 tar: Exiting with failure status due to previous errors
19651 " | $at_diff - "$at_stderr" || at_failed=:
19652 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
19653 case $at_status in
19654    77) echo 77 > "$at_status_file"; exit 77;;
19655    2) ;;
19656    *) echo "$at_srcdir/lustar02.at:32: exit code was $at_status, expected 2"
19657       at_failed=:;;
19658 esac
19659 if $at_failed; then
19660
19661
19662   echo 1 > "$at_status_file"
19663   exit 1
19664 fi
19665
19666 $at_traceon
19667
19668
19669
19670       $at_traceoff
19671       $at_times_p && times >"$at_times_file"
19672     ) 5>&1 2>&1 | eval $at_tee_pipe
19673     at_status=`cat "$at_status_file"`
19674     ;;
19675
19676   45 ) # 45. lustar03.at:21: ustar: splitting long names
19677     at_setup_line='lustar03.at:21'
19678     at_desc="ustar: splitting long names"
19679     $at_quiet $ECHO_N " 45: ustar: splitting long names                    $ECHO_C"
19680     at_xfail=no
19681       test -f $XFAILFILE && at_xfail=yes
19682     echo "#                             -*- compilation -*-" >> "$at_group_log"
19683     (
19684       echo "45. lustar03.at:21: testing ..."
19685       $at_traceon
19686
19687
19688
19689
19690
19691
19692
19693
19694
19695   $at_traceoff
19696 echo "$at_srcdir/lustar03.at:29:
19697 mkdir ustar
19698 (cd ustar
19699 TEST_TAR_FORMAT=ustar
19700 export TEST_TAR_FORMAT
19701 TAR_OPTIONS=\"-H ustar\"
19702 export TAR_OPTIONS
19703 rm -rf *
19704
19705
19706 install-sh -d this_is_a_very_long_name_for_a_file_designed_to_test_generation/of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be >/dev/null && genfile --file this_is_a_very_long_name_for_a_file_designed_to_test_generation/of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be/file || exit 77
19707 echo \"Create archive\"
19708 tar cf archive this_is_a_very_long_name_for_a_file_designed_to_test_generation/of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be
19709 echo \"List archive\"
19710 tar tf archive)"
19711 echo lustar03.at:29 >"$at_check_line_file"
19712
19713 at_trace_this=
19714 if test -n "$at_traceon"; then
19715     echo 'Not enabling shell tracing (command contains an embedded newline)'
19716 fi
19717
19718 if test -n "$at_trace_this"; then
19719     ( $at_traceon;
19720 mkdir ustar
19721 (cd ustar
19722 TEST_TAR_FORMAT=ustar
19723 export TEST_TAR_FORMAT
19724 TAR_OPTIONS="-H ustar"
19725 export TAR_OPTIONS
19726 rm -rf *
19727
19728
19729 install-sh -d this_is_a_very_long_name_for_a_file_designed_to_test_generation/of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be >/dev/null && genfile --file this_is_a_very_long_name_for_a_file_designed_to_test_generation/of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be/file || exit 77
19730 echo "Create archive"
19731 tar cf archive this_is_a_very_long_name_for_a_file_designed_to_test_generation/of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be
19732 echo "List archive"
19733 tar tf archive) ) >"$at_stdout" 2>"$at_stder1"
19734     at_status=$?
19735     grep '^ *+' "$at_stder1" >&2
19736     grep -v '^ *+' "$at_stder1" >"$at_stderr"
19737 else
19738     ( :;
19739 mkdir ustar
19740 (cd ustar
19741 TEST_TAR_FORMAT=ustar
19742 export TEST_TAR_FORMAT
19743 TAR_OPTIONS="-H ustar"
19744 export TAR_OPTIONS
19745 rm -rf *
19746
19747
19748 install-sh -d this_is_a_very_long_name_for_a_file_designed_to_test_generation/of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be >/dev/null && genfile --file this_is_a_very_long_name_for_a_file_designed_to_test_generation/of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be/file || exit 77
19749 echo "Create archive"
19750 tar cf archive this_is_a_very_long_name_for_a_file_designed_to_test_generation/of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be
19751 echo "List archive"
19752 tar tf archive) ) >"$at_stdout" 2>"$at_stderr"
19753     at_status=$?
19754 fi
19755
19756 at_failed=false
19757 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
19758 echo >>"$at_stdout"; echo "Create archive
19759 List archive
19760 this_is_a_very_long_name_for_a_file_designed_to_test_generation/of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be/
19761 this_is_a_very_long_name_for_a_file_designed_to_test_generation/of_ustar_archives_by_gnu_tar_semicolon_it_will_not_fit_the_name_field_and_cannot_be_split_be/file
19762 " | $at_diff - "$at_stdout" || at_failed=:
19763 case $at_status in
19764    77) echo 77 > "$at_status_file"; exit 77;;
19765    0) ;;
19766    *) echo "$at_srcdir/lustar03.at:29: exit code was $at_status, expected 0"
19767       at_failed=:;;
19768 esac
19769 if $at_failed; then
19770
19771
19772   echo 1 > "$at_status_file"
19773   exit 1
19774 fi
19775
19776 $at_traceon
19777
19778
19779
19780       $at_traceoff
19781       $at_times_p && times >"$at_times_file"
19782     ) 5>&1 2>&1 | eval $at_tee_pipe
19783     at_status=`cat "$at_status_file"`
19784     ;;
19785
19786   46 ) # 46. multiv01.at:23: multivolume dumps from pipes
19787     at_setup_line='multiv01.at:23'
19788     at_desc="multivolume dumps from pipes"
19789     $at_quiet $ECHO_N " 46: multivolume dumps from pipes                   $ECHO_C"
19790     at_xfail=no
19791       test -f $XFAILFILE && at_xfail=yes
19792     echo "#                             -*- compilation -*-" >> "$at_group_log"
19793     (
19794       echo "46. multiv01.at:23: testing ..."
19795       $at_traceon
19796
19797
19798
19799 # Fixme: should be configurable
19800 #  TRUSS=truss -o /tmp/tr
19801 #  TRUSS=strace
19802
19803
19804
19805   $at_traceoff
19806 echo "$at_srcdir/multiv01.at:30:
19807 mkdir gnu
19808 (cd gnu
19809 TEST_TAR_FORMAT=gnu
19810 export TEST_TAR_FORMAT
19811 TAR_OPTIONS=\"-H gnu\"
19812 export TAR_OPTIONS
19813 rm -rf *
19814
19815 exec <&-
19816 genfile --length 7168 --file file1
19817
19818 for block in \" 1\" \" 2\" \" 3\" \" 4\" \" 5\" \" 6\" \" 7\" \" 8\" \\
19819               \" 9\" \"10\" \"11\" \"12\" \"13\" \"14\" \"15\" \"16\" ; do \\
19820   echo \"file2  block \${block} bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla\"
19821   for count in 2 3 4 5 6 7 8 ; do
19822     echo \"bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla\"
19823   done
19824 done >file2
19825
19826 if test \$TEST_TAR_FORMAT = pax; then
19827   TAPE_LENGTH=11
19828 else
19829   TAPE_LENGTH=10
19830 fi
19831
19832 tar -c --multi-volume --tape-length=\$TAPE_LENGTH \\
19833   --listed-incremental=t.snar \\
19834   -f t1-pipe.tar -f t2-pipe.tar ./file1 ./file2 || exit 1
19835
19836 mkdir extract-dir-pipe
19837 dd bs=4096 count=\$TAPE_LENGTH if=t2-pipe.tar 2>/dev/null |
19838 PATH=\$PATH \${TRUSS} tar -f t1-pipe.tar -f - \\
19839       -C extract-dir-pipe -x --multi-volume \\
19840       --tape-length=\$TAPE_LENGTH --read-full-records || exit 1
19841
19842 cmp file1 extract-dir-pipe/file1
19843 cmp file2 extract-dir-pipe/file2
19844 )"
19845 echo multiv01.at:30 >"$at_check_line_file"
19846
19847 at_trace_this=
19848 if test -n "$at_traceon"; then
19849     echo 'Not enabling shell tracing (command contains a ${...} parameter expansion)'
19850 fi
19851
19852 if test -n "$at_trace_this"; then
19853     ( $at_traceon;
19854 mkdir gnu
19855 (cd gnu
19856 TEST_TAR_FORMAT=gnu
19857 export TEST_TAR_FORMAT
19858 TAR_OPTIONS="-H gnu"
19859 export TAR_OPTIONS
19860 rm -rf *
19861
19862 exec <&-
19863 genfile --length 7168 --file file1
19864
19865 for block in " 1" " 2" " 3" " 4" " 5" " 6" " 7" " 8" \
19866               " 9" "10" "11" "12" "13" "14" "15" "16" ; do \
19867   echo "file2  block ${block} bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla"
19868   for count in 2 3 4 5 6 7 8 ; do
19869     echo "bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla"
19870   done
19871 done >file2
19872
19873 if test $TEST_TAR_FORMAT = pax; then
19874   TAPE_LENGTH=11
19875 else
19876   TAPE_LENGTH=10
19877 fi
19878
19879 tar -c --multi-volume --tape-length=$TAPE_LENGTH \
19880   --listed-incremental=t.snar \
19881   -f t1-pipe.tar -f t2-pipe.tar ./file1 ./file2 || exit 1
19882
19883 mkdir extract-dir-pipe
19884 dd bs=4096 count=$TAPE_LENGTH if=t2-pipe.tar 2>/dev/null |
19885 PATH=$PATH ${TRUSS} tar -f t1-pipe.tar -f - \
19886       -C extract-dir-pipe -x --multi-volume \
19887       --tape-length=$TAPE_LENGTH --read-full-records || exit 1
19888
19889 cmp file1 extract-dir-pipe/file1
19890 cmp file2 extract-dir-pipe/file2
19891 ) ) >"$at_stdout" 2>"$at_stder1"
19892     at_status=$?
19893     grep '^ *+' "$at_stder1" >&2
19894     grep -v '^ *+' "$at_stder1" >"$at_stderr"
19895 else
19896     ( :;
19897 mkdir gnu
19898 (cd gnu
19899 TEST_TAR_FORMAT=gnu
19900 export TEST_TAR_FORMAT
19901 TAR_OPTIONS="-H gnu"
19902 export TAR_OPTIONS
19903 rm -rf *
19904
19905 exec <&-
19906 genfile --length 7168 --file file1
19907
19908 for block in " 1" " 2" " 3" " 4" " 5" " 6" " 7" " 8" \
19909               " 9" "10" "11" "12" "13" "14" "15" "16" ; do \
19910   echo "file2  block ${block} bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla"
19911   for count in 2 3 4 5 6 7 8 ; do
19912     echo "bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla"
19913   done
19914 done >file2
19915
19916 if test $TEST_TAR_FORMAT = pax; then
19917   TAPE_LENGTH=11
19918 else
19919   TAPE_LENGTH=10
19920 fi
19921
19922 tar -c --multi-volume --tape-length=$TAPE_LENGTH \
19923   --listed-incremental=t.snar \
19924   -f t1-pipe.tar -f t2-pipe.tar ./file1 ./file2 || exit 1
19925
19926 mkdir extract-dir-pipe
19927 dd bs=4096 count=$TAPE_LENGTH if=t2-pipe.tar 2>/dev/null |
19928 PATH=$PATH ${TRUSS} tar -f t1-pipe.tar -f - \
19929       -C extract-dir-pipe -x --multi-volume \
19930       --tape-length=$TAPE_LENGTH --read-full-records || exit 1
19931
19932 cmp file1 extract-dir-pipe/file1
19933 cmp file2 extract-dir-pipe/file2
19934 ) ) >"$at_stdout" 2>"$at_stderr"
19935     at_status=$?
19936 fi
19937
19938 at_failed=false
19939 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
19940 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
19941 case $at_status in
19942    77) echo 77 > "$at_status_file"; exit 77;;
19943    0) ;;
19944    *) echo "$at_srcdir/multiv01.at:30: exit code was $at_status, expected 0"
19945       at_failed=:;;
19946 esac
19947 if $at_failed; then
19948
19949
19950   echo 1 > "$at_status_file"
19951   exit 1
19952 fi
19953
19954 $at_traceon
19955 $at_traceoff
19956 echo "$at_srcdir/multiv01.at:30:
19957 mkdir oldgnu
19958 (cd oldgnu
19959 TEST_TAR_FORMAT=oldgnu
19960 export TEST_TAR_FORMAT
19961 TAR_OPTIONS=\"-H oldgnu\"
19962 export TAR_OPTIONS
19963 rm -rf *
19964
19965 exec <&-
19966 genfile --length 7168 --file file1
19967
19968 for block in \" 1\" \" 2\" \" 3\" \" 4\" \" 5\" \" 6\" \" 7\" \" 8\" \\
19969               \" 9\" \"10\" \"11\" \"12\" \"13\" \"14\" \"15\" \"16\" ; do \\
19970   echo \"file2  block \${block} bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla\"
19971   for count in 2 3 4 5 6 7 8 ; do
19972     echo \"bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla\"
19973   done
19974 done >file2
19975
19976 if test \$TEST_TAR_FORMAT = pax; then
19977   TAPE_LENGTH=11
19978 else
19979   TAPE_LENGTH=10
19980 fi
19981
19982 tar -c --multi-volume --tape-length=\$TAPE_LENGTH \\
19983   --listed-incremental=t.snar \\
19984   -f t1-pipe.tar -f t2-pipe.tar ./file1 ./file2 || exit 1
19985
19986 mkdir extract-dir-pipe
19987 dd bs=4096 count=\$TAPE_LENGTH if=t2-pipe.tar 2>/dev/null |
19988 PATH=\$PATH \${TRUSS} tar -f t1-pipe.tar -f - \\
19989       -C extract-dir-pipe -x --multi-volume \\
19990       --tape-length=\$TAPE_LENGTH --read-full-records || exit 1
19991
19992 cmp file1 extract-dir-pipe/file1
19993 cmp file2 extract-dir-pipe/file2
19994 )"
19995 echo multiv01.at:30 >"$at_check_line_file"
19996
19997 at_trace_this=
19998 if test -n "$at_traceon"; then
19999     echo 'Not enabling shell tracing (command contains a ${...} parameter expansion)'
20000 fi
20001
20002 if test -n "$at_trace_this"; then
20003     ( $at_traceon;
20004 mkdir oldgnu
20005 (cd oldgnu
20006 TEST_TAR_FORMAT=oldgnu
20007 export TEST_TAR_FORMAT
20008 TAR_OPTIONS="-H oldgnu"
20009 export TAR_OPTIONS
20010 rm -rf *
20011
20012 exec <&-
20013 genfile --length 7168 --file file1
20014
20015 for block in " 1" " 2" " 3" " 4" " 5" " 6" " 7" " 8" \
20016               " 9" "10" "11" "12" "13" "14" "15" "16" ; do \
20017   echo "file2  block ${block} bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla"
20018   for count in 2 3 4 5 6 7 8 ; do
20019     echo "bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla"
20020   done
20021 done >file2
20022
20023 if test $TEST_TAR_FORMAT = pax; then
20024   TAPE_LENGTH=11
20025 else
20026   TAPE_LENGTH=10
20027 fi
20028
20029 tar -c --multi-volume --tape-length=$TAPE_LENGTH \
20030   --listed-incremental=t.snar \
20031   -f t1-pipe.tar -f t2-pipe.tar ./file1 ./file2 || exit 1
20032
20033 mkdir extract-dir-pipe
20034 dd bs=4096 count=$TAPE_LENGTH if=t2-pipe.tar 2>/dev/null |
20035 PATH=$PATH ${TRUSS} tar -f t1-pipe.tar -f - \
20036       -C extract-dir-pipe -x --multi-volume \
20037       --tape-length=$TAPE_LENGTH --read-full-records || exit 1
20038
20039 cmp file1 extract-dir-pipe/file1
20040 cmp file2 extract-dir-pipe/file2
20041 ) ) >"$at_stdout" 2>"$at_stder1"
20042     at_status=$?
20043     grep '^ *+' "$at_stder1" >&2
20044     grep -v '^ *+' "$at_stder1" >"$at_stderr"
20045 else
20046     ( :;
20047 mkdir oldgnu
20048 (cd oldgnu
20049 TEST_TAR_FORMAT=oldgnu
20050 export TEST_TAR_FORMAT
20051 TAR_OPTIONS="-H oldgnu"
20052 export TAR_OPTIONS
20053 rm -rf *
20054
20055 exec <&-
20056 genfile --length 7168 --file file1
20057
20058 for block in " 1" " 2" " 3" " 4" " 5" " 6" " 7" " 8" \
20059               " 9" "10" "11" "12" "13" "14" "15" "16" ; do \
20060   echo "file2  block ${block} bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla"
20061   for count in 2 3 4 5 6 7 8 ; do
20062     echo "bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla"
20063   done
20064 done >file2
20065
20066 if test $TEST_TAR_FORMAT = pax; then
20067   TAPE_LENGTH=11
20068 else
20069   TAPE_LENGTH=10
20070 fi
20071
20072 tar -c --multi-volume --tape-length=$TAPE_LENGTH \
20073   --listed-incremental=t.snar \
20074   -f t1-pipe.tar -f t2-pipe.tar ./file1 ./file2 || exit 1
20075
20076 mkdir extract-dir-pipe
20077 dd bs=4096 count=$TAPE_LENGTH if=t2-pipe.tar 2>/dev/null |
20078 PATH=$PATH ${TRUSS} tar -f t1-pipe.tar -f - \
20079       -C extract-dir-pipe -x --multi-volume \
20080       --tape-length=$TAPE_LENGTH --read-full-records || exit 1
20081
20082 cmp file1 extract-dir-pipe/file1
20083 cmp file2 extract-dir-pipe/file2
20084 ) ) >"$at_stdout" 2>"$at_stderr"
20085     at_status=$?
20086 fi
20087
20088 at_failed=false
20089 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
20090 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
20091 case $at_status in
20092    77) echo 77 > "$at_status_file"; exit 77;;
20093    0) ;;
20094    *) echo "$at_srcdir/multiv01.at:30: exit code was $at_status, expected 0"
20095       at_failed=:;;
20096 esac
20097 if $at_failed; then
20098
20099
20100   echo 1 > "$at_status_file"
20101   exit 1
20102 fi
20103
20104 $at_traceon
20105 $at_traceoff
20106 echo "$at_srcdir/multiv01.at:30:
20107 mkdir pax
20108 (cd pax
20109 TEST_TAR_FORMAT=pax
20110 export TEST_TAR_FORMAT
20111 TAR_OPTIONS=\"-H pax\"
20112 export TAR_OPTIONS
20113 rm -rf *
20114
20115 exec <&-
20116 genfile --length 7168 --file file1
20117
20118 for block in \" 1\" \" 2\" \" 3\" \" 4\" \" 5\" \" 6\" \" 7\" \" 8\" \\
20119               \" 9\" \"10\" \"11\" \"12\" \"13\" \"14\" \"15\" \"16\" ; do \\
20120   echo \"file2  block \${block} bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla\"
20121   for count in 2 3 4 5 6 7 8 ; do
20122     echo \"bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla\"
20123   done
20124 done >file2
20125
20126 if test \$TEST_TAR_FORMAT = pax; then
20127   TAPE_LENGTH=11
20128 else
20129   TAPE_LENGTH=10
20130 fi
20131
20132 tar -c --multi-volume --tape-length=\$TAPE_LENGTH \\
20133   --listed-incremental=t.snar \\
20134   -f t1-pipe.tar -f t2-pipe.tar ./file1 ./file2 || exit 1
20135
20136 mkdir extract-dir-pipe
20137 dd bs=4096 count=\$TAPE_LENGTH if=t2-pipe.tar 2>/dev/null |
20138 PATH=\$PATH \${TRUSS} tar -f t1-pipe.tar -f - \\
20139       -C extract-dir-pipe -x --multi-volume \\
20140       --tape-length=\$TAPE_LENGTH --read-full-records || exit 1
20141
20142 cmp file1 extract-dir-pipe/file1
20143 cmp file2 extract-dir-pipe/file2
20144 )"
20145 echo multiv01.at:30 >"$at_check_line_file"
20146
20147 at_trace_this=
20148 if test -n "$at_traceon"; then
20149     echo 'Not enabling shell tracing (command contains a ${...} parameter expansion)'
20150 fi
20151
20152 if test -n "$at_trace_this"; then
20153     ( $at_traceon;
20154 mkdir pax
20155 (cd pax
20156 TEST_TAR_FORMAT=pax
20157 export TEST_TAR_FORMAT
20158 TAR_OPTIONS="-H pax"
20159 export TAR_OPTIONS
20160 rm -rf *
20161
20162 exec <&-
20163 genfile --length 7168 --file file1
20164
20165 for block in " 1" " 2" " 3" " 4" " 5" " 6" " 7" " 8" \
20166               " 9" "10" "11" "12" "13" "14" "15" "16" ; do \
20167   echo "file2  block ${block} bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla"
20168   for count in 2 3 4 5 6 7 8 ; do
20169     echo "bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla"
20170   done
20171 done >file2
20172
20173 if test $TEST_TAR_FORMAT = pax; then
20174   TAPE_LENGTH=11
20175 else
20176   TAPE_LENGTH=10
20177 fi
20178
20179 tar -c --multi-volume --tape-length=$TAPE_LENGTH \
20180   --listed-incremental=t.snar \
20181   -f t1-pipe.tar -f t2-pipe.tar ./file1 ./file2 || exit 1
20182
20183 mkdir extract-dir-pipe
20184 dd bs=4096 count=$TAPE_LENGTH if=t2-pipe.tar 2>/dev/null |
20185 PATH=$PATH ${TRUSS} tar -f t1-pipe.tar -f - \
20186       -C extract-dir-pipe -x --multi-volume \
20187       --tape-length=$TAPE_LENGTH --read-full-records || exit 1
20188
20189 cmp file1 extract-dir-pipe/file1
20190 cmp file2 extract-dir-pipe/file2
20191 ) ) >"$at_stdout" 2>"$at_stder1"
20192     at_status=$?
20193     grep '^ *+' "$at_stder1" >&2
20194     grep -v '^ *+' "$at_stder1" >"$at_stderr"
20195 else
20196     ( :;
20197 mkdir pax
20198 (cd pax
20199 TEST_TAR_FORMAT=pax
20200 export TEST_TAR_FORMAT
20201 TAR_OPTIONS="-H pax"
20202 export TAR_OPTIONS
20203 rm -rf *
20204
20205 exec <&-
20206 genfile --length 7168 --file file1
20207
20208 for block in " 1" " 2" " 3" " 4" " 5" " 6" " 7" " 8" \
20209               " 9" "10" "11" "12" "13" "14" "15" "16" ; do \
20210   echo "file2  block ${block} bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla"
20211   for count in 2 3 4 5 6 7 8 ; do
20212     echo "bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla!bla"
20213   done
20214 done >file2
20215
20216 if test $TEST_TAR_FORMAT = pax; then
20217   TAPE_LENGTH=11
20218 else
20219   TAPE_LENGTH=10
20220 fi
20221
20222 tar -c --multi-volume --tape-length=$TAPE_LENGTH \
20223   --listed-incremental=t.snar \
20224   -f t1-pipe.tar -f t2-pipe.tar ./file1 ./file2 || exit 1
20225
20226 mkdir extract-dir-pipe
20227 dd bs=4096 count=$TAPE_LENGTH if=t2-pipe.tar 2>/dev/null |
20228 PATH=$PATH ${TRUSS} tar -f t1-pipe.tar -f - \
20229       -C extract-dir-pipe -x --multi-volume \
20230       --tape-length=$TAPE_LENGTH --read-full-records || exit 1
20231
20232 cmp file1 extract-dir-pipe/file1
20233 cmp file2 extract-dir-pipe/file2
20234 ) ) >"$at_stdout" 2>"$at_stderr"
20235     at_status=$?
20236 fi
20237
20238 at_failed=false
20239 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
20240 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
20241 case $at_status in
20242    77) echo 77 > "$at_status_file"; exit 77;;
20243    0) ;;
20244    *) echo "$at_srcdir/multiv01.at:30: exit code was $at_status, expected 0"
20245       at_failed=:;;
20246 esac
20247 if $at_failed; then
20248
20249
20250   echo 1 > "$at_status_file"
20251   exit 1
20252 fi
20253
20254 $at_traceon
20255
20256
20257
20258       $at_traceoff
20259       $at_times_p && times >"$at_times_file"
20260     ) 5>&1 2>&1 | eval $at_tee_pipe
20261     at_status=`cat "$at_status_file"`
20262     ;;
20263
20264   47 ) # 47. multiv02.at:28: skipping a straddling member
20265     at_setup_line='multiv02.at:28'
20266     at_desc="skipping a straddling member"
20267     $at_quiet $ECHO_N " 47: skipping a straddling member                   $ECHO_C"
20268     at_xfail=no
20269       test -f $XFAILFILE && at_xfail=yes
20270     echo "#                             -*- compilation -*-" >> "$at_group_log"
20271     (
20272       echo "47. multiv02.at:28: testing ..."
20273       $at_traceon
20274
20275
20276
20277
20278
20279   $at_traceoff
20280 echo "$at_srcdir/multiv02.at:31:
20281 mkdir gnu
20282 (cd gnu
20283 TEST_TAR_FORMAT=gnu
20284 export TEST_TAR_FORMAT
20285 TAR_OPTIONS=\"-H gnu\"
20286 export TAR_OPTIONS
20287 rm -rf *
20288
20289 genfile --length 10240 --file en
20290 genfile --length 20000 --file to
20291 genfile --length 20000 --file tre
20292 genfile --length 10240 --file fire
20293
20294 exec <&-
20295
20296 tar -c -f A.tar -f B.tar -f C.tar -M -L 30 en to tre fire || exit 1
20297 echo separator
20298 tar -v -x -f A.tar -f B.tar -f C.tar -M en || exit 1
20299 )"
20300 echo multiv02.at:31 >"$at_check_line_file"
20301
20302 at_trace_this=
20303 if test -n "$at_traceon"; then
20304     echo 'Not enabling shell tracing (command contains an embedded newline)'
20305 fi
20306
20307 if test -n "$at_trace_this"; then
20308     ( $at_traceon;
20309 mkdir gnu
20310 (cd gnu
20311 TEST_TAR_FORMAT=gnu
20312 export TEST_TAR_FORMAT
20313 TAR_OPTIONS="-H gnu"
20314 export TAR_OPTIONS
20315 rm -rf *
20316
20317 genfile --length 10240 --file en
20318 genfile --length 20000 --file to
20319 genfile --length 20000 --file tre
20320 genfile --length 10240 --file fire
20321
20322 exec <&-
20323
20324 tar -c -f A.tar -f B.tar -f C.tar -M -L 30 en to tre fire || exit 1
20325 echo separator
20326 tar -v -x -f A.tar -f B.tar -f C.tar -M en || exit 1
20327 ) ) >"$at_stdout" 2>"$at_stder1"
20328     at_status=$?
20329     grep '^ *+' "$at_stder1" >&2
20330     grep -v '^ *+' "$at_stder1" >"$at_stderr"
20331 else
20332     ( :;
20333 mkdir gnu
20334 (cd gnu
20335 TEST_TAR_FORMAT=gnu
20336 export TEST_TAR_FORMAT
20337 TAR_OPTIONS="-H gnu"
20338 export TAR_OPTIONS
20339 rm -rf *
20340
20341 genfile --length 10240 --file en
20342 genfile --length 20000 --file to
20343 genfile --length 20000 --file tre
20344 genfile --length 10240 --file fire
20345
20346 exec <&-
20347
20348 tar -c -f A.tar -f B.tar -f C.tar -M -L 30 en to tre fire || exit 1
20349 echo separator
20350 tar -v -x -f A.tar -f B.tar -f C.tar -M en || exit 1
20351 ) ) >"$at_stdout" 2>"$at_stderr"
20352     at_status=$?
20353 fi
20354
20355 at_failed=false
20356 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
20357 echo >>"$at_stdout"; echo "separator
20358 en
20359 " | $at_diff - "$at_stdout" || at_failed=:
20360 case $at_status in
20361    77) echo 77 > "$at_status_file"; exit 77;;
20362    0) ;;
20363    *) echo "$at_srcdir/multiv02.at:31: exit code was $at_status, expected 0"
20364       at_failed=:;;
20365 esac
20366 if $at_failed; then
20367
20368
20369   echo 1 > "$at_status_file"
20370   exit 1
20371 fi
20372
20373 $at_traceon
20374 $at_traceoff
20375 echo "$at_srcdir/multiv02.at:31:
20376 mkdir oldgnu
20377 (cd oldgnu
20378 TEST_TAR_FORMAT=oldgnu
20379 export TEST_TAR_FORMAT
20380 TAR_OPTIONS=\"-H oldgnu\"
20381 export TAR_OPTIONS
20382 rm -rf *
20383
20384 genfile --length 10240 --file en
20385 genfile --length 20000 --file to
20386 genfile --length 20000 --file tre
20387 genfile --length 10240 --file fire
20388
20389 exec <&-
20390
20391 tar -c -f A.tar -f B.tar -f C.tar -M -L 30 en to tre fire || exit 1
20392 echo separator
20393 tar -v -x -f A.tar -f B.tar -f C.tar -M en || exit 1
20394 )"
20395 echo multiv02.at:31 >"$at_check_line_file"
20396
20397 at_trace_this=
20398 if test -n "$at_traceon"; then
20399     echo 'Not enabling shell tracing (command contains an embedded newline)'
20400 fi
20401
20402 if test -n "$at_trace_this"; then
20403     ( $at_traceon;
20404 mkdir oldgnu
20405 (cd oldgnu
20406 TEST_TAR_FORMAT=oldgnu
20407 export TEST_TAR_FORMAT
20408 TAR_OPTIONS="-H oldgnu"
20409 export TAR_OPTIONS
20410 rm -rf *
20411
20412 genfile --length 10240 --file en
20413 genfile --length 20000 --file to
20414 genfile --length 20000 --file tre
20415 genfile --length 10240 --file fire
20416
20417 exec <&-
20418
20419 tar -c -f A.tar -f B.tar -f C.tar -M -L 30 en to tre fire || exit 1
20420 echo separator
20421 tar -v -x -f A.tar -f B.tar -f C.tar -M en || exit 1
20422 ) ) >"$at_stdout" 2>"$at_stder1"
20423     at_status=$?
20424     grep '^ *+' "$at_stder1" >&2
20425     grep -v '^ *+' "$at_stder1" >"$at_stderr"
20426 else
20427     ( :;
20428 mkdir oldgnu
20429 (cd oldgnu
20430 TEST_TAR_FORMAT=oldgnu
20431 export TEST_TAR_FORMAT
20432 TAR_OPTIONS="-H oldgnu"
20433 export TAR_OPTIONS
20434 rm -rf *
20435
20436 genfile --length 10240 --file en
20437 genfile --length 20000 --file to
20438 genfile --length 20000 --file tre
20439 genfile --length 10240 --file fire
20440
20441 exec <&-
20442
20443 tar -c -f A.tar -f B.tar -f C.tar -M -L 30 en to tre fire || exit 1
20444 echo separator
20445 tar -v -x -f A.tar -f B.tar -f C.tar -M en || exit 1
20446 ) ) >"$at_stdout" 2>"$at_stderr"
20447     at_status=$?
20448 fi
20449
20450 at_failed=false
20451 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
20452 echo >>"$at_stdout"; echo "separator
20453 en
20454 " | $at_diff - "$at_stdout" || at_failed=:
20455 case $at_status in
20456    77) echo 77 > "$at_status_file"; exit 77;;
20457    0) ;;
20458    *) echo "$at_srcdir/multiv02.at:31: exit code was $at_status, expected 0"
20459       at_failed=:;;
20460 esac
20461 if $at_failed; then
20462
20463
20464   echo 1 > "$at_status_file"
20465   exit 1
20466 fi
20467
20468 $at_traceon
20469 $at_traceoff
20470 echo "$at_srcdir/multiv02.at:31:
20471 mkdir pax
20472 (cd pax
20473 TEST_TAR_FORMAT=pax
20474 export TEST_TAR_FORMAT
20475 TAR_OPTIONS=\"-H pax\"
20476 export TAR_OPTIONS
20477 rm -rf *
20478
20479 genfile --length 10240 --file en
20480 genfile --length 20000 --file to
20481 genfile --length 20000 --file tre
20482 genfile --length 10240 --file fire
20483
20484 exec <&-
20485
20486 tar -c -f A.tar -f B.tar -f C.tar -M -L 30 en to tre fire || exit 1
20487 echo separator
20488 tar -v -x -f A.tar -f B.tar -f C.tar -M en || exit 1
20489 )"
20490 echo multiv02.at:31 >"$at_check_line_file"
20491
20492 at_trace_this=
20493 if test -n "$at_traceon"; then
20494     echo 'Not enabling shell tracing (command contains an embedded newline)'
20495 fi
20496
20497 if test -n "$at_trace_this"; then
20498     ( $at_traceon;
20499 mkdir pax
20500 (cd pax
20501 TEST_TAR_FORMAT=pax
20502 export TEST_TAR_FORMAT
20503 TAR_OPTIONS="-H pax"
20504 export TAR_OPTIONS
20505 rm -rf *
20506
20507 genfile --length 10240 --file en
20508 genfile --length 20000 --file to
20509 genfile --length 20000 --file tre
20510 genfile --length 10240 --file fire
20511
20512 exec <&-
20513
20514 tar -c -f A.tar -f B.tar -f C.tar -M -L 30 en to tre fire || exit 1
20515 echo separator
20516 tar -v -x -f A.tar -f B.tar -f C.tar -M en || exit 1
20517 ) ) >"$at_stdout" 2>"$at_stder1"
20518     at_status=$?
20519     grep '^ *+' "$at_stder1" >&2
20520     grep -v '^ *+' "$at_stder1" >"$at_stderr"
20521 else
20522     ( :;
20523 mkdir pax
20524 (cd pax
20525 TEST_TAR_FORMAT=pax
20526 export TEST_TAR_FORMAT
20527 TAR_OPTIONS="-H pax"
20528 export TAR_OPTIONS
20529 rm -rf *
20530
20531 genfile --length 10240 --file en
20532 genfile --length 20000 --file to
20533 genfile --length 20000 --file tre
20534 genfile --length 10240 --file fire
20535
20536 exec <&-
20537
20538 tar -c -f A.tar -f B.tar -f C.tar -M -L 30 en to tre fire || exit 1
20539 echo separator
20540 tar -v -x -f A.tar -f B.tar -f C.tar -M en || exit 1
20541 ) ) >"$at_stdout" 2>"$at_stderr"
20542     at_status=$?
20543 fi
20544
20545 at_failed=false
20546 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
20547 echo >>"$at_stdout"; echo "separator
20548 en
20549 " | $at_diff - "$at_stdout" || at_failed=:
20550 case $at_status in
20551    77) echo 77 > "$at_status_file"; exit 77;;
20552    0) ;;
20553    *) echo "$at_srcdir/multiv02.at:31: exit code was $at_status, expected 0"
20554       at_failed=:;;
20555 esac
20556 if $at_failed; then
20557
20558
20559   echo 1 > "$at_status_file"
20560   exit 1
20561 fi
20562
20563 $at_traceon
20564
20565
20566
20567       $at_traceoff
20568       $at_times_p && times >"$at_times_file"
20569     ) 5>&1 2>&1 | eval $at_tee_pipe
20570     at_status=`cat "$at_status_file"`
20571     ;;
20572
20573   48 ) # 48. multiv03.at:30: MV archive & long filenames
20574     at_setup_line='multiv03.at:30'
20575     at_desc="MV archive & long filenames"
20576     $at_quiet $ECHO_N " 48: MV archive & long filenames                    $ECHO_C"
20577     at_xfail=no
20578       test -f $XFAILFILE && at_xfail=yes
20579     echo "#                             -*- compilation -*-" >> "$at_group_log"
20580     (
20581       echo "48. multiv03.at:30: testing ..."
20582       $at_traceon
20583
20584
20585
20586
20587
20588   $at_traceoff
20589 echo "$at_srcdir/multiv03.at:33:
20590 mkdir gnu
20591 (cd gnu
20592 TEST_TAR_FORMAT=gnu
20593 export TEST_TAR_FORMAT
20594 TAR_OPTIONS=\"-H gnu\"
20595 export TAR_OPTIONS
20596 rm -rf *
20597
20598 AFILE=\`awk 'BEGIN { for (i = 0; i < 100; i++) printf \"a\"; exit; }'\`
20599 BFILE=\`awk 'BEGIN { for (i = 0; i < 101; i++) printf \"b\"; exit; }'\`
20600
20601 cat > ../experr <<EOF
20602 tar: \$BFILE: file name too long to be stored in a GNU multivolume header, truncated
20603 tar: \\\`\$BFILE' is possibly continued on this volume: header contains truncated name
20604 EOF
20605
20606 cat > ../expout <<EOF
20607 \$AFILE
20608 separator-1
20609 separator-2
20610 EOF
20611
20612 genfile --length 15360 --file \$AFILE
20613
20614 exec <&-
20615
20616 tar -M -L 10 -c -f arch.1 -f arch.2 \$AFILE || exit 1
20617 tar -tM -f arch.1 -f arch.2 || exit 1
20618
20619 echo separator-1
20620
20621 genfile --length 15360 --file \$BFILE
20622 tar -M -L 10 -c -f arch.1 -f arch.2 \$BFILE || exit 1
20623
20624 echo separator-2
20625 mv \$BFILE bfile
20626 tar -M -x -f arch.1 -f arch.2 || exit 1
20627 cmp \$BFILE bfile
20628 )"
20629 echo multiv03.at:33 >"$at_check_line_file"
20630
20631 at_trace_this=
20632 if test -n "$at_traceon"; then
20633     echo 'Not enabling shell tracing (command contains a `...` command substitution)'
20634 fi
20635
20636 if test -n "$at_trace_this"; then
20637     ( $at_traceon;
20638 mkdir gnu
20639 (cd gnu
20640 TEST_TAR_FORMAT=gnu
20641 export TEST_TAR_FORMAT
20642 TAR_OPTIONS="-H gnu"
20643 export TAR_OPTIONS
20644 rm -rf *
20645
20646 AFILE=`awk 'BEGIN { for (i = 0; i < 100; i++) printf "a"; exit; }'`
20647 BFILE=`awk 'BEGIN { for (i = 0; i < 101; i++) printf "b"; exit; }'`
20648
20649 cat > ../experr <<EOF
20650 tar: $BFILE: file name too long to be stored in a GNU multivolume header, truncated
20651 tar: \`$BFILE' is possibly continued on this volume: header contains truncated name
20652 EOF
20653
20654 cat > ../expout <<EOF
20655 $AFILE
20656 separator-1
20657 separator-2
20658 EOF
20659
20660 genfile --length 15360 --file $AFILE
20661
20662 exec <&-
20663
20664 tar -M -L 10 -c -f arch.1 -f arch.2 $AFILE || exit 1
20665 tar -tM -f arch.1 -f arch.2 || exit 1
20666
20667 echo separator-1
20668
20669 genfile --length 15360 --file $BFILE
20670 tar -M -L 10 -c -f arch.1 -f arch.2 $BFILE || exit 1
20671
20672 echo separator-2
20673 mv $BFILE bfile
20674 tar -M -x -f arch.1 -f arch.2 || exit 1
20675 cmp $BFILE bfile
20676 ) ) >"$at_stdout" 2>"$at_stder1"
20677     at_status=$?
20678     grep '^ *+' "$at_stder1" >&2
20679     grep -v '^ *+' "$at_stder1" >"$at_stderr"
20680 else
20681     ( :;
20682 mkdir gnu
20683 (cd gnu
20684 TEST_TAR_FORMAT=gnu
20685 export TEST_TAR_FORMAT
20686 TAR_OPTIONS="-H gnu"
20687 export TAR_OPTIONS
20688 rm -rf *
20689
20690 AFILE=`awk 'BEGIN { for (i = 0; i < 100; i++) printf "a"; exit; }'`
20691 BFILE=`awk 'BEGIN { for (i = 0; i < 101; i++) printf "b"; exit; }'`
20692
20693 cat > ../experr <<EOF
20694 tar: $BFILE: file name too long to be stored in a GNU multivolume header, truncated
20695 tar: \`$BFILE' is possibly continued on this volume: header contains truncated name
20696 EOF
20697
20698 cat > ../expout <<EOF
20699 $AFILE
20700 separator-1
20701 separator-2
20702 EOF
20703
20704 genfile --length 15360 --file $AFILE
20705
20706 exec <&-
20707
20708 tar -M -L 10 -c -f arch.1 -f arch.2 $AFILE || exit 1
20709 tar -tM -f arch.1 -f arch.2 || exit 1
20710
20711 echo separator-1
20712
20713 genfile --length 15360 --file $BFILE
20714 tar -M -L 10 -c -f arch.1 -f arch.2 $BFILE || exit 1
20715
20716 echo separator-2
20717 mv $BFILE bfile
20718 tar -M -x -f arch.1 -f arch.2 || exit 1
20719 cmp $BFILE bfile
20720 ) ) >"$at_stdout" 2>"$at_stderr"
20721     at_status=$?
20722 fi
20723
20724 at_failed=false
20725 $at_diff experr "$at_stderr" || at_failed=:
20726 $at_diff expout "$at_stdout" || at_failed=:
20727 case $at_status in
20728    77) echo 77 > "$at_status_file"; exit 77;;
20729    0) ;;
20730    *) echo "$at_srcdir/multiv03.at:33: exit code was $at_status, expected 0"
20731       at_failed=:;;
20732 esac
20733 if $at_failed; then
20734
20735
20736   echo 1 > "$at_status_file"
20737   exit 1
20738 fi
20739
20740 $at_traceon
20741 $at_traceoff
20742 echo "$at_srcdir/multiv03.at:33:
20743 mkdir oldgnu
20744 (cd oldgnu
20745 TEST_TAR_FORMAT=oldgnu
20746 export TEST_TAR_FORMAT
20747 TAR_OPTIONS=\"-H oldgnu\"
20748 export TAR_OPTIONS
20749 rm -rf *
20750
20751 AFILE=\`awk 'BEGIN { for (i = 0; i < 100; i++) printf \"a\"; exit; }'\`
20752 BFILE=\`awk 'BEGIN { for (i = 0; i < 101; i++) printf \"b\"; exit; }'\`
20753
20754 cat > ../experr <<EOF
20755 tar: \$BFILE: file name too long to be stored in a GNU multivolume header, truncated
20756 tar: \\\`\$BFILE' is possibly continued on this volume: header contains truncated name
20757 EOF
20758
20759 cat > ../expout <<EOF
20760 \$AFILE
20761 separator-1
20762 separator-2
20763 EOF
20764
20765 genfile --length 15360 --file \$AFILE
20766
20767 exec <&-
20768
20769 tar -M -L 10 -c -f arch.1 -f arch.2 \$AFILE || exit 1
20770 tar -tM -f arch.1 -f arch.2 || exit 1
20771
20772 echo separator-1
20773
20774 genfile --length 15360 --file \$BFILE
20775 tar -M -L 10 -c -f arch.1 -f arch.2 \$BFILE || exit 1
20776
20777 echo separator-2
20778 mv \$BFILE bfile
20779 tar -M -x -f arch.1 -f arch.2 || exit 1
20780 cmp \$BFILE bfile
20781 )"
20782 echo multiv03.at:33 >"$at_check_line_file"
20783
20784 at_trace_this=
20785 if test -n "$at_traceon"; then
20786     echo 'Not enabling shell tracing (command contains a `...` command substitution)'
20787 fi
20788
20789 if test -n "$at_trace_this"; then
20790     ( $at_traceon;
20791 mkdir oldgnu
20792 (cd oldgnu
20793 TEST_TAR_FORMAT=oldgnu
20794 export TEST_TAR_FORMAT
20795 TAR_OPTIONS="-H oldgnu"
20796 export TAR_OPTIONS
20797 rm -rf *
20798
20799 AFILE=`awk 'BEGIN { for (i = 0; i < 100; i++) printf "a"; exit; }'`
20800 BFILE=`awk 'BEGIN { for (i = 0; i < 101; i++) printf "b"; exit; }'`
20801
20802 cat > ../experr <<EOF
20803 tar: $BFILE: file name too long to be stored in a GNU multivolume header, truncated
20804 tar: \`$BFILE' is possibly continued on this volume: header contains truncated name
20805 EOF
20806
20807 cat > ../expout <<EOF
20808 $AFILE
20809 separator-1
20810 separator-2
20811 EOF
20812
20813 genfile --length 15360 --file $AFILE
20814
20815 exec <&-
20816
20817 tar -M -L 10 -c -f arch.1 -f arch.2 $AFILE || exit 1
20818 tar -tM -f arch.1 -f arch.2 || exit 1
20819
20820 echo separator-1
20821
20822 genfile --length 15360 --file $BFILE
20823 tar -M -L 10 -c -f arch.1 -f arch.2 $BFILE || exit 1
20824
20825 echo separator-2
20826 mv $BFILE bfile
20827 tar -M -x -f arch.1 -f arch.2 || exit 1
20828 cmp $BFILE bfile
20829 ) ) >"$at_stdout" 2>"$at_stder1"
20830     at_status=$?
20831     grep '^ *+' "$at_stder1" >&2
20832     grep -v '^ *+' "$at_stder1" >"$at_stderr"
20833 else
20834     ( :;
20835 mkdir oldgnu
20836 (cd oldgnu
20837 TEST_TAR_FORMAT=oldgnu
20838 export TEST_TAR_FORMAT
20839 TAR_OPTIONS="-H oldgnu"
20840 export TAR_OPTIONS
20841 rm -rf *
20842
20843 AFILE=`awk 'BEGIN { for (i = 0; i < 100; i++) printf "a"; exit; }'`
20844 BFILE=`awk 'BEGIN { for (i = 0; i < 101; i++) printf "b"; exit; }'`
20845
20846 cat > ../experr <<EOF
20847 tar: $BFILE: file name too long to be stored in a GNU multivolume header, truncated
20848 tar: \`$BFILE' is possibly continued on this volume: header contains truncated name
20849 EOF
20850
20851 cat > ../expout <<EOF
20852 $AFILE
20853 separator-1
20854 separator-2
20855 EOF
20856
20857 genfile --length 15360 --file $AFILE
20858
20859 exec <&-
20860
20861 tar -M -L 10 -c -f arch.1 -f arch.2 $AFILE || exit 1
20862 tar -tM -f arch.1 -f arch.2 || exit 1
20863
20864 echo separator-1
20865
20866 genfile --length 15360 --file $BFILE
20867 tar -M -L 10 -c -f arch.1 -f arch.2 $BFILE || exit 1
20868
20869 echo separator-2
20870 mv $BFILE bfile
20871 tar -M -x -f arch.1 -f arch.2 || exit 1
20872 cmp $BFILE bfile
20873 ) ) >"$at_stdout" 2>"$at_stderr"
20874     at_status=$?
20875 fi
20876
20877 at_failed=false
20878 $at_diff experr "$at_stderr" || at_failed=:
20879 $at_diff expout "$at_stdout" || at_failed=:
20880 case $at_status in
20881    77) echo 77 > "$at_status_file"; exit 77;;
20882    0) ;;
20883    *) echo "$at_srcdir/multiv03.at:33: exit code was $at_status, expected 0"
20884       at_failed=:;;
20885 esac
20886 if $at_failed; then
20887
20888
20889   echo 1 > "$at_status_file"
20890   exit 1
20891 fi
20892
20893 $at_traceon
20894
20895
20896
20897       $at_traceoff
20898       $at_times_p && times >"$at_times_file"
20899     ) 5>&1 2>&1 | eval $at_tee_pipe
20900     at_status=`cat "$at_status_file"`
20901     ;;
20902
20903   49 ) # 49. multiv04.at:36: split directory members in a MV archive
20904     at_setup_line='multiv04.at:36'
20905     at_desc="split directory members in a MV archive"
20906     $at_quiet $ECHO_N " 49: split directory members in a MV archive        $ECHO_C"
20907     at_xfail=no
20908       test -f $XFAILFILE && at_xfail=yes
20909     echo "#                             -*- compilation -*-" >> "$at_group_log"
20910     (
20911       echo "49. multiv04.at:36: testing ..."
20912       $at_traceon
20913
20914
20915
20916
20917
20918   $at_traceoff
20919 echo "$at_srcdir/multiv04.at:39:
20920 mkdir gnu
20921 (cd gnu
20922 TEST_TAR_FORMAT=gnu
20923 export TEST_TAR_FORMAT
20924 TAR_OPTIONS=\"-H gnu\"
20925 export TAR_OPTIONS
20926 rm -rf *
20927
20928
20929 mkdir directory
20930 awk 'BEGIN { for (i = 0; i < 1024; i++) printf(\"directory/%014x\\n\", i); }' </dev/null | genfile --files-from -
20931
20932 exec <&-
20933
20934 sleep 2
20935
20936 tar --listed-incremental=list -c -f archive.a directory
20937
20938 sleep 2
20939
20940 tar --listed-incremental=list -c --record-size 1024 -L 16 -f arc.1 -f arc.2 -v directory
20941
20942 echo separator
20943
20944 tar -MRt -f arc.1 -f arc.2)"
20945 echo multiv04.at:39 >"$at_check_line_file"
20946
20947 at_trace_this=
20948 if test -n "$at_traceon"; then
20949     echo 'Not enabling shell tracing (command contains an embedded newline)'
20950 fi
20951
20952 if test -n "$at_trace_this"; then
20953     ( $at_traceon;
20954 mkdir gnu
20955 (cd gnu
20956 TEST_TAR_FORMAT=gnu
20957 export TEST_TAR_FORMAT
20958 TAR_OPTIONS="-H gnu"
20959 export TAR_OPTIONS
20960 rm -rf *
20961
20962
20963 mkdir directory
20964 awk 'BEGIN { for (i = 0; i < 1024; i++) printf("directory/%014x\n", i); }' </dev/null | genfile --files-from -
20965
20966 exec <&-
20967
20968 sleep 2
20969
20970 tar --listed-incremental=list -c -f archive.a directory
20971
20972 sleep 2
20973
20974 tar --listed-incremental=list -c --record-size 1024 -L 16 -f arc.1 -f arc.2 -v directory
20975
20976 echo separator
20977
20978 tar -MRt -f arc.1 -f arc.2) ) >"$at_stdout" 2>"$at_stder1"
20979     at_status=$?
20980     grep '^ *+' "$at_stder1" >&2
20981     grep -v '^ *+' "$at_stder1" >"$at_stderr"
20982 else
20983     ( :;
20984 mkdir gnu
20985 (cd gnu
20986 TEST_TAR_FORMAT=gnu
20987 export TEST_TAR_FORMAT
20988 TAR_OPTIONS="-H gnu"
20989 export TAR_OPTIONS
20990 rm -rf *
20991
20992
20993 mkdir directory
20994 awk 'BEGIN { for (i = 0; i < 1024; i++) printf("directory/%014x\n", i); }' </dev/null | genfile --files-from -
20995
20996 exec <&-
20997
20998 sleep 2
20999
21000 tar --listed-incremental=list -c -f archive.a directory
21001
21002 sleep 2
21003
21004 tar --listed-incremental=list -c --record-size 1024 -L 16 -f arc.1 -f arc.2 -v directory
21005
21006 echo separator
21007
21008 tar -MRt -f arc.1 -f arc.2) ) >"$at_stdout" 2>"$at_stderr"
21009     at_status=$?
21010 fi
21011
21012 at_failed=false
21013 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
21014 echo >>"$at_stdout"; echo "directory/
21015 separator
21016 block 0: directory/
21017 block 35: ** Block of NULs **
21018 " | $at_diff - "$at_stdout" || at_failed=:
21019 case $at_status in
21020    77) echo 77 > "$at_status_file"; exit 77;;
21021    0) ;;
21022    *) echo "$at_srcdir/multiv04.at:39: exit code was $at_status, expected 0"
21023       at_failed=:;;
21024 esac
21025 if $at_failed; then
21026
21027
21028   echo 1 > "$at_status_file"
21029   exit 1
21030 fi
21031
21032 $at_traceon
21033 $at_traceoff
21034 echo "$at_srcdir/multiv04.at:39:
21035 mkdir oldgnu
21036 (cd oldgnu
21037 TEST_TAR_FORMAT=oldgnu
21038 export TEST_TAR_FORMAT
21039 TAR_OPTIONS=\"-H oldgnu\"
21040 export TAR_OPTIONS
21041 rm -rf *
21042
21043
21044 mkdir directory
21045 awk 'BEGIN { for (i = 0; i < 1024; i++) printf(\"directory/%014x\\n\", i); }' </dev/null | genfile --files-from -
21046
21047 exec <&-
21048
21049 sleep 2
21050
21051 tar --listed-incremental=list -c -f archive.a directory
21052
21053 sleep 2
21054
21055 tar --listed-incremental=list -c --record-size 1024 -L 16 -f arc.1 -f arc.2 -v directory
21056
21057 echo separator
21058
21059 tar -MRt -f arc.1 -f arc.2)"
21060 echo multiv04.at:39 >"$at_check_line_file"
21061
21062 at_trace_this=
21063 if test -n "$at_traceon"; then
21064     echo 'Not enabling shell tracing (command contains an embedded newline)'
21065 fi
21066
21067 if test -n "$at_trace_this"; then
21068     ( $at_traceon;
21069 mkdir oldgnu
21070 (cd oldgnu
21071 TEST_TAR_FORMAT=oldgnu
21072 export TEST_TAR_FORMAT
21073 TAR_OPTIONS="-H oldgnu"
21074 export TAR_OPTIONS
21075 rm -rf *
21076
21077
21078 mkdir directory
21079 awk 'BEGIN { for (i = 0; i < 1024; i++) printf("directory/%014x\n", i); }' </dev/null | genfile --files-from -
21080
21081 exec <&-
21082
21083 sleep 2
21084
21085 tar --listed-incremental=list -c -f archive.a directory
21086
21087 sleep 2
21088
21089 tar --listed-incremental=list -c --record-size 1024 -L 16 -f arc.1 -f arc.2 -v directory
21090
21091 echo separator
21092
21093 tar -MRt -f arc.1 -f arc.2) ) >"$at_stdout" 2>"$at_stder1"
21094     at_status=$?
21095     grep '^ *+' "$at_stder1" >&2
21096     grep -v '^ *+' "$at_stder1" >"$at_stderr"
21097 else
21098     ( :;
21099 mkdir oldgnu
21100 (cd oldgnu
21101 TEST_TAR_FORMAT=oldgnu
21102 export TEST_TAR_FORMAT
21103 TAR_OPTIONS="-H oldgnu"
21104 export TAR_OPTIONS
21105 rm -rf *
21106
21107
21108 mkdir directory
21109 awk 'BEGIN { for (i = 0; i < 1024; i++) printf("directory/%014x\n", i); }' </dev/null | genfile --files-from -
21110
21111 exec <&-
21112
21113 sleep 2
21114
21115 tar --listed-incremental=list -c -f archive.a directory
21116
21117 sleep 2
21118
21119 tar --listed-incremental=list -c --record-size 1024 -L 16 -f arc.1 -f arc.2 -v directory
21120
21121 echo separator
21122
21123 tar -MRt -f arc.1 -f arc.2) ) >"$at_stdout" 2>"$at_stderr"
21124     at_status=$?
21125 fi
21126
21127 at_failed=false
21128 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
21129 echo >>"$at_stdout"; echo "directory/
21130 separator
21131 block 0: directory/
21132 block 35: ** Block of NULs **
21133 " | $at_diff - "$at_stdout" || at_failed=:
21134 case $at_status in
21135    77) echo 77 > "$at_status_file"; exit 77;;
21136    0) ;;
21137    *) echo "$at_srcdir/multiv04.at:39: exit code was $at_status, expected 0"
21138       at_failed=:;;
21139 esac
21140 if $at_failed; then
21141
21142
21143   echo 1 > "$at_status_file"
21144   exit 1
21145 fi
21146
21147 $at_traceon
21148
21149
21150
21151       $at_traceoff
21152       $at_times_p && times >"$at_times_file"
21153     ) 5>&1 2>&1 | eval $at_tee_pipe
21154     at_status=`cat "$at_status_file"`
21155     ;;
21156
21157   50 ) # 50. multiv05.at:26: Restoring after an out of sync volume
21158     at_setup_line='multiv05.at:26'
21159     at_desc="Restoring after an out of sync volume"
21160     $at_quiet $ECHO_N " 50: Restoring after an out of sync volume          $ECHO_C"
21161     at_xfail=no
21162       test -f $XFAILFILE && at_xfail=yes
21163     echo "#                             -*- compilation -*-" >> "$at_group_log"
21164     (
21165       echo "50. multiv05.at:26: testing ..."
21166       $at_traceon
21167
21168
21169
21170
21171
21172
21173   $at_traceoff
21174 echo "$at_srcdir/multiv05.at:30:
21175 mkdir gnu
21176 (cd gnu
21177 TEST_TAR_FORMAT=gnu
21178 export TEST_TAR_FORMAT
21179 TAR_OPTIONS=\"-H gnu\"
21180 export TAR_OPTIONS
21181 rm -rf *
21182
21183 exec <&-
21184
21185 genfile --length 250k --file jeden
21186 genfile --length 250k --file dwa
21187 genfile --length 250k --file trzy
21188 genfile --length 250k --file cztery
21189 genfile --length 250k --file piec
21190 genfile --length 250k --file szesc
21191
21192
21193 echo Creating archive
21194 tar -c -M -L 502 -f a.tar -f b.tar -f c.tar jeden dwa trzy cztery piec szesc
21195 echo separator
21196 mkdir bak
21197 mv jeden dwa trzy cztery piec szesc bak
21198 tar -vxM -f a.tar -f c.tar -f b.tar -f c.tar
21199 echo Diffing jeden
21200    cmp bak/jeden jeden || exit 1
21201 echo Diffing dwa
21202    cmp bak/dwa dwa || exit 1
21203 echo Diffing trzy
21204    cmp bak/trzy trzy || exit 1
21205 echo Diffing cztery
21206    cmp bak/cztery cztery || exit 1
21207 echo Diffing piec
21208    cmp bak/piec piec || exit 1
21209 echo Diffing szesc
21210    cmp bak/szesc szesc || exit 1
21211 )"
21212 echo multiv05.at:30 >"$at_check_line_file"
21213
21214 at_trace_this=
21215 if test -n "$at_traceon"; then
21216     echo 'Not enabling shell tracing (command contains an embedded newline)'
21217 fi
21218
21219 if test -n "$at_trace_this"; then
21220     ( $at_traceon;
21221 mkdir gnu
21222 (cd gnu
21223 TEST_TAR_FORMAT=gnu
21224 export TEST_TAR_FORMAT
21225 TAR_OPTIONS="-H gnu"
21226 export TAR_OPTIONS
21227 rm -rf *
21228
21229 exec <&-
21230
21231 genfile --length 250k --file jeden
21232 genfile --length 250k --file dwa
21233 genfile --length 250k --file trzy
21234 genfile --length 250k --file cztery
21235 genfile --length 250k --file piec
21236 genfile --length 250k --file szesc
21237
21238
21239 echo Creating archive
21240 tar -c -M -L 502 -f a.tar -f b.tar -f c.tar jeden dwa trzy cztery piec szesc
21241 echo separator
21242 mkdir bak
21243 mv jeden dwa trzy cztery piec szesc bak
21244 tar -vxM -f a.tar -f c.tar -f b.tar -f c.tar
21245 echo Diffing jeden
21246    cmp bak/jeden jeden || exit 1
21247 echo Diffing dwa
21248    cmp bak/dwa dwa || exit 1
21249 echo Diffing trzy
21250    cmp bak/trzy trzy || exit 1
21251 echo Diffing cztery
21252    cmp bak/cztery cztery || exit 1
21253 echo Diffing piec
21254    cmp bak/piec piec || exit 1
21255 echo Diffing szesc
21256    cmp bak/szesc szesc || exit 1
21257 ) ) >"$at_stdout" 2>"$at_stder1"
21258     at_status=$?
21259     grep '^ *+' "$at_stder1" >&2
21260     grep -v '^ *+' "$at_stder1" >"$at_stderr"
21261 else
21262     ( :;
21263 mkdir gnu
21264 (cd gnu
21265 TEST_TAR_FORMAT=gnu
21266 export TEST_TAR_FORMAT
21267 TAR_OPTIONS="-H gnu"
21268 export TAR_OPTIONS
21269 rm -rf *
21270
21271 exec <&-
21272
21273 genfile --length 250k --file jeden
21274 genfile --length 250k --file dwa
21275 genfile --length 250k --file trzy
21276 genfile --length 250k --file cztery
21277 genfile --length 250k --file piec
21278 genfile --length 250k --file szesc
21279
21280
21281 echo Creating archive
21282 tar -c -M -L 502 -f a.tar -f b.tar -f c.tar jeden dwa trzy cztery piec szesc
21283 echo separator
21284 mkdir bak
21285 mv jeden dwa trzy cztery piec szesc bak
21286 tar -vxM -f a.tar -f c.tar -f b.tar -f c.tar
21287 echo Diffing jeden
21288    cmp bak/jeden jeden || exit 1
21289 echo Diffing dwa
21290    cmp bak/dwa dwa || exit 1
21291 echo Diffing trzy
21292    cmp bak/trzy trzy || exit 1
21293 echo Diffing cztery
21294    cmp bak/cztery cztery || exit 1
21295 echo Diffing piec
21296    cmp bak/piec piec || exit 1
21297 echo Diffing szesc
21298    cmp bak/szesc szesc || exit 1
21299 ) ) >"$at_stdout" 2>"$at_stderr"
21300     at_status=$?
21301 fi
21302
21303 at_failed=false
21304 echo >>"$at_stderr"; echo "tar: \`trzy' is not continued on this volume
21305 " | $at_diff - "$at_stderr" || at_failed=:
21306 echo >>"$at_stdout"; echo "Creating archive
21307 separator
21308 jeden
21309 dwa
21310 trzy
21311 cztery
21312 piec
21313 szesc
21314 Diffing jeden
21315 Diffing dwa
21316 Diffing trzy
21317 Diffing cztery
21318 Diffing piec
21319 Diffing szesc
21320 " | $at_diff - "$at_stdout" || at_failed=:
21321 case $at_status in
21322    77) echo 77 > "$at_status_file"; exit 77;;
21323    0) ;;
21324    *) echo "$at_srcdir/multiv05.at:30: exit code was $at_status, expected 0"
21325       at_failed=:;;
21326 esac
21327 if $at_failed; then
21328
21329
21330   echo 1 > "$at_status_file"
21331   exit 1
21332 fi
21333
21334 $at_traceon
21335
21336
21337
21338       $at_traceoff
21339       $at_times_p && times >"$at_times_file"
21340     ) 5>&1 2>&1 | eval $at_tee_pipe
21341     at_status=`cat "$at_status_file"`
21342     ;;
21343
21344   51 ) # 51. multiv06.at:27: Multivolumes with L=record_size
21345     at_setup_line='multiv06.at:27'
21346     at_desc="Multivolumes with L=record_size"
21347     $at_quiet $ECHO_N " 51: Multivolumes with L=record_size                $ECHO_C"
21348     at_xfail=no
21349       test -f $XFAILFILE && at_xfail=yes
21350     echo "#                             -*- compilation -*-" >> "$at_group_log"
21351     (
21352       echo "51. multiv06.at:27: testing ..."
21353       $at_traceon
21354
21355
21356
21357
21358
21359   $at_traceoff
21360 echo "$at_srcdir/multiv06.at:30:
21361 mkdir gnu
21362 (cd gnu
21363 TEST_TAR_FORMAT=gnu
21364 export TEST_TAR_FORMAT
21365 TAR_OPTIONS=\"-H gnu\"
21366 export TAR_OPTIONS
21367 rm -rf *
21368
21369 exec <&-
21370 decho Creating file
21371 genfile --length 20139 --file file
21372 decho Creating archive
21373 tar -c -M -L10 -b20 -farc.1 -farc.2 -farc.3 file
21374 decho Testing archive
21375 tar -t -M -farc.1 -farc.2 -farc.3)"
21376 echo multiv06.at:30 >"$at_check_line_file"
21377
21378 at_trace_this=
21379 if test -n "$at_traceon"; then
21380     echo 'Not enabling shell tracing (command contains an embedded newline)'
21381 fi
21382
21383 if test -n "$at_trace_this"; then
21384     ( $at_traceon;
21385 mkdir gnu
21386 (cd gnu
21387 TEST_TAR_FORMAT=gnu
21388 export TEST_TAR_FORMAT
21389 TAR_OPTIONS="-H gnu"
21390 export TAR_OPTIONS
21391 rm -rf *
21392
21393 exec <&-
21394 decho Creating file
21395 genfile --length 20139 --file file
21396 decho Creating archive
21397 tar -c -M -L10 -b20 -farc.1 -farc.2 -farc.3 file
21398 decho Testing archive
21399 tar -t -M -farc.1 -farc.2 -farc.3) ) >"$at_stdout" 2>"$at_stder1"
21400     at_status=$?
21401     grep '^ *+' "$at_stder1" >&2
21402     grep -v '^ *+' "$at_stder1" >"$at_stderr"
21403 else
21404     ( :;
21405 mkdir gnu
21406 (cd gnu
21407 TEST_TAR_FORMAT=gnu
21408 export TEST_TAR_FORMAT
21409 TAR_OPTIONS="-H gnu"
21410 export TAR_OPTIONS
21411 rm -rf *
21412
21413 exec <&-
21414 decho Creating file
21415 genfile --length 20139 --file file
21416 decho Creating archive
21417 tar -c -M -L10 -b20 -farc.1 -farc.2 -farc.3 file
21418 decho Testing archive
21419 tar -t -M -farc.1 -farc.2 -farc.3) ) >"$at_stdout" 2>"$at_stderr"
21420     at_status=$?
21421 fi
21422
21423 at_failed=false
21424 echo >>"$at_stderr"; echo "Creating file
21425 Creating archive
21426 Testing archive
21427 " | $at_diff - "$at_stderr" || at_failed=:
21428 echo >>"$at_stdout"; echo "Creating file
21429 Creating archive
21430 Testing archive
21431 file
21432 " | $at_diff - "$at_stdout" || at_failed=:
21433 case $at_status in
21434    77) echo 77 > "$at_status_file"; exit 77;;
21435    0) ;;
21436    *) echo "$at_srcdir/multiv06.at:30: exit code was $at_status, expected 0"
21437       at_failed=:;;
21438 esac
21439 if $at_failed; then
21440
21441
21442   echo 1 > "$at_status_file"
21443   exit 1
21444 fi
21445
21446 $at_traceon
21447 $at_traceoff
21448 echo "$at_srcdir/multiv06.at:30:
21449 mkdir pax
21450 (cd pax
21451 TEST_TAR_FORMAT=pax
21452 export TEST_TAR_FORMAT
21453 TAR_OPTIONS=\"-H pax\"
21454 export TAR_OPTIONS
21455 rm -rf *
21456
21457 exec <&-
21458 decho Creating file
21459 genfile --length 20139 --file file
21460 decho Creating archive
21461 tar -c -M -L10 -b20 -farc.1 -farc.2 -farc.3 file
21462 decho Testing archive
21463 tar -t -M -farc.1 -farc.2 -farc.3)"
21464 echo multiv06.at:30 >"$at_check_line_file"
21465
21466 at_trace_this=
21467 if test -n "$at_traceon"; then
21468     echo 'Not enabling shell tracing (command contains an embedded newline)'
21469 fi
21470
21471 if test -n "$at_trace_this"; then
21472     ( $at_traceon;
21473 mkdir pax
21474 (cd pax
21475 TEST_TAR_FORMAT=pax
21476 export TEST_TAR_FORMAT
21477 TAR_OPTIONS="-H pax"
21478 export TAR_OPTIONS
21479 rm -rf *
21480
21481 exec <&-
21482 decho Creating file
21483 genfile --length 20139 --file file
21484 decho Creating archive
21485 tar -c -M -L10 -b20 -farc.1 -farc.2 -farc.3 file
21486 decho Testing archive
21487 tar -t -M -farc.1 -farc.2 -farc.3) ) >"$at_stdout" 2>"$at_stder1"
21488     at_status=$?
21489     grep '^ *+' "$at_stder1" >&2
21490     grep -v '^ *+' "$at_stder1" >"$at_stderr"
21491 else
21492     ( :;
21493 mkdir pax
21494 (cd pax
21495 TEST_TAR_FORMAT=pax
21496 export TEST_TAR_FORMAT
21497 TAR_OPTIONS="-H pax"
21498 export TAR_OPTIONS
21499 rm -rf *
21500
21501 exec <&-
21502 decho Creating file
21503 genfile --length 20139 --file file
21504 decho Creating archive
21505 tar -c -M -L10 -b20 -farc.1 -farc.2 -farc.3 file
21506 decho Testing archive
21507 tar -t -M -farc.1 -farc.2 -farc.3) ) >"$at_stdout" 2>"$at_stderr"
21508     at_status=$?
21509 fi
21510
21511 at_failed=false
21512 echo >>"$at_stderr"; echo "Creating file
21513 Creating archive
21514 Testing archive
21515 " | $at_diff - "$at_stderr" || at_failed=:
21516 echo >>"$at_stdout"; echo "Creating file
21517 Creating archive
21518 Testing archive
21519 file
21520 " | $at_diff - "$at_stdout" || at_failed=:
21521 case $at_status in
21522    77) echo 77 > "$at_status_file"; exit 77;;
21523    0) ;;
21524    *) echo "$at_srcdir/multiv06.at:30: exit code was $at_status, expected 0"
21525       at_failed=:;;
21526 esac
21527 if $at_failed; then
21528
21529
21530   echo 1 > "$at_status_file"
21531   exit 1
21532 fi
21533
21534 $at_traceon
21535
21536
21537
21538       $at_traceoff
21539       $at_times_p && times >"$at_times_file"
21540     ) 5>&1 2>&1 | eval $at_tee_pipe
21541     at_status=`cat "$at_status_file"`
21542     ;;
21543
21544   52 ) # 52. old.at:23: old archives
21545     at_setup_line='old.at:23'
21546     at_desc="old archives"
21547     $at_quiet $ECHO_N " 52: old archives                                   $ECHO_C"
21548     at_xfail=no
21549     echo "#                             -*- compilation -*-" >> "$at_group_log"
21550     (
21551       echo "52. old.at:23: testing ..."
21552       $at_traceon
21553
21554
21555
21556 unset TAR_OPTIONS
21557 $at_traceoff
21558 echo "$at_srcdir/old.at:27:
21559 mkdir directory
21560 tar cfvo archive directory || exit 1
21561 tar tf archive
21562 "
21563 echo old.at:27 >"$at_check_line_file"
21564
21565 at_trace_this=
21566 if test -n "$at_traceon"; then
21567     echo 'Not enabling shell tracing (command contains an embedded newline)'
21568 fi
21569
21570 if test -n "$at_trace_this"; then
21571     ( $at_traceon;
21572 mkdir directory
21573 tar cfvo archive directory || exit 1
21574 tar tf archive
21575  ) >"$at_stdout" 2>"$at_stder1"
21576     at_status=$?
21577     grep '^ *+' "$at_stder1" >&2
21578     grep -v '^ *+' "$at_stder1" >"$at_stderr"
21579 else
21580     ( :;
21581 mkdir directory
21582 tar cfvo archive directory || exit 1
21583 tar tf archive
21584  ) >"$at_stdout" 2>"$at_stderr"
21585     at_status=$?
21586 fi
21587
21588 at_failed=false
21589 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
21590 echo >>"$at_stdout"; echo "directory/
21591 directory/
21592 " | $at_diff - "$at_stdout" || at_failed=:
21593 case $at_status in
21594    77) echo 77 > "$at_status_file"; exit 77;;
21595    0) ;;
21596    *) echo "$at_srcdir/old.at:27: exit code was $at_status, expected 0"
21597       at_failed=:;;
21598 esac
21599 if $at_failed; then
21600
21601
21602   echo 1 > "$at_status_file"
21603   exit 1
21604 fi
21605
21606 $at_traceon
21607
21608
21609       $at_traceoff
21610       $at_times_p && times >"$at_times_file"
21611     ) 5>&1 2>&1 | eval $at_tee_pipe
21612     at_status=`cat "$at_status_file"`
21613     ;;
21614
21615   53 ) # 53. recurse.at:21: recurse
21616     at_setup_line='recurse.at:21'
21617     at_desc="recurse"
21618     $at_quiet $ECHO_N " 53: recurse                                        $ECHO_C"
21619     at_xfail=no
21620       test -f $XFAILFILE && at_xfail=yes
21621     echo "#                             -*- compilation -*-" >> "$at_group_log"
21622     (
21623       echo "53. recurse.at:21: testing ..."
21624       $at_traceon
21625
21626
21627
21628
21629
21630   $at_traceoff
21631 echo "$at_srcdir/recurse.at:24:
21632 mkdir v7
21633 (cd v7
21634 TEST_TAR_FORMAT=v7
21635 export TEST_TAR_FORMAT
21636 TAR_OPTIONS=\"-H v7\"
21637 export TAR_OPTIONS
21638 rm -rf *
21639
21640 mkdir directory
21641 touch directory/file
21642 tar --create --file archive --no-recursion directory || exit 1
21643 tar tf archive
21644 )"
21645 echo recurse.at:24 >"$at_check_line_file"
21646
21647 at_trace_this=
21648 if test -n "$at_traceon"; then
21649     echo 'Not enabling shell tracing (command contains an embedded newline)'
21650 fi
21651
21652 if test -n "$at_trace_this"; then
21653     ( $at_traceon;
21654 mkdir v7
21655 (cd v7
21656 TEST_TAR_FORMAT=v7
21657 export TEST_TAR_FORMAT
21658 TAR_OPTIONS="-H v7"
21659 export TAR_OPTIONS
21660 rm -rf *
21661
21662 mkdir directory
21663 touch directory/file
21664 tar --create --file archive --no-recursion directory || exit 1
21665 tar tf archive
21666 ) ) >"$at_stdout" 2>"$at_stder1"
21667     at_status=$?
21668     grep '^ *+' "$at_stder1" >&2
21669     grep -v '^ *+' "$at_stder1" >"$at_stderr"
21670 else
21671     ( :;
21672 mkdir v7
21673 (cd v7
21674 TEST_TAR_FORMAT=v7
21675 export TEST_TAR_FORMAT
21676 TAR_OPTIONS="-H v7"
21677 export TAR_OPTIONS
21678 rm -rf *
21679
21680 mkdir directory
21681 touch directory/file
21682 tar --create --file archive --no-recursion directory || exit 1
21683 tar tf archive
21684 ) ) >"$at_stdout" 2>"$at_stderr"
21685     at_status=$?
21686 fi
21687
21688 at_failed=false
21689 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
21690 echo >>"$at_stdout"; echo "directory/
21691 " | $at_diff - "$at_stdout" || at_failed=:
21692 case $at_status in
21693    77) echo 77 > "$at_status_file"; exit 77;;
21694    0) ;;
21695    *) echo "$at_srcdir/recurse.at:24: exit code was $at_status, expected 0"
21696       at_failed=:;;
21697 esac
21698 if $at_failed; then
21699
21700
21701   echo 1 > "$at_status_file"
21702   exit 1
21703 fi
21704
21705 $at_traceon
21706 $at_traceoff
21707 echo "$at_srcdir/recurse.at:24:
21708 mkdir oldgnu
21709 (cd oldgnu
21710 TEST_TAR_FORMAT=oldgnu
21711 export TEST_TAR_FORMAT
21712 TAR_OPTIONS=\"-H oldgnu\"
21713 export TAR_OPTIONS
21714 rm -rf *
21715
21716 mkdir directory
21717 touch directory/file
21718 tar --create --file archive --no-recursion directory || exit 1
21719 tar tf archive
21720 )"
21721 echo recurse.at:24 >"$at_check_line_file"
21722
21723 at_trace_this=
21724 if test -n "$at_traceon"; then
21725     echo 'Not enabling shell tracing (command contains an embedded newline)'
21726 fi
21727
21728 if test -n "$at_trace_this"; then
21729     ( $at_traceon;
21730 mkdir oldgnu
21731 (cd oldgnu
21732 TEST_TAR_FORMAT=oldgnu
21733 export TEST_TAR_FORMAT
21734 TAR_OPTIONS="-H oldgnu"
21735 export TAR_OPTIONS
21736 rm -rf *
21737
21738 mkdir directory
21739 touch directory/file
21740 tar --create --file archive --no-recursion directory || exit 1
21741 tar tf archive
21742 ) ) >"$at_stdout" 2>"$at_stder1"
21743     at_status=$?
21744     grep '^ *+' "$at_stder1" >&2
21745     grep -v '^ *+' "$at_stder1" >"$at_stderr"
21746 else
21747     ( :;
21748 mkdir oldgnu
21749 (cd oldgnu
21750 TEST_TAR_FORMAT=oldgnu
21751 export TEST_TAR_FORMAT
21752 TAR_OPTIONS="-H oldgnu"
21753 export TAR_OPTIONS
21754 rm -rf *
21755
21756 mkdir directory
21757 touch directory/file
21758 tar --create --file archive --no-recursion directory || exit 1
21759 tar tf archive
21760 ) ) >"$at_stdout" 2>"$at_stderr"
21761     at_status=$?
21762 fi
21763
21764 at_failed=false
21765 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
21766 echo >>"$at_stdout"; echo "directory/
21767 " | $at_diff - "$at_stdout" || at_failed=:
21768 case $at_status in
21769    77) echo 77 > "$at_status_file"; exit 77;;
21770    0) ;;
21771    *) echo "$at_srcdir/recurse.at:24: exit code was $at_status, expected 0"
21772       at_failed=:;;
21773 esac
21774 if $at_failed; then
21775
21776
21777   echo 1 > "$at_status_file"
21778   exit 1
21779 fi
21780
21781 $at_traceon
21782 $at_traceoff
21783 echo "$at_srcdir/recurse.at:24:
21784 mkdir ustar
21785 (cd ustar
21786 TEST_TAR_FORMAT=ustar
21787 export TEST_TAR_FORMAT
21788 TAR_OPTIONS=\"-H ustar\"
21789 export TAR_OPTIONS
21790 rm -rf *
21791
21792 mkdir directory
21793 touch directory/file
21794 tar --create --file archive --no-recursion directory || exit 1
21795 tar tf archive
21796 )"
21797 echo recurse.at:24 >"$at_check_line_file"
21798
21799 at_trace_this=
21800 if test -n "$at_traceon"; then
21801     echo 'Not enabling shell tracing (command contains an embedded newline)'
21802 fi
21803
21804 if test -n "$at_trace_this"; then
21805     ( $at_traceon;
21806 mkdir ustar
21807 (cd ustar
21808 TEST_TAR_FORMAT=ustar
21809 export TEST_TAR_FORMAT
21810 TAR_OPTIONS="-H ustar"
21811 export TAR_OPTIONS
21812 rm -rf *
21813
21814 mkdir directory
21815 touch directory/file
21816 tar --create --file archive --no-recursion directory || exit 1
21817 tar tf archive
21818 ) ) >"$at_stdout" 2>"$at_stder1"
21819     at_status=$?
21820     grep '^ *+' "$at_stder1" >&2
21821     grep -v '^ *+' "$at_stder1" >"$at_stderr"
21822 else
21823     ( :;
21824 mkdir ustar
21825 (cd ustar
21826 TEST_TAR_FORMAT=ustar
21827 export TEST_TAR_FORMAT
21828 TAR_OPTIONS="-H ustar"
21829 export TAR_OPTIONS
21830 rm -rf *
21831
21832 mkdir directory
21833 touch directory/file
21834 tar --create --file archive --no-recursion directory || exit 1
21835 tar tf archive
21836 ) ) >"$at_stdout" 2>"$at_stderr"
21837     at_status=$?
21838 fi
21839
21840 at_failed=false
21841 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
21842 echo >>"$at_stdout"; echo "directory/
21843 " | $at_diff - "$at_stdout" || at_failed=:
21844 case $at_status in
21845    77) echo 77 > "$at_status_file"; exit 77;;
21846    0) ;;
21847    *) echo "$at_srcdir/recurse.at:24: exit code was $at_status, expected 0"
21848       at_failed=:;;
21849 esac
21850 if $at_failed; then
21851
21852
21853   echo 1 > "$at_status_file"
21854   exit 1
21855 fi
21856
21857 $at_traceon
21858 $at_traceoff
21859 echo "$at_srcdir/recurse.at:24:
21860 mkdir posix
21861 (cd posix
21862 TEST_TAR_FORMAT=posix
21863 export TEST_TAR_FORMAT
21864 TAR_OPTIONS=\"-H posix\"
21865 export TAR_OPTIONS
21866 rm -rf *
21867
21868 mkdir directory
21869 touch directory/file
21870 tar --create --file archive --no-recursion directory || exit 1
21871 tar tf archive
21872 )"
21873 echo recurse.at:24 >"$at_check_line_file"
21874
21875 at_trace_this=
21876 if test -n "$at_traceon"; then
21877     echo 'Not enabling shell tracing (command contains an embedded newline)'
21878 fi
21879
21880 if test -n "$at_trace_this"; then
21881     ( $at_traceon;
21882 mkdir posix
21883 (cd posix
21884 TEST_TAR_FORMAT=posix
21885 export TEST_TAR_FORMAT
21886 TAR_OPTIONS="-H posix"
21887 export TAR_OPTIONS
21888 rm -rf *
21889
21890 mkdir directory
21891 touch directory/file
21892 tar --create --file archive --no-recursion directory || exit 1
21893 tar tf archive
21894 ) ) >"$at_stdout" 2>"$at_stder1"
21895     at_status=$?
21896     grep '^ *+' "$at_stder1" >&2
21897     grep -v '^ *+' "$at_stder1" >"$at_stderr"
21898 else
21899     ( :;
21900 mkdir posix
21901 (cd posix
21902 TEST_TAR_FORMAT=posix
21903 export TEST_TAR_FORMAT
21904 TAR_OPTIONS="-H posix"
21905 export TAR_OPTIONS
21906 rm -rf *
21907
21908 mkdir directory
21909 touch directory/file
21910 tar --create --file archive --no-recursion directory || exit 1
21911 tar tf archive
21912 ) ) >"$at_stdout" 2>"$at_stderr"
21913     at_status=$?
21914 fi
21915
21916 at_failed=false
21917 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
21918 echo >>"$at_stdout"; echo "directory/
21919 " | $at_diff - "$at_stdout" || at_failed=:
21920 case $at_status in
21921    77) echo 77 > "$at_status_file"; exit 77;;
21922    0) ;;
21923    *) echo "$at_srcdir/recurse.at:24: exit code was $at_status, expected 0"
21924       at_failed=:;;
21925 esac
21926 if $at_failed; then
21927
21928
21929   echo 1 > "$at_status_file"
21930   exit 1
21931 fi
21932
21933 $at_traceon
21934 $at_traceoff
21935 echo "$at_srcdir/recurse.at:24:
21936 mkdir gnu
21937 (cd gnu
21938 TEST_TAR_FORMAT=gnu
21939 export TEST_TAR_FORMAT
21940 TAR_OPTIONS=\"-H gnu\"
21941 export TAR_OPTIONS
21942 rm -rf *
21943
21944 mkdir directory
21945 touch directory/file
21946 tar --create --file archive --no-recursion directory || exit 1
21947 tar tf archive
21948 )"
21949 echo recurse.at:24 >"$at_check_line_file"
21950
21951 at_trace_this=
21952 if test -n "$at_traceon"; then
21953     echo 'Not enabling shell tracing (command contains an embedded newline)'
21954 fi
21955
21956 if test -n "$at_trace_this"; then
21957     ( $at_traceon;
21958 mkdir gnu
21959 (cd gnu
21960 TEST_TAR_FORMAT=gnu
21961 export TEST_TAR_FORMAT
21962 TAR_OPTIONS="-H gnu"
21963 export TAR_OPTIONS
21964 rm -rf *
21965
21966 mkdir directory
21967 touch directory/file
21968 tar --create --file archive --no-recursion directory || exit 1
21969 tar tf archive
21970 ) ) >"$at_stdout" 2>"$at_stder1"
21971     at_status=$?
21972     grep '^ *+' "$at_stder1" >&2
21973     grep -v '^ *+' "$at_stder1" >"$at_stderr"
21974 else
21975     ( :;
21976 mkdir gnu
21977 (cd gnu
21978 TEST_TAR_FORMAT=gnu
21979 export TEST_TAR_FORMAT
21980 TAR_OPTIONS="-H gnu"
21981 export TAR_OPTIONS
21982 rm -rf *
21983
21984 mkdir directory
21985 touch directory/file
21986 tar --create --file archive --no-recursion directory || exit 1
21987 tar tf archive
21988 ) ) >"$at_stdout" 2>"$at_stderr"
21989     at_status=$?
21990 fi
21991
21992 at_failed=false
21993 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
21994 echo >>"$at_stdout"; echo "directory/
21995 " | $at_diff - "$at_stdout" || at_failed=:
21996 case $at_status in
21997    77) echo 77 > "$at_status_file"; exit 77;;
21998    0) ;;
21999    *) echo "$at_srcdir/recurse.at:24: exit code was $at_status, expected 0"
22000       at_failed=:;;
22001 esac
22002 if $at_failed; then
22003
22004
22005   echo 1 > "$at_status_file"
22006   exit 1
22007 fi
22008
22009 $at_traceon
22010
22011
22012
22013       $at_traceoff
22014       $at_times_p && times >"$at_times_file"
22015     ) 5>&1 2>&1 | eval $at_tee_pipe
22016     at_status=`cat "$at_status_file"`
22017     ;;
22018
22019   54 ) # 54. same-order01.at:26: working -C with --same-order
22020     at_setup_line='same-order01.at:26'
22021     at_desc="working -C with --same-order"
22022     $at_quiet $ECHO_N " 54: working -C with --same-order                   $ECHO_C"
22023     at_xfail=no
22024       test -f $XFAILFILE && at_xfail=yes
22025     echo "#                             -*- compilation -*-" >> "$at_group_log"
22026     (
22027       echo "54. same-order01.at:26: testing ..."
22028       $at_traceon
22029
22030
22031
22032
22033
22034   $at_traceoff
22035 echo "$at_srcdir/same-order01.at:29:
22036 mkdir v7
22037 (cd v7
22038 TEST_TAR_FORMAT=v7
22039 export TEST_TAR_FORMAT
22040 TAR_OPTIONS=\"-H v7\"
22041 export TAR_OPTIONS
22042 rm -rf *
22043
22044
22045 test -z "`sort < /dev/null 2>&1`" || exit 77
22046
22047
22048 genfile -l 1024 -f file1
22049 genfile -l 1024 -f file2
22050 tar cf archive file1 file2
22051
22052 mkdir directory
22053 tar -xf archive --same-order -C directory || exit 1
22054
22055 ls directory|sort
22056 )"
22057 echo same-order01.at:29 >"$at_check_line_file"
22058
22059 at_trace_this=
22060 if test -n "$at_traceon"; then
22061     echo 'Not enabling shell tracing (command contains an embedded newline)'
22062 fi
22063
22064 if test -n "$at_trace_this"; then
22065     ( $at_traceon;
22066 mkdir v7
22067 (cd v7
22068 TEST_TAR_FORMAT=v7
22069 export TEST_TAR_FORMAT
22070 TAR_OPTIONS="-H v7"
22071 export TAR_OPTIONS
22072 rm -rf *
22073
22074
22075 test -z "`sort < /dev/null 2>&1`" || exit 77
22076
22077
22078 genfile -l 1024 -f file1
22079 genfile -l 1024 -f file2
22080 tar cf archive file1 file2
22081
22082 mkdir directory
22083 tar -xf archive --same-order -C directory || exit 1
22084
22085 ls directory|sort
22086 ) ) >"$at_stdout" 2>"$at_stder1"
22087     at_status=$?
22088     grep '^ *+' "$at_stder1" >&2
22089     grep -v '^ *+' "$at_stder1" >"$at_stderr"
22090 else
22091     ( :;
22092 mkdir v7
22093 (cd v7
22094 TEST_TAR_FORMAT=v7
22095 export TEST_TAR_FORMAT
22096 TAR_OPTIONS="-H v7"
22097 export TAR_OPTIONS
22098 rm -rf *
22099
22100
22101 test -z "`sort < /dev/null 2>&1`" || exit 77
22102
22103
22104 genfile -l 1024 -f file1
22105 genfile -l 1024 -f file2
22106 tar cf archive file1 file2
22107
22108 mkdir directory
22109 tar -xf archive --same-order -C directory || exit 1
22110
22111 ls directory|sort
22112 ) ) >"$at_stdout" 2>"$at_stderr"
22113     at_status=$?
22114 fi
22115
22116 at_failed=false
22117 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
22118 echo >>"$at_stdout"; echo "file1
22119 file2
22120 " | $at_diff - "$at_stdout" || at_failed=:
22121 case $at_status in
22122    77) echo 77 > "$at_status_file"; exit 77;;
22123    0) ;;
22124    *) echo "$at_srcdir/same-order01.at:29: exit code was $at_status, expected 0"
22125       at_failed=:;;
22126 esac
22127 if $at_failed; then
22128
22129
22130   echo 1 > "$at_status_file"
22131   exit 1
22132 fi
22133
22134 $at_traceon
22135 $at_traceoff
22136 echo "$at_srcdir/same-order01.at:29:
22137 mkdir oldgnu
22138 (cd oldgnu
22139 TEST_TAR_FORMAT=oldgnu
22140 export TEST_TAR_FORMAT
22141 TAR_OPTIONS=\"-H oldgnu\"
22142 export TAR_OPTIONS
22143 rm -rf *
22144
22145
22146 test -z "`sort < /dev/null 2>&1`" || exit 77
22147
22148
22149 genfile -l 1024 -f file1
22150 genfile -l 1024 -f file2
22151 tar cf archive file1 file2
22152
22153 mkdir directory
22154 tar -xf archive --same-order -C directory || exit 1
22155
22156 ls directory|sort
22157 )"
22158 echo same-order01.at:29 >"$at_check_line_file"
22159
22160 at_trace_this=
22161 if test -n "$at_traceon"; then
22162     echo 'Not enabling shell tracing (command contains an embedded newline)'
22163 fi
22164
22165 if test -n "$at_trace_this"; then
22166     ( $at_traceon;
22167 mkdir oldgnu
22168 (cd oldgnu
22169 TEST_TAR_FORMAT=oldgnu
22170 export TEST_TAR_FORMAT
22171 TAR_OPTIONS="-H oldgnu"
22172 export TAR_OPTIONS
22173 rm -rf *
22174
22175
22176 test -z "`sort < /dev/null 2>&1`" || exit 77
22177
22178
22179 genfile -l 1024 -f file1
22180 genfile -l 1024 -f file2
22181 tar cf archive file1 file2
22182
22183 mkdir directory
22184 tar -xf archive --same-order -C directory || exit 1
22185
22186 ls directory|sort
22187 ) ) >"$at_stdout" 2>"$at_stder1"
22188     at_status=$?
22189     grep '^ *+' "$at_stder1" >&2
22190     grep -v '^ *+' "$at_stder1" >"$at_stderr"
22191 else
22192     ( :;
22193 mkdir oldgnu
22194 (cd oldgnu
22195 TEST_TAR_FORMAT=oldgnu
22196 export TEST_TAR_FORMAT
22197 TAR_OPTIONS="-H oldgnu"
22198 export TAR_OPTIONS
22199 rm -rf *
22200
22201
22202 test -z "`sort < /dev/null 2>&1`" || exit 77
22203
22204
22205 genfile -l 1024 -f file1
22206 genfile -l 1024 -f file2
22207 tar cf archive file1 file2
22208
22209 mkdir directory
22210 tar -xf archive --same-order -C directory || exit 1
22211
22212 ls directory|sort
22213 ) ) >"$at_stdout" 2>"$at_stderr"
22214     at_status=$?
22215 fi
22216
22217 at_failed=false
22218 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
22219 echo >>"$at_stdout"; echo "file1
22220 file2
22221 " | $at_diff - "$at_stdout" || at_failed=:
22222 case $at_status in
22223    77) echo 77 > "$at_status_file"; exit 77;;
22224    0) ;;
22225    *) echo "$at_srcdir/same-order01.at:29: exit code was $at_status, expected 0"
22226       at_failed=:;;
22227 esac
22228 if $at_failed; then
22229
22230
22231   echo 1 > "$at_status_file"
22232   exit 1
22233 fi
22234
22235 $at_traceon
22236 $at_traceoff
22237 echo "$at_srcdir/same-order01.at:29:
22238 mkdir ustar
22239 (cd ustar
22240 TEST_TAR_FORMAT=ustar
22241 export TEST_TAR_FORMAT
22242 TAR_OPTIONS=\"-H ustar\"
22243 export TAR_OPTIONS
22244 rm -rf *
22245
22246
22247 test -z "`sort < /dev/null 2>&1`" || exit 77
22248
22249
22250 genfile -l 1024 -f file1
22251 genfile -l 1024 -f file2
22252 tar cf archive file1 file2
22253
22254 mkdir directory
22255 tar -xf archive --same-order -C directory || exit 1
22256
22257 ls directory|sort
22258 )"
22259 echo same-order01.at:29 >"$at_check_line_file"
22260
22261 at_trace_this=
22262 if test -n "$at_traceon"; then
22263     echo 'Not enabling shell tracing (command contains an embedded newline)'
22264 fi
22265
22266 if test -n "$at_trace_this"; then
22267     ( $at_traceon;
22268 mkdir ustar
22269 (cd ustar
22270 TEST_TAR_FORMAT=ustar
22271 export TEST_TAR_FORMAT
22272 TAR_OPTIONS="-H ustar"
22273 export TAR_OPTIONS
22274 rm -rf *
22275
22276
22277 test -z "`sort < /dev/null 2>&1`" || exit 77
22278
22279
22280 genfile -l 1024 -f file1
22281 genfile -l 1024 -f file2
22282 tar cf archive file1 file2
22283
22284 mkdir directory
22285 tar -xf archive --same-order -C directory || exit 1
22286
22287 ls directory|sort
22288 ) ) >"$at_stdout" 2>"$at_stder1"
22289     at_status=$?
22290     grep '^ *+' "$at_stder1" >&2
22291     grep -v '^ *+' "$at_stder1" >"$at_stderr"
22292 else
22293     ( :;
22294 mkdir ustar
22295 (cd ustar
22296 TEST_TAR_FORMAT=ustar
22297 export TEST_TAR_FORMAT
22298 TAR_OPTIONS="-H ustar"
22299 export TAR_OPTIONS
22300 rm -rf *
22301
22302
22303 test -z "`sort < /dev/null 2>&1`" || exit 77
22304
22305
22306 genfile -l 1024 -f file1
22307 genfile -l 1024 -f file2
22308 tar cf archive file1 file2
22309
22310 mkdir directory
22311 tar -xf archive --same-order -C directory || exit 1
22312
22313 ls directory|sort
22314 ) ) >"$at_stdout" 2>"$at_stderr"
22315     at_status=$?
22316 fi
22317
22318 at_failed=false
22319 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
22320 echo >>"$at_stdout"; echo "file1
22321 file2
22322 " | $at_diff - "$at_stdout" || at_failed=:
22323 case $at_status in
22324    77) echo 77 > "$at_status_file"; exit 77;;
22325    0) ;;
22326    *) echo "$at_srcdir/same-order01.at:29: exit code was $at_status, expected 0"
22327       at_failed=:;;
22328 esac
22329 if $at_failed; then
22330
22331
22332   echo 1 > "$at_status_file"
22333   exit 1
22334 fi
22335
22336 $at_traceon
22337 $at_traceoff
22338 echo "$at_srcdir/same-order01.at:29:
22339 mkdir posix
22340 (cd posix
22341 TEST_TAR_FORMAT=posix
22342 export TEST_TAR_FORMAT
22343 TAR_OPTIONS=\"-H posix\"
22344 export TAR_OPTIONS
22345 rm -rf *
22346
22347
22348 test -z "`sort < /dev/null 2>&1`" || exit 77
22349
22350
22351 genfile -l 1024 -f file1
22352 genfile -l 1024 -f file2
22353 tar cf archive file1 file2
22354
22355 mkdir directory
22356 tar -xf archive --same-order -C directory || exit 1
22357
22358 ls directory|sort
22359 )"
22360 echo same-order01.at:29 >"$at_check_line_file"
22361
22362 at_trace_this=
22363 if test -n "$at_traceon"; then
22364     echo 'Not enabling shell tracing (command contains an embedded newline)'
22365 fi
22366
22367 if test -n "$at_trace_this"; then
22368     ( $at_traceon;
22369 mkdir posix
22370 (cd posix
22371 TEST_TAR_FORMAT=posix
22372 export TEST_TAR_FORMAT
22373 TAR_OPTIONS="-H posix"
22374 export TAR_OPTIONS
22375 rm -rf *
22376
22377
22378 test -z "`sort < /dev/null 2>&1`" || exit 77
22379
22380
22381 genfile -l 1024 -f file1
22382 genfile -l 1024 -f file2
22383 tar cf archive file1 file2
22384
22385 mkdir directory
22386 tar -xf archive --same-order -C directory || exit 1
22387
22388 ls directory|sort
22389 ) ) >"$at_stdout" 2>"$at_stder1"
22390     at_status=$?
22391     grep '^ *+' "$at_stder1" >&2
22392     grep -v '^ *+' "$at_stder1" >"$at_stderr"
22393 else
22394     ( :;
22395 mkdir posix
22396 (cd posix
22397 TEST_TAR_FORMAT=posix
22398 export TEST_TAR_FORMAT
22399 TAR_OPTIONS="-H posix"
22400 export TAR_OPTIONS
22401 rm -rf *
22402
22403
22404 test -z "`sort < /dev/null 2>&1`" || exit 77
22405
22406
22407 genfile -l 1024 -f file1
22408 genfile -l 1024 -f file2
22409 tar cf archive file1 file2
22410
22411 mkdir directory
22412 tar -xf archive --same-order -C directory || exit 1
22413
22414 ls directory|sort
22415 ) ) >"$at_stdout" 2>"$at_stderr"
22416     at_status=$?
22417 fi
22418
22419 at_failed=false
22420 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
22421 echo >>"$at_stdout"; echo "file1
22422 file2
22423 " | $at_diff - "$at_stdout" || at_failed=:
22424 case $at_status in
22425    77) echo 77 > "$at_status_file"; exit 77;;
22426    0) ;;
22427    *) echo "$at_srcdir/same-order01.at:29: exit code was $at_status, expected 0"
22428       at_failed=:;;
22429 esac
22430 if $at_failed; then
22431
22432
22433   echo 1 > "$at_status_file"
22434   exit 1
22435 fi
22436
22437 $at_traceon
22438 $at_traceoff
22439 echo "$at_srcdir/same-order01.at:29:
22440 mkdir gnu
22441 (cd gnu
22442 TEST_TAR_FORMAT=gnu
22443 export TEST_TAR_FORMAT
22444 TAR_OPTIONS=\"-H gnu\"
22445 export TAR_OPTIONS
22446 rm -rf *
22447
22448
22449 test -z "`sort < /dev/null 2>&1`" || exit 77
22450
22451
22452 genfile -l 1024 -f file1
22453 genfile -l 1024 -f file2
22454 tar cf archive file1 file2
22455
22456 mkdir directory
22457 tar -xf archive --same-order -C directory || exit 1
22458
22459 ls directory|sort
22460 )"
22461 echo same-order01.at:29 >"$at_check_line_file"
22462
22463 at_trace_this=
22464 if test -n "$at_traceon"; then
22465     echo 'Not enabling shell tracing (command contains an embedded newline)'
22466 fi
22467
22468 if test -n "$at_trace_this"; then
22469     ( $at_traceon;
22470 mkdir gnu
22471 (cd gnu
22472 TEST_TAR_FORMAT=gnu
22473 export TEST_TAR_FORMAT
22474 TAR_OPTIONS="-H gnu"
22475 export TAR_OPTIONS
22476 rm -rf *
22477
22478
22479 test -z "`sort < /dev/null 2>&1`" || exit 77
22480
22481
22482 genfile -l 1024 -f file1
22483 genfile -l 1024 -f file2
22484 tar cf archive file1 file2
22485
22486 mkdir directory
22487 tar -xf archive --same-order -C directory || exit 1
22488
22489 ls directory|sort
22490 ) ) >"$at_stdout" 2>"$at_stder1"
22491     at_status=$?
22492     grep '^ *+' "$at_stder1" >&2
22493     grep -v '^ *+' "$at_stder1" >"$at_stderr"
22494 else
22495     ( :;
22496 mkdir gnu
22497 (cd gnu
22498 TEST_TAR_FORMAT=gnu
22499 export TEST_TAR_FORMAT
22500 TAR_OPTIONS="-H gnu"
22501 export TAR_OPTIONS
22502 rm -rf *
22503
22504
22505 test -z "`sort < /dev/null 2>&1`" || exit 77
22506
22507
22508 genfile -l 1024 -f file1
22509 genfile -l 1024 -f file2
22510 tar cf archive file1 file2
22511
22512 mkdir directory
22513 tar -xf archive --same-order -C directory || exit 1
22514
22515 ls directory|sort
22516 ) ) >"$at_stdout" 2>"$at_stderr"
22517     at_status=$?
22518 fi
22519
22520 at_failed=false
22521 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
22522 echo >>"$at_stdout"; echo "file1
22523 file2
22524 " | $at_diff - "$at_stdout" || at_failed=:
22525 case $at_status in
22526    77) echo 77 > "$at_status_file"; exit 77;;
22527    0) ;;
22528    *) echo "$at_srcdir/same-order01.at:29: exit code was $at_status, expected 0"
22529       at_failed=:;;
22530 esac
22531 if $at_failed; then
22532
22533
22534   echo 1 > "$at_status_file"
22535   exit 1
22536 fi
22537
22538 $at_traceon
22539
22540
22541
22542       $at_traceoff
22543       $at_times_p && times >"$at_times_file"
22544     ) 5>&1 2>&1 | eval $at_tee_pipe
22545     at_status=`cat "$at_status_file"`
22546     ;;
22547
22548   55 ) # 55. same-order02.at:25: multiple -C options
22549     at_setup_line='same-order02.at:25'
22550     at_desc="multiple -C options"
22551     $at_quiet $ECHO_N " 55: multiple -C options                            $ECHO_C"
22552     at_xfail=no
22553       test -f $XFAILFILE && at_xfail=yes
22554     echo "#                             -*- compilation -*-" >> "$at_group_log"
22555     (
22556       echo "55. same-order02.at:25: testing ..."
22557       $at_traceon
22558
22559
22560
22561
22562
22563   $at_traceoff
22564 echo "$at_srcdir/same-order02.at:28:
22565 mkdir v7
22566 (cd v7
22567 TEST_TAR_FORMAT=v7
22568 export TEST_TAR_FORMAT
22569 TAR_OPTIONS=\"-H v7\"
22570 export TAR_OPTIONS
22571 rm -rf *
22572
22573 genfile -l 1024 -f file1
22574 genfile -l 1024 -f file2
22575 tar cf archive file1 file2
22576
22577 mkdir en
22578 mkdir to
22579
22580 HERE=\`pwd\`
22581 tar -xf archive --same-order -C \$HERE/en file1 -C \$HERE/to file2 || exit 1
22582
22583 ls en
22584 echo separator
22585 ls to
22586 )"
22587 echo same-order02.at:28 >"$at_check_line_file"
22588
22589 at_trace_this=
22590 if test -n "$at_traceon"; then
22591     echo 'Not enabling shell tracing (command contains a `...` command substitution)'
22592 fi
22593
22594 if test -n "$at_trace_this"; then
22595     ( $at_traceon;
22596 mkdir v7
22597 (cd v7
22598 TEST_TAR_FORMAT=v7
22599 export TEST_TAR_FORMAT
22600 TAR_OPTIONS="-H v7"
22601 export TAR_OPTIONS
22602 rm -rf *
22603
22604 genfile -l 1024 -f file1
22605 genfile -l 1024 -f file2
22606 tar cf archive file1 file2
22607
22608 mkdir en
22609 mkdir to
22610
22611 HERE=`pwd`
22612 tar -xf archive --same-order -C $HERE/en file1 -C $HERE/to file2 || exit 1
22613
22614 ls en
22615 echo separator
22616 ls to
22617 ) ) >"$at_stdout" 2>"$at_stder1"
22618     at_status=$?
22619     grep '^ *+' "$at_stder1" >&2
22620     grep -v '^ *+' "$at_stder1" >"$at_stderr"
22621 else
22622     ( :;
22623 mkdir v7
22624 (cd v7
22625 TEST_TAR_FORMAT=v7
22626 export TEST_TAR_FORMAT
22627 TAR_OPTIONS="-H v7"
22628 export TAR_OPTIONS
22629 rm -rf *
22630
22631 genfile -l 1024 -f file1
22632 genfile -l 1024 -f file2
22633 tar cf archive file1 file2
22634
22635 mkdir en
22636 mkdir to
22637
22638 HERE=`pwd`
22639 tar -xf archive --same-order -C $HERE/en file1 -C $HERE/to file2 || exit 1
22640
22641 ls en
22642 echo separator
22643 ls to
22644 ) ) >"$at_stdout" 2>"$at_stderr"
22645     at_status=$?
22646 fi
22647
22648 at_failed=false
22649 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
22650 echo >>"$at_stdout"; echo "file1
22651 separator
22652 file2
22653 " | $at_diff - "$at_stdout" || at_failed=:
22654 case $at_status in
22655    77) echo 77 > "$at_status_file"; exit 77;;
22656    0) ;;
22657    *) echo "$at_srcdir/same-order02.at:28: exit code was $at_status, expected 0"
22658       at_failed=:;;
22659 esac
22660 if $at_failed; then
22661
22662
22663   echo 1 > "$at_status_file"
22664   exit 1
22665 fi
22666
22667 $at_traceon
22668 $at_traceoff
22669 echo "$at_srcdir/same-order02.at:28:
22670 mkdir oldgnu
22671 (cd oldgnu
22672 TEST_TAR_FORMAT=oldgnu
22673 export TEST_TAR_FORMAT
22674 TAR_OPTIONS=\"-H oldgnu\"
22675 export TAR_OPTIONS
22676 rm -rf *
22677
22678 genfile -l 1024 -f file1
22679 genfile -l 1024 -f file2
22680 tar cf archive file1 file2
22681
22682 mkdir en
22683 mkdir to
22684
22685 HERE=\`pwd\`
22686 tar -xf archive --same-order -C \$HERE/en file1 -C \$HERE/to file2 || exit 1
22687
22688 ls en
22689 echo separator
22690 ls to
22691 )"
22692 echo same-order02.at:28 >"$at_check_line_file"
22693
22694 at_trace_this=
22695 if test -n "$at_traceon"; then
22696     echo 'Not enabling shell tracing (command contains a `...` command substitution)'
22697 fi
22698
22699 if test -n "$at_trace_this"; then
22700     ( $at_traceon;
22701 mkdir oldgnu
22702 (cd oldgnu
22703 TEST_TAR_FORMAT=oldgnu
22704 export TEST_TAR_FORMAT
22705 TAR_OPTIONS="-H oldgnu"
22706 export TAR_OPTIONS
22707 rm -rf *
22708
22709 genfile -l 1024 -f file1
22710 genfile -l 1024 -f file2
22711 tar cf archive file1 file2
22712
22713 mkdir en
22714 mkdir to
22715
22716 HERE=`pwd`
22717 tar -xf archive --same-order -C $HERE/en file1 -C $HERE/to file2 || exit 1
22718
22719 ls en
22720 echo separator
22721 ls to
22722 ) ) >"$at_stdout" 2>"$at_stder1"
22723     at_status=$?
22724     grep '^ *+' "$at_stder1" >&2
22725     grep -v '^ *+' "$at_stder1" >"$at_stderr"
22726 else
22727     ( :;
22728 mkdir oldgnu
22729 (cd oldgnu
22730 TEST_TAR_FORMAT=oldgnu
22731 export TEST_TAR_FORMAT
22732 TAR_OPTIONS="-H oldgnu"
22733 export TAR_OPTIONS
22734 rm -rf *
22735
22736 genfile -l 1024 -f file1
22737 genfile -l 1024 -f file2
22738 tar cf archive file1 file2
22739
22740 mkdir en
22741 mkdir to
22742
22743 HERE=`pwd`
22744 tar -xf archive --same-order -C $HERE/en file1 -C $HERE/to file2 || exit 1
22745
22746 ls en
22747 echo separator
22748 ls to
22749 ) ) >"$at_stdout" 2>"$at_stderr"
22750     at_status=$?
22751 fi
22752
22753 at_failed=false
22754 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
22755 echo >>"$at_stdout"; echo "file1
22756 separator
22757 file2
22758 " | $at_diff - "$at_stdout" || at_failed=:
22759 case $at_status in
22760    77) echo 77 > "$at_status_file"; exit 77;;
22761    0) ;;
22762    *) echo "$at_srcdir/same-order02.at:28: exit code was $at_status, expected 0"
22763       at_failed=:;;
22764 esac
22765 if $at_failed; then
22766
22767
22768   echo 1 > "$at_status_file"
22769   exit 1
22770 fi
22771
22772 $at_traceon
22773 $at_traceoff
22774 echo "$at_srcdir/same-order02.at:28:
22775 mkdir ustar
22776 (cd ustar
22777 TEST_TAR_FORMAT=ustar
22778 export TEST_TAR_FORMAT
22779 TAR_OPTIONS=\"-H ustar\"
22780 export TAR_OPTIONS
22781 rm -rf *
22782
22783 genfile -l 1024 -f file1
22784 genfile -l 1024 -f file2
22785 tar cf archive file1 file2
22786
22787 mkdir en
22788 mkdir to
22789
22790 HERE=\`pwd\`
22791 tar -xf archive --same-order -C \$HERE/en file1 -C \$HERE/to file2 || exit 1
22792
22793 ls en
22794 echo separator
22795 ls to
22796 )"
22797 echo same-order02.at:28 >"$at_check_line_file"
22798
22799 at_trace_this=
22800 if test -n "$at_traceon"; then
22801     echo 'Not enabling shell tracing (command contains a `...` command substitution)'
22802 fi
22803
22804 if test -n "$at_trace_this"; then
22805     ( $at_traceon;
22806 mkdir ustar
22807 (cd ustar
22808 TEST_TAR_FORMAT=ustar
22809 export TEST_TAR_FORMAT
22810 TAR_OPTIONS="-H ustar"
22811 export TAR_OPTIONS
22812 rm -rf *
22813
22814 genfile -l 1024 -f file1
22815 genfile -l 1024 -f file2
22816 tar cf archive file1 file2
22817
22818 mkdir en
22819 mkdir to
22820
22821 HERE=`pwd`
22822 tar -xf archive --same-order -C $HERE/en file1 -C $HERE/to file2 || exit 1
22823
22824 ls en
22825 echo separator
22826 ls to
22827 ) ) >"$at_stdout" 2>"$at_stder1"
22828     at_status=$?
22829     grep '^ *+' "$at_stder1" >&2
22830     grep -v '^ *+' "$at_stder1" >"$at_stderr"
22831 else
22832     ( :;
22833 mkdir ustar
22834 (cd ustar
22835 TEST_TAR_FORMAT=ustar
22836 export TEST_TAR_FORMAT
22837 TAR_OPTIONS="-H ustar"
22838 export TAR_OPTIONS
22839 rm -rf *
22840
22841 genfile -l 1024 -f file1
22842 genfile -l 1024 -f file2
22843 tar cf archive file1 file2
22844
22845 mkdir en
22846 mkdir to
22847
22848 HERE=`pwd`
22849 tar -xf archive --same-order -C $HERE/en file1 -C $HERE/to file2 || exit 1
22850
22851 ls en
22852 echo separator
22853 ls to
22854 ) ) >"$at_stdout" 2>"$at_stderr"
22855     at_status=$?
22856 fi
22857
22858 at_failed=false
22859 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
22860 echo >>"$at_stdout"; echo "file1
22861 separator
22862 file2
22863 " | $at_diff - "$at_stdout" || at_failed=:
22864 case $at_status in
22865    77) echo 77 > "$at_status_file"; exit 77;;
22866    0) ;;
22867    *) echo "$at_srcdir/same-order02.at:28: exit code was $at_status, expected 0"
22868       at_failed=:;;
22869 esac
22870 if $at_failed; then
22871
22872
22873   echo 1 > "$at_status_file"
22874   exit 1
22875 fi
22876
22877 $at_traceon
22878 $at_traceoff
22879 echo "$at_srcdir/same-order02.at:28:
22880 mkdir posix
22881 (cd posix
22882 TEST_TAR_FORMAT=posix
22883 export TEST_TAR_FORMAT
22884 TAR_OPTIONS=\"-H posix\"
22885 export TAR_OPTIONS
22886 rm -rf *
22887
22888 genfile -l 1024 -f file1
22889 genfile -l 1024 -f file2
22890 tar cf archive file1 file2
22891
22892 mkdir en
22893 mkdir to
22894
22895 HERE=\`pwd\`
22896 tar -xf archive --same-order -C \$HERE/en file1 -C \$HERE/to file2 || exit 1
22897
22898 ls en
22899 echo separator
22900 ls to
22901 )"
22902 echo same-order02.at:28 >"$at_check_line_file"
22903
22904 at_trace_this=
22905 if test -n "$at_traceon"; then
22906     echo 'Not enabling shell tracing (command contains a `...` command substitution)'
22907 fi
22908
22909 if test -n "$at_trace_this"; then
22910     ( $at_traceon;
22911 mkdir posix
22912 (cd posix
22913 TEST_TAR_FORMAT=posix
22914 export TEST_TAR_FORMAT
22915 TAR_OPTIONS="-H posix"
22916 export TAR_OPTIONS
22917 rm -rf *
22918
22919 genfile -l 1024 -f file1
22920 genfile -l 1024 -f file2
22921 tar cf archive file1 file2
22922
22923 mkdir en
22924 mkdir to
22925
22926 HERE=`pwd`
22927 tar -xf archive --same-order -C $HERE/en file1 -C $HERE/to file2 || exit 1
22928
22929 ls en
22930 echo separator
22931 ls to
22932 ) ) >"$at_stdout" 2>"$at_stder1"
22933     at_status=$?
22934     grep '^ *+' "$at_stder1" >&2
22935     grep -v '^ *+' "$at_stder1" >"$at_stderr"
22936 else
22937     ( :;
22938 mkdir posix
22939 (cd posix
22940 TEST_TAR_FORMAT=posix
22941 export TEST_TAR_FORMAT
22942 TAR_OPTIONS="-H posix"
22943 export TAR_OPTIONS
22944 rm -rf *
22945
22946 genfile -l 1024 -f file1
22947 genfile -l 1024 -f file2
22948 tar cf archive file1 file2
22949
22950 mkdir en
22951 mkdir to
22952
22953 HERE=`pwd`
22954 tar -xf archive --same-order -C $HERE/en file1 -C $HERE/to file2 || exit 1
22955
22956 ls en
22957 echo separator
22958 ls to
22959 ) ) >"$at_stdout" 2>"$at_stderr"
22960     at_status=$?
22961 fi
22962
22963 at_failed=false
22964 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
22965 echo >>"$at_stdout"; echo "file1
22966 separator
22967 file2
22968 " | $at_diff - "$at_stdout" || at_failed=:
22969 case $at_status in
22970    77) echo 77 > "$at_status_file"; exit 77;;
22971    0) ;;
22972    *) echo "$at_srcdir/same-order02.at:28: exit code was $at_status, expected 0"
22973       at_failed=:;;
22974 esac
22975 if $at_failed; then
22976
22977
22978   echo 1 > "$at_status_file"
22979   exit 1
22980 fi
22981
22982 $at_traceon
22983 $at_traceoff
22984 echo "$at_srcdir/same-order02.at:28:
22985 mkdir gnu
22986 (cd gnu
22987 TEST_TAR_FORMAT=gnu
22988 export TEST_TAR_FORMAT
22989 TAR_OPTIONS=\"-H gnu\"
22990 export TAR_OPTIONS
22991 rm -rf *
22992
22993 genfile -l 1024 -f file1
22994 genfile -l 1024 -f file2
22995 tar cf archive file1 file2
22996
22997 mkdir en
22998 mkdir to
22999
23000 HERE=\`pwd\`
23001 tar -xf archive --same-order -C \$HERE/en file1 -C \$HERE/to file2 || exit 1
23002
23003 ls en
23004 echo separator
23005 ls to
23006 )"
23007 echo same-order02.at:28 >"$at_check_line_file"
23008
23009 at_trace_this=
23010 if test -n "$at_traceon"; then
23011     echo 'Not enabling shell tracing (command contains a `...` command substitution)'
23012 fi
23013
23014 if test -n "$at_trace_this"; then
23015     ( $at_traceon;
23016 mkdir gnu
23017 (cd gnu
23018 TEST_TAR_FORMAT=gnu
23019 export TEST_TAR_FORMAT
23020 TAR_OPTIONS="-H gnu"
23021 export TAR_OPTIONS
23022 rm -rf *
23023
23024 genfile -l 1024 -f file1
23025 genfile -l 1024 -f file2
23026 tar cf archive file1 file2
23027
23028 mkdir en
23029 mkdir to
23030
23031 HERE=`pwd`
23032 tar -xf archive --same-order -C $HERE/en file1 -C $HERE/to file2 || exit 1
23033
23034 ls en
23035 echo separator
23036 ls to
23037 ) ) >"$at_stdout" 2>"$at_stder1"
23038     at_status=$?
23039     grep '^ *+' "$at_stder1" >&2
23040     grep -v '^ *+' "$at_stder1" >"$at_stderr"
23041 else
23042     ( :;
23043 mkdir gnu
23044 (cd gnu
23045 TEST_TAR_FORMAT=gnu
23046 export TEST_TAR_FORMAT
23047 TAR_OPTIONS="-H gnu"
23048 export TAR_OPTIONS
23049 rm -rf *
23050
23051 genfile -l 1024 -f file1
23052 genfile -l 1024 -f file2
23053 tar cf archive file1 file2
23054
23055 mkdir en
23056 mkdir to
23057
23058 HERE=`pwd`
23059 tar -xf archive --same-order -C $HERE/en file1 -C $HERE/to file2 || exit 1
23060
23061 ls en
23062 echo separator
23063 ls to
23064 ) ) >"$at_stdout" 2>"$at_stderr"
23065     at_status=$?
23066 fi
23067
23068 at_failed=false
23069 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
23070 echo >>"$at_stdout"; echo "file1
23071 separator
23072 file2
23073 " | $at_diff - "$at_stdout" || at_failed=:
23074 case $at_status in
23075    77) echo 77 > "$at_status_file"; exit 77;;
23076    0) ;;
23077    *) echo "$at_srcdir/same-order02.at:28: exit code was $at_status, expected 0"
23078       at_failed=:;;
23079 esac
23080 if $at_failed; then
23081
23082
23083   echo 1 > "$at_status_file"
23084   exit 1
23085 fi
23086
23087 $at_traceon
23088
23089
23090
23091       $at_traceoff
23092       $at_times_p && times >"$at_times_file"
23093     ) 5>&1 2>&1 | eval $at_tee_pipe
23094     at_status=`cat "$at_status_file"`
23095     ;;
23096
23097   56 ) # 56. shortrec.at:25: short records
23098     at_setup_line='shortrec.at:25'
23099     at_desc="short records"
23100     $at_quiet $ECHO_N " 56: short records                                  $ECHO_C"
23101     at_xfail=no
23102       test -f $XFAILFILE && at_xfail=yes
23103     echo "#                             -*- compilation -*-" >> "$at_group_log"
23104     (
23105       echo "56. shortrec.at:25: testing ..."
23106       $at_traceon
23107
23108
23109
23110
23111
23112   $at_traceoff
23113 echo "$at_srcdir/shortrec.at:28:
23114 mkdir v7
23115 (cd v7
23116 TEST_TAR_FORMAT=v7
23117 export TEST_TAR_FORMAT
23118 TAR_OPTIONS=\"-H v7\"
23119 export TAR_OPTIONS
23120 rm -rf *
23121
23122 mkdir directory
23123 (cd directory && touch a b c d e f g h i j k l m n o p q r)
23124 tar -c -b 1 -f - directory | tar -t -f - >/dev/null
23125 tar -c -b 1 -f archive directory
23126 tar -t -f archive >/dev/null
23127 tar -t -f - < archive >/dev/null
23128
23129 rm -r directory
23130 )"
23131 echo shortrec.at:28 >"$at_check_line_file"
23132
23133 at_trace_this=
23134 if test -n "$at_traceon"; then
23135     echo 'Not enabling shell tracing (command contains an embedded newline)'
23136 fi
23137
23138 if test -n "$at_trace_this"; then
23139     ( $at_traceon;
23140 mkdir v7
23141 (cd v7
23142 TEST_TAR_FORMAT=v7
23143 export TEST_TAR_FORMAT
23144 TAR_OPTIONS="-H v7"
23145 export TAR_OPTIONS
23146 rm -rf *
23147
23148 mkdir directory
23149 (cd directory && touch a b c d e f g h i j k l m n o p q r)
23150 tar -c -b 1 -f - directory | tar -t -f - >/dev/null
23151 tar -c -b 1 -f archive directory
23152 tar -t -f archive >/dev/null
23153 tar -t -f - < archive >/dev/null
23154
23155 rm -r directory
23156 ) ) >"$at_stdout" 2>"$at_stder1"
23157     at_status=$?
23158     grep '^ *+' "$at_stder1" >&2
23159     grep -v '^ *+' "$at_stder1" >"$at_stderr"
23160 else
23161     ( :;
23162 mkdir v7
23163 (cd v7
23164 TEST_TAR_FORMAT=v7
23165 export TEST_TAR_FORMAT
23166 TAR_OPTIONS="-H v7"
23167 export TAR_OPTIONS
23168 rm -rf *
23169
23170 mkdir directory
23171 (cd directory && touch a b c d e f g h i j k l m n o p q r)
23172 tar -c -b 1 -f - directory | tar -t -f - >/dev/null
23173 tar -c -b 1 -f archive directory
23174 tar -t -f archive >/dev/null
23175 tar -t -f - < archive >/dev/null
23176
23177 rm -r directory
23178 ) ) >"$at_stdout" 2>"$at_stderr"
23179     at_status=$?
23180 fi
23181
23182 at_failed=false
23183 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
23184 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
23185 case $at_status in
23186    77) echo 77 > "$at_status_file"; exit 77;;
23187    0) ;;
23188    *) echo "$at_srcdir/shortrec.at:28: exit code was $at_status, expected 0"
23189       at_failed=:;;
23190 esac
23191 if $at_failed; then
23192
23193
23194   echo 1 > "$at_status_file"
23195   exit 1
23196 fi
23197
23198 $at_traceon
23199 $at_traceoff
23200 echo "$at_srcdir/shortrec.at:28:
23201 mkdir oldgnu
23202 (cd oldgnu
23203 TEST_TAR_FORMAT=oldgnu
23204 export TEST_TAR_FORMAT
23205 TAR_OPTIONS=\"-H oldgnu\"
23206 export TAR_OPTIONS
23207 rm -rf *
23208
23209 mkdir directory
23210 (cd directory && touch a b c d e f g h i j k l m n o p q r)
23211 tar -c -b 1 -f - directory | tar -t -f - >/dev/null
23212 tar -c -b 1 -f archive directory
23213 tar -t -f archive >/dev/null
23214 tar -t -f - < archive >/dev/null
23215
23216 rm -r directory
23217 )"
23218 echo shortrec.at:28 >"$at_check_line_file"
23219
23220 at_trace_this=
23221 if test -n "$at_traceon"; then
23222     echo 'Not enabling shell tracing (command contains an embedded newline)'
23223 fi
23224
23225 if test -n "$at_trace_this"; then
23226     ( $at_traceon;
23227 mkdir oldgnu
23228 (cd oldgnu
23229 TEST_TAR_FORMAT=oldgnu
23230 export TEST_TAR_FORMAT
23231 TAR_OPTIONS="-H oldgnu"
23232 export TAR_OPTIONS
23233 rm -rf *
23234
23235 mkdir directory
23236 (cd directory && touch a b c d e f g h i j k l m n o p q r)
23237 tar -c -b 1 -f - directory | tar -t -f - >/dev/null
23238 tar -c -b 1 -f archive directory
23239 tar -t -f archive >/dev/null
23240 tar -t -f - < archive >/dev/null
23241
23242 rm -r directory
23243 ) ) >"$at_stdout" 2>"$at_stder1"
23244     at_status=$?
23245     grep '^ *+' "$at_stder1" >&2
23246     grep -v '^ *+' "$at_stder1" >"$at_stderr"
23247 else
23248     ( :;
23249 mkdir oldgnu
23250 (cd oldgnu
23251 TEST_TAR_FORMAT=oldgnu
23252 export TEST_TAR_FORMAT
23253 TAR_OPTIONS="-H oldgnu"
23254 export TAR_OPTIONS
23255 rm -rf *
23256
23257 mkdir directory
23258 (cd directory && touch a b c d e f g h i j k l m n o p q r)
23259 tar -c -b 1 -f - directory | tar -t -f - >/dev/null
23260 tar -c -b 1 -f archive directory
23261 tar -t -f archive >/dev/null
23262 tar -t -f - < archive >/dev/null
23263
23264 rm -r directory
23265 ) ) >"$at_stdout" 2>"$at_stderr"
23266     at_status=$?
23267 fi
23268
23269 at_failed=false
23270 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
23271 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
23272 case $at_status in
23273    77) echo 77 > "$at_status_file"; exit 77;;
23274    0) ;;
23275    *) echo "$at_srcdir/shortrec.at:28: exit code was $at_status, expected 0"
23276       at_failed=:;;
23277 esac
23278 if $at_failed; then
23279
23280
23281   echo 1 > "$at_status_file"
23282   exit 1
23283 fi
23284
23285 $at_traceon
23286 $at_traceoff
23287 echo "$at_srcdir/shortrec.at:28:
23288 mkdir ustar
23289 (cd ustar
23290 TEST_TAR_FORMAT=ustar
23291 export TEST_TAR_FORMAT
23292 TAR_OPTIONS=\"-H ustar\"
23293 export TAR_OPTIONS
23294 rm -rf *
23295
23296 mkdir directory
23297 (cd directory && touch a b c d e f g h i j k l m n o p q r)
23298 tar -c -b 1 -f - directory | tar -t -f - >/dev/null
23299 tar -c -b 1 -f archive directory
23300 tar -t -f archive >/dev/null
23301 tar -t -f - < archive >/dev/null
23302
23303 rm -r directory
23304 )"
23305 echo shortrec.at:28 >"$at_check_line_file"
23306
23307 at_trace_this=
23308 if test -n "$at_traceon"; then
23309     echo 'Not enabling shell tracing (command contains an embedded newline)'
23310 fi
23311
23312 if test -n "$at_trace_this"; then
23313     ( $at_traceon;
23314 mkdir ustar
23315 (cd ustar
23316 TEST_TAR_FORMAT=ustar
23317 export TEST_TAR_FORMAT
23318 TAR_OPTIONS="-H ustar"
23319 export TAR_OPTIONS
23320 rm -rf *
23321
23322 mkdir directory
23323 (cd directory && touch a b c d e f g h i j k l m n o p q r)
23324 tar -c -b 1 -f - directory | tar -t -f - >/dev/null
23325 tar -c -b 1 -f archive directory
23326 tar -t -f archive >/dev/null
23327 tar -t -f - < archive >/dev/null
23328
23329 rm -r directory
23330 ) ) >"$at_stdout" 2>"$at_stder1"
23331     at_status=$?
23332     grep '^ *+' "$at_stder1" >&2
23333     grep -v '^ *+' "$at_stder1" >"$at_stderr"
23334 else
23335     ( :;
23336 mkdir ustar
23337 (cd ustar
23338 TEST_TAR_FORMAT=ustar
23339 export TEST_TAR_FORMAT
23340 TAR_OPTIONS="-H ustar"
23341 export TAR_OPTIONS
23342 rm -rf *
23343
23344 mkdir directory
23345 (cd directory && touch a b c d e f g h i j k l m n o p q r)
23346 tar -c -b 1 -f - directory | tar -t -f - >/dev/null
23347 tar -c -b 1 -f archive directory
23348 tar -t -f archive >/dev/null
23349 tar -t -f - < archive >/dev/null
23350
23351 rm -r directory
23352 ) ) >"$at_stdout" 2>"$at_stderr"
23353     at_status=$?
23354 fi
23355
23356 at_failed=false
23357 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
23358 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
23359 case $at_status in
23360    77) echo 77 > "$at_status_file"; exit 77;;
23361    0) ;;
23362    *) echo "$at_srcdir/shortrec.at:28: exit code was $at_status, expected 0"
23363       at_failed=:;;
23364 esac
23365 if $at_failed; then
23366
23367
23368   echo 1 > "$at_status_file"
23369   exit 1
23370 fi
23371
23372 $at_traceon
23373 $at_traceoff
23374 echo "$at_srcdir/shortrec.at:28:
23375 mkdir posix
23376 (cd posix
23377 TEST_TAR_FORMAT=posix
23378 export TEST_TAR_FORMAT
23379 TAR_OPTIONS=\"-H posix\"
23380 export TAR_OPTIONS
23381 rm -rf *
23382
23383 mkdir directory
23384 (cd directory && touch a b c d e f g h i j k l m n o p q r)
23385 tar -c -b 1 -f - directory | tar -t -f - >/dev/null
23386 tar -c -b 1 -f archive directory
23387 tar -t -f archive >/dev/null
23388 tar -t -f - < archive >/dev/null
23389
23390 rm -r directory
23391 )"
23392 echo shortrec.at:28 >"$at_check_line_file"
23393
23394 at_trace_this=
23395 if test -n "$at_traceon"; then
23396     echo 'Not enabling shell tracing (command contains an embedded newline)'
23397 fi
23398
23399 if test -n "$at_trace_this"; then
23400     ( $at_traceon;
23401 mkdir posix
23402 (cd posix
23403 TEST_TAR_FORMAT=posix
23404 export TEST_TAR_FORMAT
23405 TAR_OPTIONS="-H posix"
23406 export TAR_OPTIONS
23407 rm -rf *
23408
23409 mkdir directory
23410 (cd directory && touch a b c d e f g h i j k l m n o p q r)
23411 tar -c -b 1 -f - directory | tar -t -f - >/dev/null
23412 tar -c -b 1 -f archive directory
23413 tar -t -f archive >/dev/null
23414 tar -t -f - < archive >/dev/null
23415
23416 rm -r directory
23417 ) ) >"$at_stdout" 2>"$at_stder1"
23418     at_status=$?
23419     grep '^ *+' "$at_stder1" >&2
23420     grep -v '^ *+' "$at_stder1" >"$at_stderr"
23421 else
23422     ( :;
23423 mkdir posix
23424 (cd posix
23425 TEST_TAR_FORMAT=posix
23426 export TEST_TAR_FORMAT
23427 TAR_OPTIONS="-H posix"
23428 export TAR_OPTIONS
23429 rm -rf *
23430
23431 mkdir directory
23432 (cd directory && touch a b c d e f g h i j k l m n o p q r)
23433 tar -c -b 1 -f - directory | tar -t -f - >/dev/null
23434 tar -c -b 1 -f archive directory
23435 tar -t -f archive >/dev/null
23436 tar -t -f - < archive >/dev/null
23437
23438 rm -r directory
23439 ) ) >"$at_stdout" 2>"$at_stderr"
23440     at_status=$?
23441 fi
23442
23443 at_failed=false
23444 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
23445 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
23446 case $at_status in
23447    77) echo 77 > "$at_status_file"; exit 77;;
23448    0) ;;
23449    *) echo "$at_srcdir/shortrec.at:28: exit code was $at_status, expected 0"
23450       at_failed=:;;
23451 esac
23452 if $at_failed; then
23453
23454
23455   echo 1 > "$at_status_file"
23456   exit 1
23457 fi
23458
23459 $at_traceon
23460 $at_traceoff
23461 echo "$at_srcdir/shortrec.at:28:
23462 mkdir gnu
23463 (cd gnu
23464 TEST_TAR_FORMAT=gnu
23465 export TEST_TAR_FORMAT
23466 TAR_OPTIONS=\"-H gnu\"
23467 export TAR_OPTIONS
23468 rm -rf *
23469
23470 mkdir directory
23471 (cd directory && touch a b c d e f g h i j k l m n o p q r)
23472 tar -c -b 1 -f - directory | tar -t -f - >/dev/null
23473 tar -c -b 1 -f archive directory
23474 tar -t -f archive >/dev/null
23475 tar -t -f - < archive >/dev/null
23476
23477 rm -r directory
23478 )"
23479 echo shortrec.at:28 >"$at_check_line_file"
23480
23481 at_trace_this=
23482 if test -n "$at_traceon"; then
23483     echo 'Not enabling shell tracing (command contains an embedded newline)'
23484 fi
23485
23486 if test -n "$at_trace_this"; then
23487     ( $at_traceon;
23488 mkdir gnu
23489 (cd gnu
23490 TEST_TAR_FORMAT=gnu
23491 export TEST_TAR_FORMAT
23492 TAR_OPTIONS="-H gnu"
23493 export TAR_OPTIONS
23494 rm -rf *
23495
23496 mkdir directory
23497 (cd directory && touch a b c d e f g h i j k l m n o p q r)
23498 tar -c -b 1 -f - directory | tar -t -f - >/dev/null
23499 tar -c -b 1 -f archive directory
23500 tar -t -f archive >/dev/null
23501 tar -t -f - < archive >/dev/null
23502
23503 rm -r directory
23504 ) ) >"$at_stdout" 2>"$at_stder1"
23505     at_status=$?
23506     grep '^ *+' "$at_stder1" >&2
23507     grep -v '^ *+' "$at_stder1" >"$at_stderr"
23508 else
23509     ( :;
23510 mkdir gnu
23511 (cd gnu
23512 TEST_TAR_FORMAT=gnu
23513 export TEST_TAR_FORMAT
23514 TAR_OPTIONS="-H gnu"
23515 export TAR_OPTIONS
23516 rm -rf *
23517
23518 mkdir directory
23519 (cd directory && touch a b c d e f g h i j k l m n o p q r)
23520 tar -c -b 1 -f - directory | tar -t -f - >/dev/null
23521 tar -c -b 1 -f archive directory
23522 tar -t -f archive >/dev/null
23523 tar -t -f - < archive >/dev/null
23524
23525 rm -r directory
23526 ) ) >"$at_stdout" 2>"$at_stderr"
23527     at_status=$?
23528 fi
23529
23530 at_failed=false
23531 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
23532 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
23533 case $at_status in
23534    77) echo 77 > "$at_status_file"; exit 77;;
23535    0) ;;
23536    *) echo "$at_srcdir/shortrec.at:28: exit code was $at_status, expected 0"
23537       at_failed=:;;
23538 esac
23539 if $at_failed; then
23540
23541
23542   echo 1 > "$at_status_file"
23543   exit 1
23544 fi
23545
23546 $at_traceon
23547
23548
23549
23550       $at_traceoff
23551       $at_times_p && times >"$at_times_file"
23552     ) 5>&1 2>&1 | eval $at_tee_pipe
23553     at_status=`cat "$at_status_file"`
23554     ;;
23555
23556   57 ) # 57. sparse01.at:21: sparse files
23557     at_setup_line='sparse01.at:21'
23558     at_desc="sparse files"
23559     $at_quiet $ECHO_N " 57: sparse files                                   $ECHO_C"
23560     at_xfail=no
23561       test -f $XFAILFILE && at_xfail=yes
23562     echo "#                             -*- compilation -*-" >> "$at_group_log"
23563     (
23564       echo "57. sparse01.at:21: testing ..."
23565       $at_traceon
23566
23567
23568
23569
23570
23571   $at_traceoff
23572 echo "$at_srcdir/sparse01.at:24:
23573 mkdir posix
23574 (cd posix
23575 TEST_TAR_FORMAT=posix
23576 export TEST_TAR_FORMAT
23577 TAR_OPTIONS=\"-H posix\"
23578 export TAR_OPTIONS
23579 rm -rf *
23580
23581 genfile --length 1000 -f begin
23582 genfile --length 1000 -f end
23583 genfile --sparse --file sparsefile --block-size 512 0 ABCD 1M EFGH 2000K IJKL || exit 77
23584 tar -c -f archive --sparse begin sparsefile end || exit 1
23585 echo separator
23586
23587 tar tfv archive
23588 echo separator
23589 mkdir directory
23590 tar Cxf directory archive
23591 genfile --stat=name,size sparsefile
23592 cmp sparsefile directory/sparsefile
23593 )"
23594 echo sparse01.at:24 >"$at_check_line_file"
23595
23596 at_trace_this=
23597 if test -n "$at_traceon"; then
23598     echo 'Not enabling shell tracing (command contains an embedded newline)'
23599 fi
23600
23601 if test -n "$at_trace_this"; then
23602     ( $at_traceon;
23603 mkdir posix
23604 (cd posix
23605 TEST_TAR_FORMAT=posix
23606 export TEST_TAR_FORMAT
23607 TAR_OPTIONS="-H posix"
23608 export TAR_OPTIONS
23609 rm -rf *
23610
23611 genfile --length 1000 -f begin
23612 genfile --length 1000 -f end
23613 genfile --sparse --file sparsefile --block-size 512 0 ABCD 1M EFGH 2000K IJKL || exit 77
23614 tar -c -f archive --sparse begin sparsefile end || exit 1
23615 echo separator
23616
23617 tar tfv archive
23618 echo separator
23619 mkdir directory
23620 tar Cxf directory archive
23621 genfile --stat=name,size sparsefile
23622 cmp sparsefile directory/sparsefile
23623 ) ) >"$at_stdout" 2>"$at_stder1"
23624     at_status=$?
23625     grep '^ *+' "$at_stder1" >&2
23626     grep -v '^ *+' "$at_stder1" >"$at_stderr"
23627 else
23628     ( :;
23629 mkdir posix
23630 (cd posix
23631 TEST_TAR_FORMAT=posix
23632 export TEST_TAR_FORMAT
23633 TAR_OPTIONS="-H posix"
23634 export TAR_OPTIONS
23635 rm -rf *
23636
23637 genfile --length 1000 -f begin
23638 genfile --length 1000 -f end
23639 genfile --sparse --file sparsefile --block-size 512 0 ABCD 1M EFGH 2000K IJKL || exit 77
23640 tar -c -f archive --sparse begin sparsefile end || exit 1
23641 echo separator
23642
23643 tar tfv archive
23644 echo separator
23645 mkdir directory
23646 tar Cxf directory archive
23647 genfile --stat=name,size sparsefile
23648 cmp sparsefile directory/sparsefile
23649 ) ) >"$at_stdout" 2>"$at_stderr"
23650     at_status=$?
23651 fi
23652
23653 at_failed=false
23654 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
23655 echo stdout:; tee stdout <"$at_stdout"
23656 case $at_status in
23657    77) echo 77 > "$at_status_file"; exit 77;;
23658    0) ;;
23659    *) echo "$at_srcdir/sparse01.at:24: exit code was $at_status, expected 0"
23660       at_failed=:;;
23661 esac
23662 if $at_failed; then
23663
23664
23665   echo 1 > "$at_status_file"
23666   exit 1
23667 fi
23668
23669 $at_traceon
23670 $at_traceoff
23671 echo "$at_srcdir/sparse01.at:24:
23672 mkdir gnu
23673 (cd gnu
23674 TEST_TAR_FORMAT=gnu
23675 export TEST_TAR_FORMAT
23676 TAR_OPTIONS=\"-H gnu\"
23677 export TAR_OPTIONS
23678 rm -rf *
23679
23680 genfile --length 1000 -f begin
23681 genfile --length 1000 -f end
23682 genfile --sparse --file sparsefile --block-size 512 0 ABCD 1M EFGH 2000K IJKL || exit 77
23683 tar -c -f archive --sparse begin sparsefile end || exit 1
23684 echo separator
23685
23686 tar tfv archive
23687 echo separator
23688 mkdir directory
23689 tar Cxf directory archive
23690 genfile --stat=name,size sparsefile
23691 cmp sparsefile directory/sparsefile
23692 )"
23693 echo sparse01.at:24 >"$at_check_line_file"
23694
23695 at_trace_this=
23696 if test -n "$at_traceon"; then
23697     echo 'Not enabling shell tracing (command contains an embedded newline)'
23698 fi
23699
23700 if test -n "$at_trace_this"; then
23701     ( $at_traceon;
23702 mkdir gnu
23703 (cd gnu
23704 TEST_TAR_FORMAT=gnu
23705 export TEST_TAR_FORMAT
23706 TAR_OPTIONS="-H gnu"
23707 export TAR_OPTIONS
23708 rm -rf *
23709
23710 genfile --length 1000 -f begin
23711 genfile --length 1000 -f end
23712 genfile --sparse --file sparsefile --block-size 512 0 ABCD 1M EFGH 2000K IJKL || exit 77
23713 tar -c -f archive --sparse begin sparsefile end || exit 1
23714 echo separator
23715
23716 tar tfv archive
23717 echo separator
23718 mkdir directory
23719 tar Cxf directory archive
23720 genfile --stat=name,size sparsefile
23721 cmp sparsefile directory/sparsefile
23722 ) ) >"$at_stdout" 2>"$at_stder1"
23723     at_status=$?
23724     grep '^ *+' "$at_stder1" >&2
23725     grep -v '^ *+' "$at_stder1" >"$at_stderr"
23726 else
23727     ( :;
23728 mkdir gnu
23729 (cd gnu
23730 TEST_TAR_FORMAT=gnu
23731 export TEST_TAR_FORMAT
23732 TAR_OPTIONS="-H gnu"
23733 export TAR_OPTIONS
23734 rm -rf *
23735
23736 genfile --length 1000 -f begin
23737 genfile --length 1000 -f end
23738 genfile --sparse --file sparsefile --block-size 512 0 ABCD 1M EFGH 2000K IJKL || exit 77
23739 tar -c -f archive --sparse begin sparsefile end || exit 1
23740 echo separator
23741
23742 tar tfv archive
23743 echo separator
23744 mkdir directory
23745 tar Cxf directory archive
23746 genfile --stat=name,size sparsefile
23747 cmp sparsefile directory/sparsefile
23748 ) ) >"$at_stdout" 2>"$at_stderr"
23749     at_status=$?
23750 fi
23751
23752 at_failed=false
23753 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
23754 echo stdout:; tee stdout <"$at_stdout"
23755 case $at_status in
23756    77) echo 77 > "$at_status_file"; exit 77;;
23757    0) ;;
23758    *) echo "$at_srcdir/sparse01.at:24: exit code was $at_status, expected 0"
23759       at_failed=:;;
23760 esac
23761 if $at_failed; then
23762
23763
23764   echo 1 > "$at_status_file"
23765   exit 1
23766 fi
23767
23768 $at_traceon
23769 $at_traceoff
23770 echo "$at_srcdir/sparse01.at:24:
23771 mkdir oldgnu
23772 (cd oldgnu
23773 TEST_TAR_FORMAT=oldgnu
23774 export TEST_TAR_FORMAT
23775 TAR_OPTIONS=\"-H oldgnu\"
23776 export TAR_OPTIONS
23777 rm -rf *
23778
23779 genfile --length 1000 -f begin
23780 genfile --length 1000 -f end
23781 genfile --sparse --file sparsefile --block-size 512 0 ABCD 1M EFGH 2000K IJKL || exit 77
23782 tar -c -f archive --sparse begin sparsefile end || exit 1
23783 echo separator
23784
23785 tar tfv archive
23786 echo separator
23787 mkdir directory
23788 tar Cxf directory archive
23789 genfile --stat=name,size sparsefile
23790 cmp sparsefile directory/sparsefile
23791 )"
23792 echo sparse01.at:24 >"$at_check_line_file"
23793
23794 at_trace_this=
23795 if test -n "$at_traceon"; then
23796     echo 'Not enabling shell tracing (command contains an embedded newline)'
23797 fi
23798
23799 if test -n "$at_trace_this"; then
23800     ( $at_traceon;
23801 mkdir oldgnu
23802 (cd oldgnu
23803 TEST_TAR_FORMAT=oldgnu
23804 export TEST_TAR_FORMAT
23805 TAR_OPTIONS="-H oldgnu"
23806 export TAR_OPTIONS
23807 rm -rf *
23808
23809 genfile --length 1000 -f begin
23810 genfile --length 1000 -f end
23811 genfile --sparse --file sparsefile --block-size 512 0 ABCD 1M EFGH 2000K IJKL || exit 77
23812 tar -c -f archive --sparse begin sparsefile end || exit 1
23813 echo separator
23814
23815 tar tfv archive
23816 echo separator
23817 mkdir directory
23818 tar Cxf directory archive
23819 genfile --stat=name,size sparsefile
23820 cmp sparsefile directory/sparsefile
23821 ) ) >"$at_stdout" 2>"$at_stder1"
23822     at_status=$?
23823     grep '^ *+' "$at_stder1" >&2
23824     grep -v '^ *+' "$at_stder1" >"$at_stderr"
23825 else
23826     ( :;
23827 mkdir oldgnu
23828 (cd oldgnu
23829 TEST_TAR_FORMAT=oldgnu
23830 export TEST_TAR_FORMAT
23831 TAR_OPTIONS="-H oldgnu"
23832 export TAR_OPTIONS
23833 rm -rf *
23834
23835 genfile --length 1000 -f begin
23836 genfile --length 1000 -f end
23837 genfile --sparse --file sparsefile --block-size 512 0 ABCD 1M EFGH 2000K IJKL || exit 77
23838 tar -c -f archive --sparse begin sparsefile end || exit 1
23839 echo separator
23840
23841 tar tfv archive
23842 echo separator
23843 mkdir directory
23844 tar Cxf directory archive
23845 genfile --stat=name,size sparsefile
23846 cmp sparsefile directory/sparsefile
23847 ) ) >"$at_stdout" 2>"$at_stderr"
23848     at_status=$?
23849 fi
23850
23851 at_failed=false
23852 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
23853 echo stdout:; tee stdout <"$at_stdout"
23854 case $at_status in
23855    77) echo 77 > "$at_status_file"; exit 77;;
23856    0) ;;
23857    *) echo "$at_srcdir/sparse01.at:24: exit code was $at_status, expected 0"
23858       at_failed=:;;
23859 esac
23860 if $at_failed; then
23861
23862
23863   echo 1 > "$at_status_file"
23864   exit 1
23865 fi
23866
23867 $at_traceon
23868
23869
23870
23871
23872 cat >stdout.re <<'_ATEOF'
23873 separator
23874 -rw-r--r-- ^ ^ *  *1000 0-90-90-90-9-0-90-9-0-90-9 0-90-9:0-90-9 begin
23875 -rw-r--r-- ^ ^ *  *10344448 0-90-90-90-9-0-90-9-0-90-9 0-90-9:0-90-9 sparsefile
23876 -rw-r--r-- ^ ^ *  *1000 0-90-90-90-9-0-90-9-0-90-9 0-90-9:0-90-9 end
23877 separator
23878 sparsefile 10344448
23879 _ATEOF
23880
23881 awk '{print NR " " $0}' stdout > $$.1
23882 awk '{print NR " " $0}' stdout.re | join - $$.1 |
23883 while read NUM RE LINE
23884 do
23885   echo "$LINE" | grep -- "$RE" >/dev/null || exit 1
23886 done
23887
23888
23889       $at_traceoff
23890       $at_times_p && times >"$at_times_file"
23891     ) 5>&1 2>&1 | eval $at_tee_pipe
23892     at_status=`cat "$at_status_file"`
23893     ;;
23894
23895   58 ) # 58. sparse02.at:21: extracting sparse file over a pipe
23896     at_setup_line='sparse02.at:21'
23897     at_desc="extracting sparse file over a pipe"
23898     $at_quiet $ECHO_N " 58: extracting sparse file over a pipe             $ECHO_C"
23899     at_xfail=no
23900       test -f $XFAILFILE && at_xfail=yes
23901     echo "#                             -*- compilation -*-" >> "$at_group_log"
23902     (
23903       echo "58. sparse02.at:21: testing ..."
23904       $at_traceon
23905
23906
23907
23908 # Tar 1.14 - 1.15.1 was unable to extract sparse files to a pipe.
23909 # References: <16896.21739.460782.124775@jik.kamens.brookline.ma.us>
23910 # http://lists.gnu.org/archive/html/bug-tar/2005-02/msg00003.html
23911
23912
23913
23914   $at_traceoff
23915 echo "$at_srcdir/sparse02.at:28:
23916 mkdir posix
23917 (cd posix
23918 TEST_TAR_FORMAT=posix
23919 export TEST_TAR_FORMAT
23920 TAR_OPTIONS=\"-H posix\"
23921 export TAR_OPTIONS
23922 rm -rf *
23923
23924 genfile --sparse --file sparsefile --block-size 512 0 ABCD 1M EFGH 2000K IJKL || exit 77
23925 tar -c -f archive --sparse sparsefile || exit 1
23926 echo separator
23927
23928 tar xfO archive | cat - > sparsecopy || exit 1
23929 cmp sparsefile sparsecopy
23930 )"
23931 echo sparse02.at:28 >"$at_check_line_file"
23932
23933 at_trace_this=
23934 if test -n "$at_traceon"; then
23935     echo 'Not enabling shell tracing (command contains an embedded newline)'
23936 fi
23937
23938 if test -n "$at_trace_this"; then
23939     ( $at_traceon;
23940 mkdir posix
23941 (cd posix
23942 TEST_TAR_FORMAT=posix
23943 export TEST_TAR_FORMAT
23944 TAR_OPTIONS="-H posix"
23945 export TAR_OPTIONS
23946 rm -rf *
23947
23948 genfile --sparse --file sparsefile --block-size 512 0 ABCD 1M EFGH 2000K IJKL || exit 77
23949 tar -c -f archive --sparse sparsefile || exit 1
23950 echo separator
23951
23952 tar xfO archive | cat - > sparsecopy || exit 1
23953 cmp sparsefile sparsecopy
23954 ) ) >"$at_stdout" 2>"$at_stder1"
23955     at_status=$?
23956     grep '^ *+' "$at_stder1" >&2
23957     grep -v '^ *+' "$at_stder1" >"$at_stderr"
23958 else
23959     ( :;
23960 mkdir posix
23961 (cd posix
23962 TEST_TAR_FORMAT=posix
23963 export TEST_TAR_FORMAT
23964 TAR_OPTIONS="-H posix"
23965 export TAR_OPTIONS
23966 rm -rf *
23967
23968 genfile --sparse --file sparsefile --block-size 512 0 ABCD 1M EFGH 2000K IJKL || exit 77
23969 tar -c -f archive --sparse sparsefile || exit 1
23970 echo separator
23971
23972 tar xfO archive | cat - > sparsecopy || exit 1
23973 cmp sparsefile sparsecopy
23974 ) ) >"$at_stdout" 2>"$at_stderr"
23975     at_status=$?
23976 fi
23977
23978 at_failed=false
23979 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
23980 echo >>"$at_stdout"; echo "separator
23981 " | $at_diff - "$at_stdout" || at_failed=:
23982 case $at_status in
23983    77) echo 77 > "$at_status_file"; exit 77;;
23984    0) ;;
23985    *) echo "$at_srcdir/sparse02.at:28: exit code was $at_status, expected 0"
23986       at_failed=:;;
23987 esac
23988 if $at_failed; then
23989
23990
23991   echo 1 > "$at_status_file"
23992   exit 1
23993 fi
23994
23995 $at_traceon
23996 $at_traceoff
23997 echo "$at_srcdir/sparse02.at:28:
23998 mkdir gnu
23999 (cd gnu
24000 TEST_TAR_FORMAT=gnu
24001 export TEST_TAR_FORMAT
24002 TAR_OPTIONS=\"-H gnu\"
24003 export TAR_OPTIONS
24004 rm -rf *
24005
24006 genfile --sparse --file sparsefile --block-size 512 0 ABCD 1M EFGH 2000K IJKL || exit 77
24007 tar -c -f archive --sparse sparsefile || exit 1
24008 echo separator
24009
24010 tar xfO archive | cat - > sparsecopy || exit 1
24011 cmp sparsefile sparsecopy
24012 )"
24013 echo sparse02.at:28 >"$at_check_line_file"
24014
24015 at_trace_this=
24016 if test -n "$at_traceon"; then
24017     echo 'Not enabling shell tracing (command contains an embedded newline)'
24018 fi
24019
24020 if test -n "$at_trace_this"; then
24021     ( $at_traceon;
24022 mkdir gnu
24023 (cd gnu
24024 TEST_TAR_FORMAT=gnu
24025 export TEST_TAR_FORMAT
24026 TAR_OPTIONS="-H gnu"
24027 export TAR_OPTIONS
24028 rm -rf *
24029
24030 genfile --sparse --file sparsefile --block-size 512 0 ABCD 1M EFGH 2000K IJKL || exit 77
24031 tar -c -f archive --sparse sparsefile || exit 1
24032 echo separator
24033
24034 tar xfO archive | cat - > sparsecopy || exit 1
24035 cmp sparsefile sparsecopy
24036 ) ) >"$at_stdout" 2>"$at_stder1"
24037     at_status=$?
24038     grep '^ *+' "$at_stder1" >&2
24039     grep -v '^ *+' "$at_stder1" >"$at_stderr"
24040 else
24041     ( :;
24042 mkdir gnu
24043 (cd gnu
24044 TEST_TAR_FORMAT=gnu
24045 export TEST_TAR_FORMAT
24046 TAR_OPTIONS="-H gnu"
24047 export TAR_OPTIONS
24048 rm -rf *
24049
24050 genfile --sparse --file sparsefile --block-size 512 0 ABCD 1M EFGH 2000K IJKL || exit 77
24051 tar -c -f archive --sparse sparsefile || exit 1
24052 echo separator
24053
24054 tar xfO archive | cat - > sparsecopy || exit 1
24055 cmp sparsefile sparsecopy
24056 ) ) >"$at_stdout" 2>"$at_stderr"
24057     at_status=$?
24058 fi
24059
24060 at_failed=false
24061 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
24062 echo >>"$at_stdout"; echo "separator
24063 " | $at_diff - "$at_stdout" || at_failed=:
24064 case $at_status in
24065    77) echo 77 > "$at_status_file"; exit 77;;
24066    0) ;;
24067    *) echo "$at_srcdir/sparse02.at:28: exit code was $at_status, expected 0"
24068       at_failed=:;;
24069 esac
24070 if $at_failed; then
24071
24072
24073   echo 1 > "$at_status_file"
24074   exit 1
24075 fi
24076
24077 $at_traceon
24078 $at_traceoff
24079 echo "$at_srcdir/sparse02.at:28:
24080 mkdir oldgnu
24081 (cd oldgnu
24082 TEST_TAR_FORMAT=oldgnu
24083 export TEST_TAR_FORMAT
24084 TAR_OPTIONS=\"-H oldgnu\"
24085 export TAR_OPTIONS
24086 rm -rf *
24087
24088 genfile --sparse --file sparsefile --block-size 512 0 ABCD 1M EFGH 2000K IJKL || exit 77
24089 tar -c -f archive --sparse sparsefile || exit 1
24090 echo separator
24091
24092 tar xfO archive | cat - > sparsecopy || exit 1
24093 cmp sparsefile sparsecopy
24094 )"
24095 echo sparse02.at:28 >"$at_check_line_file"
24096
24097 at_trace_this=
24098 if test -n "$at_traceon"; then
24099     echo 'Not enabling shell tracing (command contains an embedded newline)'
24100 fi
24101
24102 if test -n "$at_trace_this"; then
24103     ( $at_traceon;
24104 mkdir oldgnu
24105 (cd oldgnu
24106 TEST_TAR_FORMAT=oldgnu
24107 export TEST_TAR_FORMAT
24108 TAR_OPTIONS="-H oldgnu"
24109 export TAR_OPTIONS
24110 rm -rf *
24111
24112 genfile --sparse --file sparsefile --block-size 512 0 ABCD 1M EFGH 2000K IJKL || exit 77
24113 tar -c -f archive --sparse sparsefile || exit 1
24114 echo separator
24115
24116 tar xfO archive | cat - > sparsecopy || exit 1
24117 cmp sparsefile sparsecopy
24118 ) ) >"$at_stdout" 2>"$at_stder1"
24119     at_status=$?
24120     grep '^ *+' "$at_stder1" >&2
24121     grep -v '^ *+' "$at_stder1" >"$at_stderr"
24122 else
24123     ( :;
24124 mkdir oldgnu
24125 (cd oldgnu
24126 TEST_TAR_FORMAT=oldgnu
24127 export TEST_TAR_FORMAT
24128 TAR_OPTIONS="-H oldgnu"
24129 export TAR_OPTIONS
24130 rm -rf *
24131
24132 genfile --sparse --file sparsefile --block-size 512 0 ABCD 1M EFGH 2000K IJKL || exit 77
24133 tar -c -f archive --sparse sparsefile || exit 1
24134 echo separator
24135
24136 tar xfO archive | cat - > sparsecopy || exit 1
24137 cmp sparsefile sparsecopy
24138 ) ) >"$at_stdout" 2>"$at_stderr"
24139     at_status=$?
24140 fi
24141
24142 at_failed=false
24143 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
24144 echo >>"$at_stdout"; echo "separator
24145 " | $at_diff - "$at_stdout" || at_failed=:
24146 case $at_status in
24147    77) echo 77 > "$at_status_file"; exit 77;;
24148    0) ;;
24149    *) echo "$at_srcdir/sparse02.at:28: exit code was $at_status, expected 0"
24150       at_failed=:;;
24151 esac
24152 if $at_failed; then
24153
24154
24155   echo 1 > "$at_status_file"
24156   exit 1
24157 fi
24158
24159 $at_traceon
24160
24161
24162
24163       $at_traceoff
24164       $at_times_p && times >"$at_times_file"
24165     ) 5>&1 2>&1 | eval $at_tee_pipe
24166     at_status=`cat "$at_status_file"`
24167     ;;
24168
24169   59 ) # 59. sparse03.at:21: storing sparse files > 8G
24170     at_setup_line='sparse03.at:21'
24171     at_desc="storing sparse files > 8G"
24172     $at_quiet $ECHO_N " 59: storing sparse files > 8G                      $ECHO_C"
24173     at_xfail=no
24174       test -f $XFAILFILE && at_xfail=yes
24175     echo "#                             -*- compilation -*-" >> "$at_group_log"
24176     (
24177       echo "59. sparse03.at:21: testing ..."
24178       $at_traceon
24179
24180
24181
24182 # Tar 1.15.1 incorrectly computed sparse member size if the extended
24183 # PAX header contained size keyword.
24184 # References: <87vf46nb36.fsf@penguin.cs.ucla.edu>
24185 # http://lists.gnu.org/archive/html/bug-tar/2005-06/msg00040.html
24186
24187
24188
24189   $at_traceoff
24190 echo "$at_srcdir/sparse03.at:29:
24191 mkdir posix
24192 (cd posix
24193 TEST_TAR_FORMAT=posix
24194 export TEST_TAR_FORMAT
24195 TAR_OPTIONS=\"-H posix\"
24196 export TAR_OPTIONS
24197 rm -rf *
24198
24199 genfile --length 1000 --file begin
24200 genfile --length 1000 --file end
24201 genfile --sparse --file sparsefile --block-size 512 8G A || exit 77
24202 tar -c -f archive --sparse begin sparsefile end || exit 1
24203 echo separator
24204
24205 tar tfv archive
24206 echo separator
24207 mkdir directory
24208 tar Cxf directory archive
24209 genfile --stat=name,size sparsefile
24210 cmp sparsefile directory/sparsefile
24211 )"
24212 echo sparse03.at:29 >"$at_check_line_file"
24213
24214 at_trace_this=
24215 if test -n "$at_traceon"; then
24216     echo 'Not enabling shell tracing (command contains an embedded newline)'
24217 fi
24218
24219 if test -n "$at_trace_this"; then
24220     ( $at_traceon;
24221 mkdir posix
24222 (cd posix
24223 TEST_TAR_FORMAT=posix
24224 export TEST_TAR_FORMAT
24225 TAR_OPTIONS="-H posix"
24226 export TAR_OPTIONS
24227 rm -rf *
24228
24229 genfile --length 1000 --file begin
24230 genfile --length 1000 --file end
24231 genfile --sparse --file sparsefile --block-size 512 8G A || exit 77
24232 tar -c -f archive --sparse begin sparsefile end || exit 1
24233 echo separator
24234
24235 tar tfv archive
24236 echo separator
24237 mkdir directory
24238 tar Cxf directory archive
24239 genfile --stat=name,size sparsefile
24240 cmp sparsefile directory/sparsefile
24241 ) ) >"$at_stdout" 2>"$at_stder1"
24242     at_status=$?
24243     grep '^ *+' "$at_stder1" >&2
24244     grep -v '^ *+' "$at_stder1" >"$at_stderr"
24245 else
24246     ( :;
24247 mkdir posix
24248 (cd posix
24249 TEST_TAR_FORMAT=posix
24250 export TEST_TAR_FORMAT
24251 TAR_OPTIONS="-H posix"
24252 export TAR_OPTIONS
24253 rm -rf *
24254
24255 genfile --length 1000 --file begin
24256 genfile --length 1000 --file end
24257 genfile --sparse --file sparsefile --block-size 512 8G A || exit 77
24258 tar -c -f archive --sparse begin sparsefile end || exit 1
24259 echo separator
24260
24261 tar tfv archive
24262 echo separator
24263 mkdir directory
24264 tar Cxf directory archive
24265 genfile --stat=name,size sparsefile
24266 cmp sparsefile directory/sparsefile
24267 ) ) >"$at_stdout" 2>"$at_stderr"
24268     at_status=$?
24269 fi
24270
24271 at_failed=false
24272 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
24273 echo stdout:; tee stdout <"$at_stdout"
24274 case $at_status in
24275    77) echo 77 > "$at_status_file"; exit 77;;
24276    0) ;;
24277    *) echo "$at_srcdir/sparse03.at:29: exit code was $at_status, expected 0"
24278       at_failed=:;;
24279 esac
24280 if $at_failed; then
24281
24282
24283   echo 1 > "$at_status_file"
24284   exit 1
24285 fi
24286
24287 $at_traceon
24288
24289
24290
24291
24292 cat >stdout.re <<'_ATEOF'
24293 separator
24294 -rw-r--r-- ^ ^ *  *1000 0-90-90-90-9-0-90-9-0-90-9 0-90-9:0-90-9 begin
24295 -rw-r--r-- ^ ^ *  *8589935104 0-90-90-90-9-0-90-9-0-90-9 0-90-9:0-90-9 sparsefile
24296 -rw-r--r-- ^ ^ *  *1000 0-90-90-90-9-0-90-9-0-90-9 0-90-9:0-90-9 end
24297 separator
24298 sparsefile 8589935104
24299 _ATEOF
24300
24301 awk '{print NR " " $0}' stdout > $$.1
24302 awk '{print NR " " $0}' stdout.re | join - $$.1 |
24303 while read NUM RE LINE
24304 do
24305   echo "$LINE" | grep -- "$RE" >/dev/null || exit 1
24306 done
24307
24308
24309       $at_traceoff
24310       $at_times_p && times >"$at_times_file"
24311     ) 5>&1 2>&1 | eval $at_tee_pipe
24312     at_status=`cat "$at_status_file"`
24313     ;;
24314
24315   60 ) # 60. sparsemv.at:21: sparse files in MV archives
24316     at_setup_line='sparsemv.at:21'
24317     at_desc="sparse files in MV archives"
24318     $at_quiet $ECHO_N " 60: sparse files in MV archives                    $ECHO_C"
24319     at_xfail=no
24320       test -f $XFAILFILE && at_xfail=yes
24321     echo "#                             -*- compilation -*-" >> "$at_group_log"
24322     (
24323       echo "60. sparsemv.at:21: testing ..."
24324       $at_traceon
24325
24326
24327
24328 # Check if sparse files are correctly split between GNU multi-volume
24329 # archives.
24330 # There are two cases: the file can be split within an empty (null) block,
24331 # or within a data block. Since null blocks are not archived, the first
24332 # case means the file is split between two consecutive data blocks.
24333 #
24334
24335
24336
24337   $at_traceoff
24338 echo "$at_srcdir/sparsemv.at:31:
24339 mkdir gnu
24340 (cd gnu
24341 TEST_TAR_FORMAT=gnu
24342 export TEST_TAR_FORMAT
24343 TAR_OPTIONS=\"-H gnu\"
24344 export TAR_OPTIONS
24345 rm -rf *
24346
24347 exec <&-
24348 genfile --sparse --file sparsefile 0 ABCDEFGHIJK 1M ABCDEFGHI || exit 77
24349 echo \"Pass 1: Split between data blocks\"
24350 echo \"Create archive\"
24351 tar --sparse -c --record-size=512 -M -L6 -f arc.1 -f arc.2 sparsefile || exit 1
24352 echo \"Test archive\"
24353 tar --record-size=512 -t -M -f arc.1 -f arc.2
24354 echo \"Compare archive\"
24355 tar --record-size=512 -d -M -f arc.1 -f arc.2
24356
24357 echo \"Pass 2: Split within a data block\"
24358 genfile --sparse --file sparsefile 0 ABCDEFGHIJ 1M ABCDEFGHI || exit 77
24359 echo \"Create archive\"
24360 tar --sparse -c --record-size=512 -M -L6 -f arc.1 -f arc.2 sparsefile || exit 1
24361 echo \"Test archive\"
24362 tar --record-size=512 -t -M -f arc.1 -f arc.2
24363 echo \"Compare archive\"
24364 tar --record-size=512 -d -M -f arc.1 -f arc.2
24365 )"
24366 echo sparsemv.at:31 >"$at_check_line_file"
24367
24368 at_trace_this=
24369 if test -n "$at_traceon"; then
24370     echo 'Not enabling shell tracing (command contains an embedded newline)'
24371 fi
24372
24373 if test -n "$at_trace_this"; then
24374     ( $at_traceon;
24375 mkdir gnu
24376 (cd gnu
24377 TEST_TAR_FORMAT=gnu
24378 export TEST_TAR_FORMAT
24379 TAR_OPTIONS="-H gnu"
24380 export TAR_OPTIONS
24381 rm -rf *
24382
24383 exec <&-
24384 genfile --sparse --file sparsefile 0 ABCDEFGHIJK 1M ABCDEFGHI || exit 77
24385 echo "Pass 1: Split between data blocks"
24386 echo "Create archive"
24387 tar --sparse -c --record-size=512 -M -L6 -f arc.1 -f arc.2 sparsefile || exit 1
24388 echo "Test archive"
24389 tar --record-size=512 -t -M -f arc.1 -f arc.2
24390 echo "Compare archive"
24391 tar --record-size=512 -d -M -f arc.1 -f arc.2
24392
24393 echo "Pass 2: Split within a data block"
24394 genfile --sparse --file sparsefile 0 ABCDEFGHIJ 1M ABCDEFGHI || exit 77
24395 echo "Create archive"
24396 tar --sparse -c --record-size=512 -M -L6 -f arc.1 -f arc.2 sparsefile || exit 1
24397 echo "Test archive"
24398 tar --record-size=512 -t -M -f arc.1 -f arc.2
24399 echo "Compare archive"
24400 tar --record-size=512 -d -M -f arc.1 -f arc.2
24401 ) ) >"$at_stdout" 2>"$at_stder1"
24402     at_status=$?
24403     grep '^ *+' "$at_stder1" >&2
24404     grep -v '^ *+' "$at_stder1" >"$at_stderr"
24405 else
24406     ( :;
24407 mkdir gnu
24408 (cd gnu
24409 TEST_TAR_FORMAT=gnu
24410 export TEST_TAR_FORMAT
24411 TAR_OPTIONS="-H gnu"
24412 export TAR_OPTIONS
24413 rm -rf *
24414
24415 exec <&-
24416 genfile --sparse --file sparsefile 0 ABCDEFGHIJK 1M ABCDEFGHI || exit 77
24417 echo "Pass 1: Split between data blocks"
24418 echo "Create archive"
24419 tar --sparse -c --record-size=512 -M -L6 -f arc.1 -f arc.2 sparsefile || exit 1
24420 echo "Test archive"
24421 tar --record-size=512 -t -M -f arc.1 -f arc.2
24422 echo "Compare archive"
24423 tar --record-size=512 -d -M -f arc.1 -f arc.2
24424
24425 echo "Pass 2: Split within a data block"
24426 genfile --sparse --file sparsefile 0 ABCDEFGHIJ 1M ABCDEFGHI || exit 77
24427 echo "Create archive"
24428 tar --sparse -c --record-size=512 -M -L6 -f arc.1 -f arc.2 sparsefile || exit 1
24429 echo "Test archive"
24430 tar --record-size=512 -t -M -f arc.1 -f arc.2
24431 echo "Compare archive"
24432 tar --record-size=512 -d -M -f arc.1 -f arc.2
24433 ) ) >"$at_stdout" 2>"$at_stderr"
24434     at_status=$?
24435 fi
24436
24437 at_failed=false
24438 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
24439 echo >>"$at_stdout"; echo "Pass 1: Split between data blocks
24440 Create archive
24441 Test archive
24442 sparsefile
24443 Compare archive
24444 Pass 2: Split within a data block
24445 Create archive
24446 Test archive
24447 sparsefile
24448 Compare archive
24449 " | $at_diff - "$at_stdout" || at_failed=:
24450 case $at_status in
24451    77) echo 77 > "$at_status_file"; exit 77;;
24452    0) ;;
24453    *) echo "$at_srcdir/sparsemv.at:31: exit code was $at_status, expected 0"
24454       at_failed=:;;
24455 esac
24456 if $at_failed; then
24457
24458
24459   echo 1 > "$at_status_file"
24460   exit 1
24461 fi
24462
24463 $at_traceon
24464 $at_traceoff
24465 echo "$at_srcdir/sparsemv.at:31:
24466 mkdir oldgnu
24467 (cd oldgnu
24468 TEST_TAR_FORMAT=oldgnu
24469 export TEST_TAR_FORMAT
24470 TAR_OPTIONS=\"-H oldgnu\"
24471 export TAR_OPTIONS
24472 rm -rf *
24473
24474 exec <&-
24475 genfile --sparse --file sparsefile 0 ABCDEFGHIJK 1M ABCDEFGHI || exit 77
24476 echo \"Pass 1: Split between data blocks\"
24477 echo \"Create archive\"
24478 tar --sparse -c --record-size=512 -M -L6 -f arc.1 -f arc.2 sparsefile || exit 1
24479 echo \"Test archive\"
24480 tar --record-size=512 -t -M -f arc.1 -f arc.2
24481 echo \"Compare archive\"
24482 tar --record-size=512 -d -M -f arc.1 -f arc.2
24483
24484 echo \"Pass 2: Split within a data block\"
24485 genfile --sparse --file sparsefile 0 ABCDEFGHIJ 1M ABCDEFGHI || exit 77
24486 echo \"Create archive\"
24487 tar --sparse -c --record-size=512 -M -L6 -f arc.1 -f arc.2 sparsefile || exit 1
24488 echo \"Test archive\"
24489 tar --record-size=512 -t -M -f arc.1 -f arc.2
24490 echo \"Compare archive\"
24491 tar --record-size=512 -d -M -f arc.1 -f arc.2
24492 )"
24493 echo sparsemv.at:31 >"$at_check_line_file"
24494
24495 at_trace_this=
24496 if test -n "$at_traceon"; then
24497     echo 'Not enabling shell tracing (command contains an embedded newline)'
24498 fi
24499
24500 if test -n "$at_trace_this"; then
24501     ( $at_traceon;
24502 mkdir oldgnu
24503 (cd oldgnu
24504 TEST_TAR_FORMAT=oldgnu
24505 export TEST_TAR_FORMAT
24506 TAR_OPTIONS="-H oldgnu"
24507 export TAR_OPTIONS
24508 rm -rf *
24509
24510 exec <&-
24511 genfile --sparse --file sparsefile 0 ABCDEFGHIJK 1M ABCDEFGHI || exit 77
24512 echo "Pass 1: Split between data blocks"
24513 echo "Create archive"
24514 tar --sparse -c --record-size=512 -M -L6 -f arc.1 -f arc.2 sparsefile || exit 1
24515 echo "Test archive"
24516 tar --record-size=512 -t -M -f arc.1 -f arc.2
24517 echo "Compare archive"
24518 tar --record-size=512 -d -M -f arc.1 -f arc.2
24519
24520 echo "Pass 2: Split within a data block"
24521 genfile --sparse --file sparsefile 0 ABCDEFGHIJ 1M ABCDEFGHI || exit 77
24522 echo "Create archive"
24523 tar --sparse -c --record-size=512 -M -L6 -f arc.1 -f arc.2 sparsefile || exit 1
24524 echo "Test archive"
24525 tar --record-size=512 -t -M -f arc.1 -f arc.2
24526 echo "Compare archive"
24527 tar --record-size=512 -d -M -f arc.1 -f arc.2
24528 ) ) >"$at_stdout" 2>"$at_stder1"
24529     at_status=$?
24530     grep '^ *+' "$at_stder1" >&2
24531     grep -v '^ *+' "$at_stder1" >"$at_stderr"
24532 else
24533     ( :;
24534 mkdir oldgnu
24535 (cd oldgnu
24536 TEST_TAR_FORMAT=oldgnu
24537 export TEST_TAR_FORMAT
24538 TAR_OPTIONS="-H oldgnu"
24539 export TAR_OPTIONS
24540 rm -rf *
24541
24542 exec <&-
24543 genfile --sparse --file sparsefile 0 ABCDEFGHIJK 1M ABCDEFGHI || exit 77
24544 echo "Pass 1: Split between data blocks"
24545 echo "Create archive"
24546 tar --sparse -c --record-size=512 -M -L6 -f arc.1 -f arc.2 sparsefile || exit 1
24547 echo "Test archive"
24548 tar --record-size=512 -t -M -f arc.1 -f arc.2
24549 echo "Compare archive"
24550 tar --record-size=512 -d -M -f arc.1 -f arc.2
24551
24552 echo "Pass 2: Split within a data block"
24553 genfile --sparse --file sparsefile 0 ABCDEFGHIJ 1M ABCDEFGHI || exit 77
24554 echo "Create archive"
24555 tar --sparse -c --record-size=512 -M -L6 -f arc.1 -f arc.2 sparsefile || exit 1
24556 echo "Test archive"
24557 tar --record-size=512 -t -M -f arc.1 -f arc.2
24558 echo "Compare archive"
24559 tar --record-size=512 -d -M -f arc.1 -f arc.2
24560 ) ) >"$at_stdout" 2>"$at_stderr"
24561     at_status=$?
24562 fi
24563
24564 at_failed=false
24565 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
24566 echo >>"$at_stdout"; echo "Pass 1: Split between data blocks
24567 Create archive
24568 Test archive
24569 sparsefile
24570 Compare archive
24571 Pass 2: Split within a data block
24572 Create archive
24573 Test archive
24574 sparsefile
24575 Compare archive
24576 " | $at_diff - "$at_stdout" || at_failed=:
24577 case $at_status in
24578    77) echo 77 > "$at_status_file"; exit 77;;
24579    0) ;;
24580    *) echo "$at_srcdir/sparsemv.at:31: exit code was $at_status, expected 0"
24581       at_failed=:;;
24582 esac
24583 if $at_failed; then
24584
24585
24586   echo 1 > "$at_status_file"
24587   exit 1
24588 fi
24589
24590 $at_traceon
24591
24592
24593
24594       $at_traceoff
24595       $at_times_p && times >"$at_times_file"
24596     ) 5>&1 2>&1 | eval $at_tee_pipe
24597     at_status=`cat "$at_status_file"`
24598     ;;
24599
24600   61 ) # 61. spmvp00.at:21: sparse files in PAX MV archives, v.0.0
24601     at_setup_line='spmvp00.at:21'
24602     at_desc="sparse files in PAX MV archives, v.0.0"
24603     $at_quiet $ECHO_N " 61: sparse files in PAX MV archives, v.0.0         $ECHO_C"
24604     at_xfail=no
24605       test -f $XFAILFILE && at_xfail=yes
24606     echo "#                             -*- compilation -*-" >> "$at_group_log"
24607     (
24608       echo "61. spmvp00.at:21: testing ..."
24609       $at_traceon
24610
24611
24612
24613
24614
24615
24616   $at_traceoff
24617 echo "$at_srcdir/spmvp00.at:24:
24618 mkdir pax
24619 (cd pax
24620 TEST_TAR_FORMAT=pax
24621 export TEST_TAR_FORMAT
24622 TAR_OPTIONS=\"-H pax\"
24623 export TAR_OPTIONS
24624 rm -rf *
24625
24626 exec <&-
24627 genfile --sparse --file sparsefile 0 ABCDEFGHI 1M ABCDEFGHI || exit 77
24628 echo \"Pass 1: Split between data blocks\"
24629 echo \"Create archive\"
24630 tar --sparse --sparse-version=0.0 -c --record-size=512 -M -L6 -f arc.1 -f arc.2 -f arc.3 sparsefile
24631 echo \"Test archive\"
24632 tar -t -M -f arc.1 -f arc.2 -f arc.3
24633 echo \"Compare archive\"
24634 tar -d -M -f arc.1 -f arc.2 -f arc.3
24635
24636 echo \"Pass 2: Split within a data block\"
24637 genfile --sparse --file sparsefile 0 ABCDEFGH 1M ABCDEFGHI || exit 77
24638 echo \"Create archive\"
24639 tar --sparse --sparse-version=0.0 -c --record-size=512 -M -L6 -f arc.1 -f arc.2 -f arc.3 sparsefile
24640 echo \"Test archive\"
24641 tar -t -M -f arc.1 -f arc.2 -f arc.3
24642 echo \"Compare archive\"
24643 tar -d -M -f arc.1 -f arc.2 -f arc.3
24644 )"
24645 echo spmvp00.at:24 >"$at_check_line_file"
24646
24647 at_trace_this=
24648 if test -n "$at_traceon"; then
24649     echo 'Not enabling shell tracing (command contains an embedded newline)'
24650 fi
24651
24652 if test -n "$at_trace_this"; then
24653     ( $at_traceon;
24654 mkdir pax
24655 (cd pax
24656 TEST_TAR_FORMAT=pax
24657 export TEST_TAR_FORMAT
24658 TAR_OPTIONS="-H pax"
24659 export TAR_OPTIONS
24660 rm -rf *
24661
24662 exec <&-
24663 genfile --sparse --file sparsefile 0 ABCDEFGHI 1M ABCDEFGHI || exit 77
24664 echo "Pass 1: Split between data blocks"
24665 echo "Create archive"
24666 tar --sparse --sparse-version=0.0 -c --record-size=512 -M -L6 -f arc.1 -f arc.2 -f arc.3 sparsefile
24667 echo "Test archive"
24668 tar -t -M -f arc.1 -f arc.2 -f arc.3
24669 echo "Compare archive"
24670 tar -d -M -f arc.1 -f arc.2 -f arc.3
24671
24672 echo "Pass 2: Split within a data block"
24673 genfile --sparse --file sparsefile 0 ABCDEFGH 1M ABCDEFGHI || exit 77
24674 echo "Create archive"
24675 tar --sparse --sparse-version=0.0 -c --record-size=512 -M -L6 -f arc.1 -f arc.2 -f arc.3 sparsefile
24676 echo "Test archive"
24677 tar -t -M -f arc.1 -f arc.2 -f arc.3
24678 echo "Compare archive"
24679 tar -d -M -f arc.1 -f arc.2 -f arc.3
24680 ) ) >"$at_stdout" 2>"$at_stder1"
24681     at_status=$?
24682     grep '^ *+' "$at_stder1" >&2
24683     grep -v '^ *+' "$at_stder1" >"$at_stderr"
24684 else
24685     ( :;
24686 mkdir pax
24687 (cd pax
24688 TEST_TAR_FORMAT=pax
24689 export TEST_TAR_FORMAT
24690 TAR_OPTIONS="-H pax"
24691 export TAR_OPTIONS
24692 rm -rf *
24693
24694 exec <&-
24695 genfile --sparse --file sparsefile 0 ABCDEFGHI 1M ABCDEFGHI || exit 77
24696 echo "Pass 1: Split between data blocks"
24697 echo "Create archive"
24698 tar --sparse --sparse-version=0.0 -c --record-size=512 -M -L6 -f arc.1 -f arc.2 -f arc.3 sparsefile
24699 echo "Test archive"
24700 tar -t -M -f arc.1 -f arc.2 -f arc.3
24701 echo "Compare archive"
24702 tar -d -M -f arc.1 -f arc.2 -f arc.3
24703
24704 echo "Pass 2: Split within a data block"
24705 genfile --sparse --file sparsefile 0 ABCDEFGH 1M ABCDEFGHI || exit 77
24706 echo "Create archive"
24707 tar --sparse --sparse-version=0.0 -c --record-size=512 -M -L6 -f arc.1 -f arc.2 -f arc.3 sparsefile
24708 echo "Test archive"
24709 tar -t -M -f arc.1 -f arc.2 -f arc.3
24710 echo "Compare archive"
24711 tar -d -M -f arc.1 -f arc.2 -f arc.3
24712 ) ) >"$at_stdout" 2>"$at_stderr"
24713     at_status=$?
24714 fi
24715
24716 at_failed=false
24717 echo >>"$at_stderr"; echo "tar: Record size = 12 blocks
24718 tar: Record size = 12 blocks
24719 " | $at_diff - "$at_stderr" || at_failed=:
24720 echo >>"$at_stdout"; echo "Pass 1: Split between data blocks
24721 Create archive
24722 Test archive
24723 sparsefile
24724 Compare archive
24725 Pass 2: Split within a data block
24726 Create archive
24727 Test archive
24728 sparsefile
24729 Compare archive
24730 " | $at_diff - "$at_stdout" || at_failed=:
24731 case $at_status in
24732    77) echo 77 > "$at_status_file"; exit 77;;
24733    0) ;;
24734    *) echo "$at_srcdir/spmvp00.at:24: exit code was $at_status, expected 0"
24735       at_failed=:;;
24736 esac
24737 if $at_failed; then
24738
24739
24740   echo 1 > "$at_status_file"
24741   exit 1
24742 fi
24743
24744 $at_traceon
24745
24746
24747
24748       $at_traceoff
24749       $at_times_p && times >"$at_times_file"
24750     ) 5>&1 2>&1 | eval $at_tee_pipe
24751     at_status=`cat "$at_status_file"`
24752     ;;
24753
24754   62 ) # 62. spmvp01.at:21: sparse files in PAX MV archives, v.0.1
24755     at_setup_line='spmvp01.at:21'
24756     at_desc="sparse files in PAX MV archives, v.0.1"
24757     $at_quiet $ECHO_N " 62: sparse files in PAX MV archives, v.0.1         $ECHO_C"
24758     at_xfail=no
24759       test -f $XFAILFILE && at_xfail=yes
24760     echo "#                             -*- compilation -*-" >> "$at_group_log"
24761     (
24762       echo "62. spmvp01.at:21: testing ..."
24763       $at_traceon
24764
24765
24766
24767
24768
24769
24770   $at_traceoff
24771 echo "$at_srcdir/spmvp01.at:24:
24772 mkdir pax
24773 (cd pax
24774 TEST_TAR_FORMAT=pax
24775 export TEST_TAR_FORMAT
24776 TAR_OPTIONS=\"-H pax\"
24777 export TAR_OPTIONS
24778 rm -rf *
24779
24780 exec <&-
24781 genfile --sparse --file sparsefile 0 ABCDEFGHIJK 1M ABCDEFGHI || exit 77
24782 echo \"Pass 1: Split between data blocks\"
24783 echo \"Create archive\"
24784 tar --sparse --sparse-version=0.1 -c --record-size=512 -M -L6 -f arc.1 -f arc.2 -f arc.3 sparsefile
24785 echo \"Test archive\"
24786 tar -t -M -f arc.1 -f arc.2 -f arc.3
24787 echo \"Compare archive\"
24788 tar -d -M -f arc.1 -f arc.2 -f arc.3
24789
24790 echo \"Pass 2: Split within a data block\"
24791 genfile --sparse --file sparsefile 0 ABCDEFGHIJ 1M ABCDEFGHI || exit 77
24792 echo \"Create archive\"
24793 tar --sparse --sparse-version=0.1 -c --record-size=512 -M -L6 -f arc.1 -f arc.2 -f arc.3 sparsefile
24794 echo \"Test archive\"
24795 tar -t -M -f arc.1 -f arc.2 -f arc.3
24796 echo \"Compare archive\"
24797 tar -d -M -f arc.1 -f arc.2 -f arc.3
24798 )"
24799 echo spmvp01.at:24 >"$at_check_line_file"
24800
24801 at_trace_this=
24802 if test -n "$at_traceon"; then
24803     echo 'Not enabling shell tracing (command contains an embedded newline)'
24804 fi
24805
24806 if test -n "$at_trace_this"; then
24807     ( $at_traceon;
24808 mkdir pax
24809 (cd pax
24810 TEST_TAR_FORMAT=pax
24811 export TEST_TAR_FORMAT
24812 TAR_OPTIONS="-H pax"
24813 export TAR_OPTIONS
24814 rm -rf *
24815
24816 exec <&-
24817 genfile --sparse --file sparsefile 0 ABCDEFGHIJK 1M ABCDEFGHI || exit 77
24818 echo "Pass 1: Split between data blocks"
24819 echo "Create archive"
24820 tar --sparse --sparse-version=0.1 -c --record-size=512 -M -L6 -f arc.1 -f arc.2 -f arc.3 sparsefile
24821 echo "Test archive"
24822 tar -t -M -f arc.1 -f arc.2 -f arc.3
24823 echo "Compare archive"
24824 tar -d -M -f arc.1 -f arc.2 -f arc.3
24825
24826 echo "Pass 2: Split within a data block"
24827 genfile --sparse --file sparsefile 0 ABCDEFGHIJ 1M ABCDEFGHI || exit 77
24828 echo "Create archive"
24829 tar --sparse --sparse-version=0.1 -c --record-size=512 -M -L6 -f arc.1 -f arc.2 -f arc.3 sparsefile
24830 echo "Test archive"
24831 tar -t -M -f arc.1 -f arc.2 -f arc.3
24832 echo "Compare archive"
24833 tar -d -M -f arc.1 -f arc.2 -f arc.3
24834 ) ) >"$at_stdout" 2>"$at_stder1"
24835     at_status=$?
24836     grep '^ *+' "$at_stder1" >&2
24837     grep -v '^ *+' "$at_stder1" >"$at_stderr"
24838 else
24839     ( :;
24840 mkdir pax
24841 (cd pax
24842 TEST_TAR_FORMAT=pax
24843 export TEST_TAR_FORMAT
24844 TAR_OPTIONS="-H pax"
24845 export TAR_OPTIONS
24846 rm -rf *
24847
24848 exec <&-
24849 genfile --sparse --file sparsefile 0 ABCDEFGHIJK 1M ABCDEFGHI || exit 77
24850 echo "Pass 1: Split between data blocks"
24851 echo "Create archive"
24852 tar --sparse --sparse-version=0.1 -c --record-size=512 -M -L6 -f arc.1 -f arc.2 -f arc.3 sparsefile
24853 echo "Test archive"
24854 tar -t -M -f arc.1 -f arc.2 -f arc.3
24855 echo "Compare archive"
24856 tar -d -M -f arc.1 -f arc.2 -f arc.3
24857
24858 echo "Pass 2: Split within a data block"
24859 genfile --sparse --file sparsefile 0 ABCDEFGHIJ 1M ABCDEFGHI || exit 77
24860 echo "Create archive"
24861 tar --sparse --sparse-version=0.1 -c --record-size=512 -M -L6 -f arc.1 -f arc.2 -f arc.3 sparsefile
24862 echo "Test archive"
24863 tar -t -M -f arc.1 -f arc.2 -f arc.3
24864 echo "Compare archive"
24865 tar -d -M -f arc.1 -f arc.2 -f arc.3
24866 ) ) >"$at_stdout" 2>"$at_stderr"
24867     at_status=$?
24868 fi
24869
24870 at_failed=false
24871 echo >>"$at_stderr"; echo "tar: Record size = 12 blocks
24872 tar: Record size = 12 blocks
24873 " | $at_diff - "$at_stderr" || at_failed=:
24874 echo >>"$at_stdout"; echo "Pass 1: Split between data blocks
24875 Create archive
24876 Test archive
24877 sparsefile
24878 Compare archive
24879 Pass 2: Split within a data block
24880 Create archive
24881 Test archive
24882 sparsefile
24883 Compare archive
24884 " | $at_diff - "$at_stdout" || at_failed=:
24885 case $at_status in
24886    77) echo 77 > "$at_status_file"; exit 77;;
24887    0) ;;
24888    *) echo "$at_srcdir/spmvp01.at:24: exit code was $at_status, expected 0"
24889       at_failed=:;;
24890 esac
24891 if $at_failed; then
24892
24893
24894   echo 1 > "$at_status_file"
24895   exit 1
24896 fi
24897
24898 $at_traceon
24899
24900
24901
24902       $at_traceoff
24903       $at_times_p && times >"$at_times_file"
24904     ) 5>&1 2>&1 | eval $at_tee_pipe
24905     at_status=`cat "$at_status_file"`
24906     ;;
24907
24908   63 ) # 63. spmvp10.at:21: sparse files in PAX MV archives, v.1.0
24909     at_setup_line='spmvp10.at:21'
24910     at_desc="sparse files in PAX MV archives, v.1.0"
24911     $at_quiet $ECHO_N " 63: sparse files in PAX MV archives, v.1.0         $ECHO_C"
24912     at_xfail=no
24913       test -f $XFAILFILE && at_xfail=yes
24914     echo "#                             -*- compilation -*-" >> "$at_group_log"
24915     (
24916       echo "63. spmvp10.at:21: testing ..."
24917       $at_traceon
24918
24919
24920
24921
24922
24923
24924   $at_traceoff
24925 echo "$at_srcdir/spmvp10.at:24:
24926 mkdir pax
24927 (cd pax
24928 TEST_TAR_FORMAT=pax
24929 export TEST_TAR_FORMAT
24930 TAR_OPTIONS=\"-H pax\"
24931 export TAR_OPTIONS
24932 rm -rf *
24933
24934 exec <&-
24935 genfile --sparse --file sparsefile 0 ABCDEFGH 1M ABCDEFGHI || exit 77
24936 echo \"Pass 1: Split between data blocks\"
24937 echo \"Create archive\"
24938 tar --sparse --sparse-version=1.0 -c --record-size=512 -M -L6 -f arc.1 -f arc.2 -f arc.3 sparsefile
24939 echo \"Test archive\"
24940 tar -t -M -f arc.1 -f arc.2 -f arc.3
24941 echo \"Compare archive\"
24942 tar -d -M -f arc.1 -f arc.2 -f arc.3
24943
24944 echo \"Pass 2: Split within a data block\"
24945 genfile --sparse --file sparsefile 0 ABCDEFG 1M ABCDEFGHI || exit 77
24946 echo \"Create archive\"
24947 tar --sparse --sparse-version=1.0 -c --record-size=512 -M -L6 -f arc.1 -f arc.2 -f arc.3 sparsefile
24948 echo \"Test archive\"
24949 tar -t -M -f arc.1 -f arc.2 -f arc.3
24950 echo \"Compare archive\"
24951 tar -d -M -f arc.1 -f arc.2 -f arc.3
24952 )"
24953 echo spmvp10.at:24 >"$at_check_line_file"
24954
24955 at_trace_this=
24956 if test -n "$at_traceon"; then
24957     echo 'Not enabling shell tracing (command contains an embedded newline)'
24958 fi
24959
24960 if test -n "$at_trace_this"; then
24961     ( $at_traceon;
24962 mkdir pax
24963 (cd pax
24964 TEST_TAR_FORMAT=pax
24965 export TEST_TAR_FORMAT
24966 TAR_OPTIONS="-H pax"
24967 export TAR_OPTIONS
24968 rm -rf *
24969
24970 exec <&-
24971 genfile --sparse --file sparsefile 0 ABCDEFGH 1M ABCDEFGHI || exit 77
24972 echo "Pass 1: Split between data blocks"
24973 echo "Create archive"
24974 tar --sparse --sparse-version=1.0 -c --record-size=512 -M -L6 -f arc.1 -f arc.2 -f arc.3 sparsefile
24975 echo "Test archive"
24976 tar -t -M -f arc.1 -f arc.2 -f arc.3
24977 echo "Compare archive"
24978 tar -d -M -f arc.1 -f arc.2 -f arc.3
24979
24980 echo "Pass 2: Split within a data block"
24981 genfile --sparse --file sparsefile 0 ABCDEFG 1M ABCDEFGHI || exit 77
24982 echo "Create archive"
24983 tar --sparse --sparse-version=1.0 -c --record-size=512 -M -L6 -f arc.1 -f arc.2 -f arc.3 sparsefile
24984 echo "Test archive"
24985 tar -t -M -f arc.1 -f arc.2 -f arc.3
24986 echo "Compare archive"
24987 tar -d -M -f arc.1 -f arc.2 -f arc.3
24988 ) ) >"$at_stdout" 2>"$at_stder1"
24989     at_status=$?
24990     grep '^ *+' "$at_stder1" >&2
24991     grep -v '^ *+' "$at_stder1" >"$at_stderr"
24992 else
24993     ( :;
24994 mkdir pax
24995 (cd pax
24996 TEST_TAR_FORMAT=pax
24997 export TEST_TAR_FORMAT
24998 TAR_OPTIONS="-H pax"
24999 export TAR_OPTIONS
25000 rm -rf *
25001
25002 exec <&-
25003 genfile --sparse --file sparsefile 0 ABCDEFGH 1M ABCDEFGHI || exit 77
25004 echo "Pass 1: Split between data blocks"
25005 echo "Create archive"
25006 tar --sparse --sparse-version=1.0 -c --record-size=512 -M -L6 -f arc.1 -f arc.2 -f arc.3 sparsefile
25007 echo "Test archive"
25008 tar -t -M -f arc.1 -f arc.2 -f arc.3
25009 echo "Compare archive"
25010 tar -d -M -f arc.1 -f arc.2 -f arc.3
25011
25012 echo "Pass 2: Split within a data block"
25013 genfile --sparse --file sparsefile 0 ABCDEFG 1M ABCDEFGHI || exit 77
25014 echo "Create archive"
25015 tar --sparse --sparse-version=1.0 -c --record-size=512 -M -L6 -f arc.1 -f arc.2 -f arc.3 sparsefile
25016 echo "Test archive"
25017 tar -t -M -f arc.1 -f arc.2 -f arc.3
25018 echo "Compare archive"
25019 tar -d -M -f arc.1 -f arc.2 -f arc.3
25020 ) ) >"$at_stdout" 2>"$at_stderr"
25021     at_status=$?
25022 fi
25023
25024 at_failed=false
25025 echo >>"$at_stderr"; echo "tar: Record size = 12 blocks
25026 tar: Record size = 12 blocks
25027 " | $at_diff - "$at_stderr" || at_failed=:
25028 echo >>"$at_stdout"; echo "Pass 1: Split between data blocks
25029 Create archive
25030 Test archive
25031 sparsefile
25032 Compare archive
25033 Pass 2: Split within a data block
25034 Create archive
25035 Test archive
25036 sparsefile
25037 Compare archive
25038 " | $at_diff - "$at_stdout" || at_failed=:
25039 case $at_status in
25040    77) echo 77 > "$at_status_file"; exit 77;;
25041    0) ;;
25042    *) echo "$at_srcdir/spmvp10.at:24: exit code was $at_status, expected 0"
25043       at_failed=:;;
25044 esac
25045 if $at_failed; then
25046
25047
25048   echo 1 > "$at_status_file"
25049   exit 1
25050 fi
25051
25052 $at_traceon
25053
25054
25055
25056       $at_traceoff
25057       $at_times_p && times >"$at_times_file"
25058     ) 5>&1 2>&1 | eval $at_tee_pipe
25059     at_status=`cat "$at_status_file"`
25060     ;;
25061
25062   64 ) # 64. update.at:27: update unchanged directories
25063     at_setup_line='update.at:27'
25064     at_desc="update unchanged directories"
25065     $at_quiet $ECHO_N " 64: update unchanged directories                   $ECHO_C"
25066     at_xfail=no
25067       test -f $XFAILFILE && at_xfail=yes
25068     echo "#                             -*- compilation -*-" >> "$at_group_log"
25069     (
25070       echo "64. update.at:27: testing ..."
25071       $at_traceon
25072
25073
25074
25075
25076
25077   $at_traceoff
25078 echo "$at_srcdir/update.at:30:
25079 mkdir v7
25080 (cd v7
25081 TEST_TAR_FORMAT=v7
25082 export TEST_TAR_FORMAT
25083 TAR_OPTIONS=\"-H v7\"
25084 export TAR_OPTIONS
25085 rm -rf *
25086
25087
25088 test -z "`sort < /dev/null 2>&1`" || exit 77
25089
25090 mkdir directory
25091 genfile --length 10240 --pattern zeros --file directory/file1
25092 genfile --length 10240 --pattern default --file directory/file2
25093
25094 tar cf archive directory || exit 1
25095 echo separator
25096 tar uf archive directory || exit 1
25097 echo separator
25098 tar tf archive | sort || exit 1
25099 )"
25100 echo update.at:30 >"$at_check_line_file"
25101
25102 at_trace_this=
25103 if test -n "$at_traceon"; then
25104     echo 'Not enabling shell tracing (command contains an embedded newline)'
25105 fi
25106
25107 if test -n "$at_trace_this"; then
25108     ( $at_traceon;
25109 mkdir v7
25110 (cd v7
25111 TEST_TAR_FORMAT=v7
25112 export TEST_TAR_FORMAT
25113 TAR_OPTIONS="-H v7"
25114 export TAR_OPTIONS
25115 rm -rf *
25116
25117
25118 test -z "`sort < /dev/null 2>&1`" || exit 77
25119
25120 mkdir directory
25121 genfile --length 10240 --pattern zeros --file directory/file1
25122 genfile --length 10240 --pattern default --file directory/file2
25123
25124 tar cf archive directory || exit 1
25125 echo separator
25126 tar uf archive directory || exit 1
25127 echo separator
25128 tar tf archive | sort || exit 1
25129 ) ) >"$at_stdout" 2>"$at_stder1"
25130     at_status=$?
25131     grep '^ *+' "$at_stder1" >&2
25132     grep -v '^ *+' "$at_stder1" >"$at_stderr"
25133 else
25134     ( :;
25135 mkdir v7
25136 (cd v7
25137 TEST_TAR_FORMAT=v7
25138 export TEST_TAR_FORMAT
25139 TAR_OPTIONS="-H v7"
25140 export TAR_OPTIONS
25141 rm -rf *
25142
25143
25144 test -z "`sort < /dev/null 2>&1`" || exit 77
25145
25146 mkdir directory
25147 genfile --length 10240 --pattern zeros --file directory/file1
25148 genfile --length 10240 --pattern default --file directory/file2
25149
25150 tar cf archive directory || exit 1
25151 echo separator
25152 tar uf archive directory || exit 1
25153 echo separator
25154 tar tf archive | sort || exit 1
25155 ) ) >"$at_stdout" 2>"$at_stderr"
25156     at_status=$?
25157 fi
25158
25159 at_failed=false
25160 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
25161 echo >>"$at_stdout"; echo "separator
25162 separator
25163 directory/
25164 directory/file1
25165 directory/file2
25166 " | $at_diff - "$at_stdout" || at_failed=:
25167 case $at_status in
25168    77) echo 77 > "$at_status_file"; exit 77;;
25169    0) ;;
25170    *) echo "$at_srcdir/update.at:30: exit code was $at_status, expected 0"
25171       at_failed=:;;
25172 esac
25173 if $at_failed; then
25174
25175
25176   echo 1 > "$at_status_file"
25177   exit 1
25178 fi
25179
25180 $at_traceon
25181 $at_traceoff
25182 echo "$at_srcdir/update.at:30:
25183 mkdir oldgnu
25184 (cd oldgnu
25185 TEST_TAR_FORMAT=oldgnu
25186 export TEST_TAR_FORMAT
25187 TAR_OPTIONS=\"-H oldgnu\"
25188 export TAR_OPTIONS
25189 rm -rf *
25190
25191
25192 test -z "`sort < /dev/null 2>&1`" || exit 77
25193
25194 mkdir directory
25195 genfile --length 10240 --pattern zeros --file directory/file1
25196 genfile --length 10240 --pattern default --file directory/file2
25197
25198 tar cf archive directory || exit 1
25199 echo separator
25200 tar uf archive directory || exit 1
25201 echo separator
25202 tar tf archive | sort || exit 1
25203 )"
25204 echo update.at:30 >"$at_check_line_file"
25205
25206 at_trace_this=
25207 if test -n "$at_traceon"; then
25208     echo 'Not enabling shell tracing (command contains an embedded newline)'
25209 fi
25210
25211 if test -n "$at_trace_this"; then
25212     ( $at_traceon;
25213 mkdir oldgnu
25214 (cd oldgnu
25215 TEST_TAR_FORMAT=oldgnu
25216 export TEST_TAR_FORMAT
25217 TAR_OPTIONS="-H oldgnu"
25218 export TAR_OPTIONS
25219 rm -rf *
25220
25221
25222 test -z "`sort < /dev/null 2>&1`" || exit 77
25223
25224 mkdir directory
25225 genfile --length 10240 --pattern zeros --file directory/file1
25226 genfile --length 10240 --pattern default --file directory/file2
25227
25228 tar cf archive directory || exit 1
25229 echo separator
25230 tar uf archive directory || exit 1
25231 echo separator
25232 tar tf archive | sort || exit 1
25233 ) ) >"$at_stdout" 2>"$at_stder1"
25234     at_status=$?
25235     grep '^ *+' "$at_stder1" >&2
25236     grep -v '^ *+' "$at_stder1" >"$at_stderr"
25237 else
25238     ( :;
25239 mkdir oldgnu
25240 (cd oldgnu
25241 TEST_TAR_FORMAT=oldgnu
25242 export TEST_TAR_FORMAT
25243 TAR_OPTIONS="-H oldgnu"
25244 export TAR_OPTIONS
25245 rm -rf *
25246
25247
25248 test -z "`sort < /dev/null 2>&1`" || exit 77
25249
25250 mkdir directory
25251 genfile --length 10240 --pattern zeros --file directory/file1
25252 genfile --length 10240 --pattern default --file directory/file2
25253
25254 tar cf archive directory || exit 1
25255 echo separator
25256 tar uf archive directory || exit 1
25257 echo separator
25258 tar tf archive | sort || exit 1
25259 ) ) >"$at_stdout" 2>"$at_stderr"
25260     at_status=$?
25261 fi
25262
25263 at_failed=false
25264 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
25265 echo >>"$at_stdout"; echo "separator
25266 separator
25267 directory/
25268 directory/file1
25269 directory/file2
25270 " | $at_diff - "$at_stdout" || at_failed=:
25271 case $at_status in
25272    77) echo 77 > "$at_status_file"; exit 77;;
25273    0) ;;
25274    *) echo "$at_srcdir/update.at:30: exit code was $at_status, expected 0"
25275       at_failed=:;;
25276 esac
25277 if $at_failed; then
25278
25279
25280   echo 1 > "$at_status_file"
25281   exit 1
25282 fi
25283
25284 $at_traceon
25285 $at_traceoff
25286 echo "$at_srcdir/update.at:30:
25287 mkdir ustar
25288 (cd ustar
25289 TEST_TAR_FORMAT=ustar
25290 export TEST_TAR_FORMAT
25291 TAR_OPTIONS=\"-H ustar\"
25292 export TAR_OPTIONS
25293 rm -rf *
25294
25295
25296 test -z "`sort < /dev/null 2>&1`" || exit 77
25297
25298 mkdir directory
25299 genfile --length 10240 --pattern zeros --file directory/file1
25300 genfile --length 10240 --pattern default --file directory/file2
25301
25302 tar cf archive directory || exit 1
25303 echo separator
25304 tar uf archive directory || exit 1
25305 echo separator
25306 tar tf archive | sort || exit 1
25307 )"
25308 echo update.at:30 >"$at_check_line_file"
25309
25310 at_trace_this=
25311 if test -n "$at_traceon"; then
25312     echo 'Not enabling shell tracing (command contains an embedded newline)'
25313 fi
25314
25315 if test -n "$at_trace_this"; then
25316     ( $at_traceon;
25317 mkdir ustar
25318 (cd ustar
25319 TEST_TAR_FORMAT=ustar
25320 export TEST_TAR_FORMAT
25321 TAR_OPTIONS="-H ustar"
25322 export TAR_OPTIONS
25323 rm -rf *
25324
25325
25326 test -z "`sort < /dev/null 2>&1`" || exit 77
25327
25328 mkdir directory
25329 genfile --length 10240 --pattern zeros --file directory/file1
25330 genfile --length 10240 --pattern default --file directory/file2
25331
25332 tar cf archive directory || exit 1
25333 echo separator
25334 tar uf archive directory || exit 1
25335 echo separator
25336 tar tf archive | sort || exit 1
25337 ) ) >"$at_stdout" 2>"$at_stder1"
25338     at_status=$?
25339     grep '^ *+' "$at_stder1" >&2
25340     grep -v '^ *+' "$at_stder1" >"$at_stderr"
25341 else
25342     ( :;
25343 mkdir ustar
25344 (cd ustar
25345 TEST_TAR_FORMAT=ustar
25346 export TEST_TAR_FORMAT
25347 TAR_OPTIONS="-H ustar"
25348 export TAR_OPTIONS
25349 rm -rf *
25350
25351
25352 test -z "`sort < /dev/null 2>&1`" || exit 77
25353
25354 mkdir directory
25355 genfile --length 10240 --pattern zeros --file directory/file1
25356 genfile --length 10240 --pattern default --file directory/file2
25357
25358 tar cf archive directory || exit 1
25359 echo separator
25360 tar uf archive directory || exit 1
25361 echo separator
25362 tar tf archive | sort || exit 1
25363 ) ) >"$at_stdout" 2>"$at_stderr"
25364     at_status=$?
25365 fi
25366
25367 at_failed=false
25368 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
25369 echo >>"$at_stdout"; echo "separator
25370 separator
25371 directory/
25372 directory/file1
25373 directory/file2
25374 " | $at_diff - "$at_stdout" || at_failed=:
25375 case $at_status in
25376    77) echo 77 > "$at_status_file"; exit 77;;
25377    0) ;;
25378    *) echo "$at_srcdir/update.at:30: exit code was $at_status, expected 0"
25379       at_failed=:;;
25380 esac
25381 if $at_failed; then
25382
25383
25384   echo 1 > "$at_status_file"
25385   exit 1
25386 fi
25387
25388 $at_traceon
25389 $at_traceoff
25390 echo "$at_srcdir/update.at:30:
25391 mkdir posix
25392 (cd posix
25393 TEST_TAR_FORMAT=posix
25394 export TEST_TAR_FORMAT
25395 TAR_OPTIONS=\"-H posix\"
25396 export TAR_OPTIONS
25397 rm -rf *
25398
25399
25400 test -z "`sort < /dev/null 2>&1`" || exit 77
25401
25402 mkdir directory
25403 genfile --length 10240 --pattern zeros --file directory/file1
25404 genfile --length 10240 --pattern default --file directory/file2
25405
25406 tar cf archive directory || exit 1
25407 echo separator
25408 tar uf archive directory || exit 1
25409 echo separator
25410 tar tf archive | sort || exit 1
25411 )"
25412 echo update.at:30 >"$at_check_line_file"
25413
25414 at_trace_this=
25415 if test -n "$at_traceon"; then
25416     echo 'Not enabling shell tracing (command contains an embedded newline)'
25417 fi
25418
25419 if test -n "$at_trace_this"; then
25420     ( $at_traceon;
25421 mkdir posix
25422 (cd posix
25423 TEST_TAR_FORMAT=posix
25424 export TEST_TAR_FORMAT
25425 TAR_OPTIONS="-H posix"
25426 export TAR_OPTIONS
25427 rm -rf *
25428
25429
25430 test -z "`sort < /dev/null 2>&1`" || exit 77
25431
25432 mkdir directory
25433 genfile --length 10240 --pattern zeros --file directory/file1
25434 genfile --length 10240 --pattern default --file directory/file2
25435
25436 tar cf archive directory || exit 1
25437 echo separator
25438 tar uf archive directory || exit 1
25439 echo separator
25440 tar tf archive | sort || exit 1
25441 ) ) >"$at_stdout" 2>"$at_stder1"
25442     at_status=$?
25443     grep '^ *+' "$at_stder1" >&2
25444     grep -v '^ *+' "$at_stder1" >"$at_stderr"
25445 else
25446     ( :;
25447 mkdir posix
25448 (cd posix
25449 TEST_TAR_FORMAT=posix
25450 export TEST_TAR_FORMAT
25451 TAR_OPTIONS="-H posix"
25452 export TAR_OPTIONS
25453 rm -rf *
25454
25455
25456 test -z "`sort < /dev/null 2>&1`" || exit 77
25457
25458 mkdir directory
25459 genfile --length 10240 --pattern zeros --file directory/file1
25460 genfile --length 10240 --pattern default --file directory/file2
25461
25462 tar cf archive directory || exit 1
25463 echo separator
25464 tar uf archive directory || exit 1
25465 echo separator
25466 tar tf archive | sort || exit 1
25467 ) ) >"$at_stdout" 2>"$at_stderr"
25468     at_status=$?
25469 fi
25470
25471 at_failed=false
25472 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
25473 echo >>"$at_stdout"; echo "separator
25474 separator
25475 directory/
25476 directory/file1
25477 directory/file2
25478 " | $at_diff - "$at_stdout" || at_failed=:
25479 case $at_status in
25480    77) echo 77 > "$at_status_file"; exit 77;;
25481    0) ;;
25482    *) echo "$at_srcdir/update.at:30: exit code was $at_status, expected 0"
25483       at_failed=:;;
25484 esac
25485 if $at_failed; then
25486
25487
25488   echo 1 > "$at_status_file"
25489   exit 1
25490 fi
25491
25492 $at_traceon
25493 $at_traceoff
25494 echo "$at_srcdir/update.at:30:
25495 mkdir gnu
25496 (cd gnu
25497 TEST_TAR_FORMAT=gnu
25498 export TEST_TAR_FORMAT
25499 TAR_OPTIONS=\"-H gnu\"
25500 export TAR_OPTIONS
25501 rm -rf *
25502
25503
25504 test -z "`sort < /dev/null 2>&1`" || exit 77
25505
25506 mkdir directory
25507 genfile --length 10240 --pattern zeros --file directory/file1
25508 genfile --length 10240 --pattern default --file directory/file2
25509
25510 tar cf archive directory || exit 1
25511 echo separator
25512 tar uf archive directory || exit 1
25513 echo separator
25514 tar tf archive | sort || exit 1
25515 )"
25516 echo update.at:30 >"$at_check_line_file"
25517
25518 at_trace_this=
25519 if test -n "$at_traceon"; then
25520     echo 'Not enabling shell tracing (command contains an embedded newline)'
25521 fi
25522
25523 if test -n "$at_trace_this"; then
25524     ( $at_traceon;
25525 mkdir gnu
25526 (cd gnu
25527 TEST_TAR_FORMAT=gnu
25528 export TEST_TAR_FORMAT
25529 TAR_OPTIONS="-H gnu"
25530 export TAR_OPTIONS
25531 rm -rf *
25532
25533
25534 test -z "`sort < /dev/null 2>&1`" || exit 77
25535
25536 mkdir directory
25537 genfile --length 10240 --pattern zeros --file directory/file1
25538 genfile --length 10240 --pattern default --file directory/file2
25539
25540 tar cf archive directory || exit 1
25541 echo separator
25542 tar uf archive directory || exit 1
25543 echo separator
25544 tar tf archive | sort || exit 1
25545 ) ) >"$at_stdout" 2>"$at_stder1"
25546     at_status=$?
25547     grep '^ *+' "$at_stder1" >&2
25548     grep -v '^ *+' "$at_stder1" >"$at_stderr"
25549 else
25550     ( :;
25551 mkdir gnu
25552 (cd gnu
25553 TEST_TAR_FORMAT=gnu
25554 export TEST_TAR_FORMAT
25555 TAR_OPTIONS="-H gnu"
25556 export TAR_OPTIONS
25557 rm -rf *
25558
25559
25560 test -z "`sort < /dev/null 2>&1`" || exit 77
25561
25562 mkdir directory
25563 genfile --length 10240 --pattern zeros --file directory/file1
25564 genfile --length 10240 --pattern default --file directory/file2
25565
25566 tar cf archive directory || exit 1
25567 echo separator
25568 tar uf archive directory || exit 1
25569 echo separator
25570 tar tf archive | sort || exit 1
25571 ) ) >"$at_stdout" 2>"$at_stderr"
25572     at_status=$?
25573 fi
25574
25575 at_failed=false
25576 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
25577 echo >>"$at_stdout"; echo "separator
25578 separator
25579 directory/
25580 directory/file1
25581 directory/file2
25582 " | $at_diff - "$at_stdout" || at_failed=:
25583 case $at_status in
25584    77) echo 77 > "$at_status_file"; exit 77;;
25585    0) ;;
25586    *) echo "$at_srcdir/update.at:30: exit code was $at_status, expected 0"
25587       at_failed=:;;
25588 esac
25589 if $at_failed; then
25590
25591
25592   echo 1 > "$at_status_file"
25593   exit 1
25594 fi
25595
25596 $at_traceon
25597
25598
25599
25600       $at_traceoff
25601       $at_times_p && times >"$at_times_file"
25602     ) 5>&1 2>&1 | eval $at_tee_pipe
25603     at_status=`cat "$at_status_file"`
25604     ;;
25605
25606   65 ) # 65. volume.at:23: volume
25607     at_setup_line='volume.at:23'
25608     at_desc="volume"
25609     $at_quiet $ECHO_N " 65: volume                                         $ECHO_C"
25610     at_xfail=no
25611       test -f $XFAILFILE && at_xfail=yes
25612     echo "#                             -*- compilation -*-" >> "$at_group_log"
25613     (
25614       echo "65. volume.at:23: testing ..."
25615       $at_traceon
25616
25617
25618
25619
25620
25621   $at_traceoff
25622 echo "$at_srcdir/volume.at:26:
25623 mkdir gnu
25624 (cd gnu
25625 TEST_TAR_FORMAT=gnu
25626 export TEST_TAR_FORMAT
25627 TAR_OPTIONS=\"-H gnu\"
25628 export TAR_OPTIONS
25629 rm -rf *
25630
25631 tar -cf archive -V label -T /dev/null || exit 1
25632
25633 tar xfV archive label || exit 1
25634 tar xfV archive 'la?el' || exit 1
25635 tar xfV archive 'l*l' || exit 1
25636
25637 echo 1>&2 -----
25638 tar xfV archive lab
25639 test \$? = 2 || exit 1
25640 echo 1>&2 -----
25641 tar xfV archive bel
25642 test \$? = 2 || exit 1
25643 echo 1>&2 -----
25644 tar xfV archive babel
25645 test \$? = 2
25646 )"
25647 echo volume.at:26 >"$at_check_line_file"
25648
25649 at_trace_this=
25650 if test -n "$at_traceon"; then
25651     echo 'Not enabling shell tracing (command contains an embedded newline)'
25652 fi
25653
25654 if test -n "$at_trace_this"; then
25655     ( $at_traceon;
25656 mkdir gnu
25657 (cd gnu
25658 TEST_TAR_FORMAT=gnu
25659 export TEST_TAR_FORMAT
25660 TAR_OPTIONS="-H gnu"
25661 export TAR_OPTIONS
25662 rm -rf *
25663
25664 tar -cf archive -V label -T /dev/null || exit 1
25665
25666 tar xfV archive label || exit 1
25667 tar xfV archive 'la?el' || exit 1
25668 tar xfV archive 'l*l' || exit 1
25669
25670 echo 1>&2 -----
25671 tar xfV archive lab
25672 test $? = 2 || exit 1
25673 echo 1>&2 -----
25674 tar xfV archive bel
25675 test $? = 2 || exit 1
25676 echo 1>&2 -----
25677 tar xfV archive babel
25678 test $? = 2
25679 ) ) >"$at_stdout" 2>"$at_stder1"
25680     at_status=$?
25681     grep '^ *+' "$at_stder1" >&2
25682     grep -v '^ *+' "$at_stder1" >"$at_stderr"
25683 else
25684     ( :;
25685 mkdir gnu
25686 (cd gnu
25687 TEST_TAR_FORMAT=gnu
25688 export TEST_TAR_FORMAT
25689 TAR_OPTIONS="-H gnu"
25690 export TAR_OPTIONS
25691 rm -rf *
25692
25693 tar -cf archive -V label -T /dev/null || exit 1
25694
25695 tar xfV archive label || exit 1
25696 tar xfV archive 'la?el' || exit 1
25697 tar xfV archive 'l*l' || exit 1
25698
25699 echo 1>&2 -----
25700 tar xfV archive lab
25701 test $? = 2 || exit 1
25702 echo 1>&2 -----
25703 tar xfV archive bel
25704 test $? = 2 || exit 1
25705 echo 1>&2 -----
25706 tar xfV archive babel
25707 test $? = 2
25708 ) ) >"$at_stdout" 2>"$at_stderr"
25709     at_status=$?
25710 fi
25711
25712 at_failed=false
25713 echo >>"$at_stderr"; echo "-----
25714 tar: Volume \`label' does not match \`lab'
25715 tar: Error is not recoverable: exiting now
25716 -----
25717 tar: Volume \`label' does not match \`bel'
25718 tar: Error is not recoverable: exiting now
25719 -----
25720 tar: Volume \`label' does not match \`babel'
25721 tar: Error is not recoverable: exiting now
25722 " | $at_diff - "$at_stderr" || at_failed=:
25723 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
25724 case $at_status in
25725    77) echo 77 > "$at_status_file"; exit 77;;
25726    0) ;;
25727    *) echo "$at_srcdir/volume.at:26: exit code was $at_status, expected 0"
25728       at_failed=:;;
25729 esac
25730 if $at_failed; then
25731
25732
25733   echo 1 > "$at_status_file"
25734   exit 1
25735 fi
25736
25737 $at_traceon
25738 $at_traceoff
25739 echo "$at_srcdir/volume.at:26:
25740 mkdir oldgnu
25741 (cd oldgnu
25742 TEST_TAR_FORMAT=oldgnu
25743 export TEST_TAR_FORMAT
25744 TAR_OPTIONS=\"-H oldgnu\"
25745 export TAR_OPTIONS
25746 rm -rf *
25747
25748 tar -cf archive -V label -T /dev/null || exit 1
25749
25750 tar xfV archive label || exit 1
25751 tar xfV archive 'la?el' || exit 1
25752 tar xfV archive 'l*l' || exit 1
25753
25754 echo 1>&2 -----
25755 tar xfV archive lab
25756 test \$? = 2 || exit 1
25757 echo 1>&2 -----
25758 tar xfV archive bel
25759 test \$? = 2 || exit 1
25760 echo 1>&2 -----
25761 tar xfV archive babel
25762 test \$? = 2
25763 )"
25764 echo volume.at:26 >"$at_check_line_file"
25765
25766 at_trace_this=
25767 if test -n "$at_traceon"; then
25768     echo 'Not enabling shell tracing (command contains an embedded newline)'
25769 fi
25770
25771 if test -n "$at_trace_this"; then
25772     ( $at_traceon;
25773 mkdir oldgnu
25774 (cd oldgnu
25775 TEST_TAR_FORMAT=oldgnu
25776 export TEST_TAR_FORMAT
25777 TAR_OPTIONS="-H oldgnu"
25778 export TAR_OPTIONS
25779 rm -rf *
25780
25781 tar -cf archive -V label -T /dev/null || exit 1
25782
25783 tar xfV archive label || exit 1
25784 tar xfV archive 'la?el' || exit 1
25785 tar xfV archive 'l*l' || exit 1
25786
25787 echo 1>&2 -----
25788 tar xfV archive lab
25789 test $? = 2 || exit 1
25790 echo 1>&2 -----
25791 tar xfV archive bel
25792 test $? = 2 || exit 1
25793 echo 1>&2 -----
25794 tar xfV archive babel
25795 test $? = 2
25796 ) ) >"$at_stdout" 2>"$at_stder1"
25797     at_status=$?
25798     grep '^ *+' "$at_stder1" >&2
25799     grep -v '^ *+' "$at_stder1" >"$at_stderr"
25800 else
25801     ( :;
25802 mkdir oldgnu
25803 (cd oldgnu
25804 TEST_TAR_FORMAT=oldgnu
25805 export TEST_TAR_FORMAT
25806 TAR_OPTIONS="-H oldgnu"
25807 export TAR_OPTIONS
25808 rm -rf *
25809
25810 tar -cf archive -V label -T /dev/null || exit 1
25811
25812 tar xfV archive label || exit 1
25813 tar xfV archive 'la?el' || exit 1
25814 tar xfV archive 'l*l' || exit 1
25815
25816 echo 1>&2 -----
25817 tar xfV archive lab
25818 test $? = 2 || exit 1
25819 echo 1>&2 -----
25820 tar xfV archive bel
25821 test $? = 2 || exit 1
25822 echo 1>&2 -----
25823 tar xfV archive babel
25824 test $? = 2
25825 ) ) >"$at_stdout" 2>"$at_stderr"
25826     at_status=$?
25827 fi
25828
25829 at_failed=false
25830 echo >>"$at_stderr"; echo "-----
25831 tar: Volume \`label' does not match \`lab'
25832 tar: Error is not recoverable: exiting now
25833 -----
25834 tar: Volume \`label' does not match \`bel'
25835 tar: Error is not recoverable: exiting now
25836 -----
25837 tar: Volume \`label' does not match \`babel'
25838 tar: Error is not recoverable: exiting now
25839 " | $at_diff - "$at_stderr" || at_failed=:
25840 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
25841 case $at_status in
25842    77) echo 77 > "$at_status_file"; exit 77;;
25843    0) ;;
25844    *) echo "$at_srcdir/volume.at:26: exit code was $at_status, expected 0"
25845       at_failed=:;;
25846 esac
25847 if $at_failed; then
25848
25849
25850   echo 1 > "$at_status_file"
25851   exit 1
25852 fi
25853
25854 $at_traceon
25855
25856
25857
25858       $at_traceoff
25859       $at_times_p && times >"$at_times_file"
25860     ) 5>&1 2>&1 | eval $at_tee_pipe
25861     at_status=`cat "$at_status_file"`
25862     ;;
25863
25864   66 ) # 66. volsize.at:29: volume header size
25865     at_setup_line='volsize.at:29'
25866     at_desc="volume header size"
25867     $at_quiet $ECHO_N " 66: volume header size                             $ECHO_C"
25868     at_xfail=no
25869       test -f $XFAILFILE && at_xfail=yes
25870     echo "#                             -*- compilation -*-" >> "$at_group_log"
25871     (
25872       echo "66. volsize.at:29: testing ..."
25873       $at_traceon
25874
25875
25876
25877
25878
25879   $at_traceoff
25880 echo "$at_srcdir/volsize.at:32:
25881 mkdir v7
25882 (cd v7
25883 TEST_TAR_FORMAT=v7
25884 export TEST_TAR_FORMAT
25885 TAR_OPTIONS=\"-H v7\"
25886 export TAR_OPTIONS
25887 rm -rf *
25888
25889
25890 test -z "`sort < /dev/null 2>&1`" || exit 77
25891
25892
25893 test -z "$TEST_DATA_DIR" && exit 77
25894 tarball_prereq abc.tar 540f196ceddcad9e7bd2f2d7533d0474 $TEST_DATA_DIR $TEST_DATA_URL || exit 77
25895
25896 echo Short Listing
25897 tar tf \$TEST_DATA_DIR/abc.tar
25898 echo Verbose Listing
25899 tar --utc -tvf \$TEST_DATA_DIR/abc.tar
25900 echo Extracted directory
25901 tar xf \$TEST_DATA_DIR/abc.tar
25902 find abc|sort
25903 )"
25904 echo volsize.at:32 >"$at_check_line_file"
25905
25906 at_trace_this=
25907 if test -n "$at_traceon"; then
25908     echo 'Not enabling shell tracing (command contains an embedded newline)'
25909 fi
25910
25911 if test -n "$at_trace_this"; then
25912     ( $at_traceon;
25913 mkdir v7
25914 (cd v7
25915 TEST_TAR_FORMAT=v7
25916 export TEST_TAR_FORMAT
25917 TAR_OPTIONS="-H v7"
25918 export TAR_OPTIONS
25919 rm -rf *
25920
25921
25922 test -z "`sort < /dev/null 2>&1`" || exit 77
25923
25924
25925 test -z "$TEST_DATA_DIR" && exit 77
25926 tarball_prereq abc.tar 540f196ceddcad9e7bd2f2d7533d0474 $TEST_DATA_DIR $TEST_DATA_URL || exit 77
25927
25928 echo Short Listing
25929 tar tf $TEST_DATA_DIR/abc.tar
25930 echo Verbose Listing
25931 tar --utc -tvf $TEST_DATA_DIR/abc.tar
25932 echo Extracted directory
25933 tar xf $TEST_DATA_DIR/abc.tar
25934 find abc|sort
25935 ) ) >"$at_stdout" 2>"$at_stder1"
25936     at_status=$?
25937     grep '^ *+' "$at_stder1" >&2
25938     grep -v '^ *+' "$at_stder1" >"$at_stderr"
25939 else
25940     ( :;
25941 mkdir v7
25942 (cd v7
25943 TEST_TAR_FORMAT=v7
25944 export TEST_TAR_FORMAT
25945 TAR_OPTIONS="-H v7"
25946 export TAR_OPTIONS
25947 rm -rf *
25948
25949
25950 test -z "`sort < /dev/null 2>&1`" || exit 77
25951
25952
25953 test -z "$TEST_DATA_DIR" && exit 77
25954 tarball_prereq abc.tar 540f196ceddcad9e7bd2f2d7533d0474 $TEST_DATA_DIR $TEST_DATA_URL || exit 77
25955
25956 echo Short Listing
25957 tar tf $TEST_DATA_DIR/abc.tar
25958 echo Verbose Listing
25959 tar --utc -tvf $TEST_DATA_DIR/abc.tar
25960 echo Extracted directory
25961 tar xf $TEST_DATA_DIR/abc.tar
25962 find abc|sort
25963 ) ) >"$at_stdout" 2>"$at_stderr"
25964     at_status=$?
25965 fi
25966
25967 at_failed=false
25968 echo >>"$at_stderr"; echo "tar: Record size = 5 blocks
25969 tar: Record size = 5 blocks
25970 " | $at_diff - "$at_stderr" || at_failed=:
25971 echo >>"$at_stdout"; echo "Short Listing
25972 abc/not-a-file.gif
25973 abc/CCC
25974 Verbose Listing
25975 V--------- 0/0            1536 2006-05-08 22:07 abc/not-a-file.gif--Volume Header--
25976 -rw-r--r-- tom/users         0 2006-04-22 19:52 abc/CCC
25977 Extracted directory
25978 abc
25979 abc/CCC
25980 " | $at_diff - "$at_stdout" || at_failed=:
25981 case $at_status in
25982    77) echo 77 > "$at_status_file"; exit 77;;
25983    0) ;;
25984    *) echo "$at_srcdir/volsize.at:32: exit code was $at_status, expected 0"
25985       at_failed=:;;
25986 esac
25987 if $at_failed; then
25988
25989
25990   echo 1 > "$at_status_file"
25991   exit 1
25992 fi
25993
25994 $at_traceon
25995 $at_traceoff
25996 echo "$at_srcdir/volsize.at:32:
25997 mkdir oldgnu
25998 (cd oldgnu
25999 TEST_TAR_FORMAT=oldgnu
26000 export TEST_TAR_FORMAT
26001 TAR_OPTIONS=\"-H oldgnu\"
26002 export TAR_OPTIONS
26003 rm -rf *
26004
26005
26006 test -z "`sort < /dev/null 2>&1`" || exit 77
26007
26008
26009 test -z "$TEST_DATA_DIR" && exit 77
26010 tarball_prereq abc.tar 540f196ceddcad9e7bd2f2d7533d0474 $TEST_DATA_DIR $TEST_DATA_URL || exit 77
26011
26012 echo Short Listing
26013 tar tf \$TEST_DATA_DIR/abc.tar
26014 echo Verbose Listing
26015 tar --utc -tvf \$TEST_DATA_DIR/abc.tar
26016 echo Extracted directory
26017 tar xf \$TEST_DATA_DIR/abc.tar
26018 find abc|sort
26019 )"
26020 echo volsize.at:32 >"$at_check_line_file"
26021
26022 at_trace_this=
26023 if test -n "$at_traceon"; then
26024     echo 'Not enabling shell tracing (command contains an embedded newline)'
26025 fi
26026
26027 if test -n "$at_trace_this"; then
26028     ( $at_traceon;
26029 mkdir oldgnu
26030 (cd oldgnu
26031 TEST_TAR_FORMAT=oldgnu
26032 export TEST_TAR_FORMAT
26033 TAR_OPTIONS="-H oldgnu"
26034 export TAR_OPTIONS
26035 rm -rf *
26036
26037
26038 test -z "`sort < /dev/null 2>&1`" || exit 77
26039
26040
26041 test -z "$TEST_DATA_DIR" && exit 77
26042 tarball_prereq abc.tar 540f196ceddcad9e7bd2f2d7533d0474 $TEST_DATA_DIR $TEST_DATA_URL || exit 77
26043
26044 echo Short Listing
26045 tar tf $TEST_DATA_DIR/abc.tar
26046 echo Verbose Listing
26047 tar --utc -tvf $TEST_DATA_DIR/abc.tar
26048 echo Extracted directory
26049 tar xf $TEST_DATA_DIR/abc.tar
26050 find abc|sort
26051 ) ) >"$at_stdout" 2>"$at_stder1"
26052     at_status=$?
26053     grep '^ *+' "$at_stder1" >&2
26054     grep -v '^ *+' "$at_stder1" >"$at_stderr"
26055 else
26056     ( :;
26057 mkdir oldgnu
26058 (cd oldgnu
26059 TEST_TAR_FORMAT=oldgnu
26060 export TEST_TAR_FORMAT
26061 TAR_OPTIONS="-H oldgnu"
26062 export TAR_OPTIONS
26063 rm -rf *
26064
26065
26066 test -z "`sort < /dev/null 2>&1`" || exit 77
26067
26068
26069 test -z "$TEST_DATA_DIR" && exit 77
26070 tarball_prereq abc.tar 540f196ceddcad9e7bd2f2d7533d0474 $TEST_DATA_DIR $TEST_DATA_URL || exit 77
26071
26072 echo Short Listing
26073 tar tf $TEST_DATA_DIR/abc.tar
26074 echo Verbose Listing
26075 tar --utc -tvf $TEST_DATA_DIR/abc.tar
26076 echo Extracted directory
26077 tar xf $TEST_DATA_DIR/abc.tar
26078 find abc|sort
26079 ) ) >"$at_stdout" 2>"$at_stderr"
26080     at_status=$?
26081 fi
26082
26083 at_failed=false
26084 echo >>"$at_stderr"; echo "tar: Record size = 5 blocks
26085 tar: Record size = 5 blocks
26086 " | $at_diff - "$at_stderr" || at_failed=:
26087 echo >>"$at_stdout"; echo "Short Listing
26088 abc/not-a-file.gif
26089 abc/CCC
26090 Verbose Listing
26091 V--------- 0/0            1536 2006-05-08 22:07 abc/not-a-file.gif--Volume Header--
26092 -rw-r--r-- tom/users         0 2006-04-22 19:52 abc/CCC
26093 Extracted directory
26094 abc
26095 abc/CCC
26096 " | $at_diff - "$at_stdout" || at_failed=:
26097 case $at_status in
26098    77) echo 77 > "$at_status_file"; exit 77;;
26099    0) ;;
26100    *) echo "$at_srcdir/volsize.at:32: exit code was $at_status, expected 0"
26101       at_failed=:;;
26102 esac
26103 if $at_failed; then
26104
26105
26106   echo 1 > "$at_status_file"
26107   exit 1
26108 fi
26109
26110 $at_traceon
26111 $at_traceoff
26112 echo "$at_srcdir/volsize.at:32:
26113 mkdir ustar
26114 (cd ustar
26115 TEST_TAR_FORMAT=ustar
26116 export TEST_TAR_FORMAT
26117 TAR_OPTIONS=\"-H ustar\"
26118 export TAR_OPTIONS
26119 rm -rf *
26120
26121
26122 test -z "`sort < /dev/null 2>&1`" || exit 77
26123
26124
26125 test -z "$TEST_DATA_DIR" && exit 77
26126 tarball_prereq abc.tar 540f196ceddcad9e7bd2f2d7533d0474 $TEST_DATA_DIR $TEST_DATA_URL || exit 77
26127
26128 echo Short Listing
26129 tar tf \$TEST_DATA_DIR/abc.tar
26130 echo Verbose Listing
26131 tar --utc -tvf \$TEST_DATA_DIR/abc.tar
26132 echo Extracted directory
26133 tar xf \$TEST_DATA_DIR/abc.tar
26134 find abc|sort
26135 )"
26136 echo volsize.at:32 >"$at_check_line_file"
26137
26138 at_trace_this=
26139 if test -n "$at_traceon"; then
26140     echo 'Not enabling shell tracing (command contains an embedded newline)'
26141 fi
26142
26143 if test -n "$at_trace_this"; then
26144     ( $at_traceon;
26145 mkdir ustar
26146 (cd ustar
26147 TEST_TAR_FORMAT=ustar
26148 export TEST_TAR_FORMAT
26149 TAR_OPTIONS="-H ustar"
26150 export TAR_OPTIONS
26151 rm -rf *
26152
26153
26154 test -z "`sort < /dev/null 2>&1`" || exit 77
26155
26156
26157 test -z "$TEST_DATA_DIR" && exit 77
26158 tarball_prereq abc.tar 540f196ceddcad9e7bd2f2d7533d0474 $TEST_DATA_DIR $TEST_DATA_URL || exit 77
26159
26160 echo Short Listing
26161 tar tf $TEST_DATA_DIR/abc.tar
26162 echo Verbose Listing
26163 tar --utc -tvf $TEST_DATA_DIR/abc.tar
26164 echo Extracted directory
26165 tar xf $TEST_DATA_DIR/abc.tar
26166 find abc|sort
26167 ) ) >"$at_stdout" 2>"$at_stder1"
26168     at_status=$?
26169     grep '^ *+' "$at_stder1" >&2
26170     grep -v '^ *+' "$at_stder1" >"$at_stderr"
26171 else
26172     ( :;
26173 mkdir ustar
26174 (cd ustar
26175 TEST_TAR_FORMAT=ustar
26176 export TEST_TAR_FORMAT
26177 TAR_OPTIONS="-H ustar"
26178 export TAR_OPTIONS
26179 rm -rf *
26180
26181
26182 test -z "`sort < /dev/null 2>&1`" || exit 77
26183
26184
26185 test -z "$TEST_DATA_DIR" && exit 77
26186 tarball_prereq abc.tar 540f196ceddcad9e7bd2f2d7533d0474 $TEST_DATA_DIR $TEST_DATA_URL || exit 77
26187
26188 echo Short Listing
26189 tar tf $TEST_DATA_DIR/abc.tar
26190 echo Verbose Listing
26191 tar --utc -tvf $TEST_DATA_DIR/abc.tar
26192 echo Extracted directory
26193 tar xf $TEST_DATA_DIR/abc.tar
26194 find abc|sort
26195 ) ) >"$at_stdout" 2>"$at_stderr"
26196     at_status=$?
26197 fi
26198
26199 at_failed=false
26200 echo >>"$at_stderr"; echo "tar: Record size = 5 blocks
26201 tar: Record size = 5 blocks
26202 " | $at_diff - "$at_stderr" || at_failed=:
26203 echo >>"$at_stdout"; echo "Short Listing
26204 abc/not-a-file.gif
26205 abc/CCC
26206 Verbose Listing
26207 V--------- 0/0            1536 2006-05-08 22:07 abc/not-a-file.gif--Volume Header--
26208 -rw-r--r-- tom/users         0 2006-04-22 19:52 abc/CCC
26209 Extracted directory
26210 abc
26211 abc/CCC
26212 " | $at_diff - "$at_stdout" || at_failed=:
26213 case $at_status in
26214    77) echo 77 > "$at_status_file"; exit 77;;
26215    0) ;;
26216    *) echo "$at_srcdir/volsize.at:32: exit code was $at_status, expected 0"
26217       at_failed=:;;
26218 esac
26219 if $at_failed; then
26220
26221
26222   echo 1 > "$at_status_file"
26223   exit 1
26224 fi
26225
26226 $at_traceon
26227 $at_traceoff
26228 echo "$at_srcdir/volsize.at:32:
26229 mkdir posix
26230 (cd posix
26231 TEST_TAR_FORMAT=posix
26232 export TEST_TAR_FORMAT
26233 TAR_OPTIONS=\"-H posix\"
26234 export TAR_OPTIONS
26235 rm -rf *
26236
26237
26238 test -z "`sort < /dev/null 2>&1`" || exit 77
26239
26240
26241 test -z "$TEST_DATA_DIR" && exit 77
26242 tarball_prereq abc.tar 540f196ceddcad9e7bd2f2d7533d0474 $TEST_DATA_DIR $TEST_DATA_URL || exit 77
26243
26244 echo Short Listing
26245 tar tf \$TEST_DATA_DIR/abc.tar
26246 echo Verbose Listing
26247 tar --utc -tvf \$TEST_DATA_DIR/abc.tar
26248 echo Extracted directory
26249 tar xf \$TEST_DATA_DIR/abc.tar
26250 find abc|sort
26251 )"
26252 echo volsize.at:32 >"$at_check_line_file"
26253
26254 at_trace_this=
26255 if test -n "$at_traceon"; then
26256     echo 'Not enabling shell tracing (command contains an embedded newline)'
26257 fi
26258
26259 if test -n "$at_trace_this"; then
26260     ( $at_traceon;
26261 mkdir posix
26262 (cd posix
26263 TEST_TAR_FORMAT=posix
26264 export TEST_TAR_FORMAT
26265 TAR_OPTIONS="-H posix"
26266 export TAR_OPTIONS
26267 rm -rf *
26268
26269
26270 test -z "`sort < /dev/null 2>&1`" || exit 77
26271
26272
26273 test -z "$TEST_DATA_DIR" && exit 77
26274 tarball_prereq abc.tar 540f196ceddcad9e7bd2f2d7533d0474 $TEST_DATA_DIR $TEST_DATA_URL || exit 77
26275
26276 echo Short Listing
26277 tar tf $TEST_DATA_DIR/abc.tar
26278 echo Verbose Listing
26279 tar --utc -tvf $TEST_DATA_DIR/abc.tar
26280 echo Extracted directory
26281 tar xf $TEST_DATA_DIR/abc.tar
26282 find abc|sort
26283 ) ) >"$at_stdout" 2>"$at_stder1"
26284     at_status=$?
26285     grep '^ *+' "$at_stder1" >&2
26286     grep -v '^ *+' "$at_stder1" >"$at_stderr"
26287 else
26288     ( :;
26289 mkdir posix
26290 (cd posix
26291 TEST_TAR_FORMAT=posix
26292 export TEST_TAR_FORMAT
26293 TAR_OPTIONS="-H posix"
26294 export TAR_OPTIONS
26295 rm -rf *
26296
26297
26298 test -z "`sort < /dev/null 2>&1`" || exit 77
26299
26300
26301 test -z "$TEST_DATA_DIR" && exit 77
26302 tarball_prereq abc.tar 540f196ceddcad9e7bd2f2d7533d0474 $TEST_DATA_DIR $TEST_DATA_URL || exit 77
26303
26304 echo Short Listing
26305 tar tf $TEST_DATA_DIR/abc.tar
26306 echo Verbose Listing
26307 tar --utc -tvf $TEST_DATA_DIR/abc.tar
26308 echo Extracted directory
26309 tar xf $TEST_DATA_DIR/abc.tar
26310 find abc|sort
26311 ) ) >"$at_stdout" 2>"$at_stderr"
26312     at_status=$?
26313 fi
26314
26315 at_failed=false
26316 echo >>"$at_stderr"; echo "tar: Record size = 5 blocks
26317 tar: Record size = 5 blocks
26318 " | $at_diff - "$at_stderr" || at_failed=:
26319 echo >>"$at_stdout"; echo "Short Listing
26320 abc/not-a-file.gif
26321 abc/CCC
26322 Verbose Listing
26323 V--------- 0/0            1536 2006-05-08 22:07 abc/not-a-file.gif--Volume Header--
26324 -rw-r--r-- tom/users         0 2006-04-22 19:52 abc/CCC
26325 Extracted directory
26326 abc
26327 abc/CCC
26328 " | $at_diff - "$at_stdout" || at_failed=:
26329 case $at_status in
26330    77) echo 77 > "$at_status_file"; exit 77;;
26331    0) ;;
26332    *) echo "$at_srcdir/volsize.at:32: exit code was $at_status, expected 0"
26333       at_failed=:;;
26334 esac
26335 if $at_failed; then
26336
26337
26338   echo 1 > "$at_status_file"
26339   exit 1
26340 fi
26341
26342 $at_traceon
26343 $at_traceoff
26344 echo "$at_srcdir/volsize.at:32:
26345 mkdir gnu
26346 (cd gnu
26347 TEST_TAR_FORMAT=gnu
26348 export TEST_TAR_FORMAT
26349 TAR_OPTIONS=\"-H gnu\"
26350 export TAR_OPTIONS
26351 rm -rf *
26352
26353
26354 test -z "`sort < /dev/null 2>&1`" || exit 77
26355
26356
26357 test -z "$TEST_DATA_DIR" && exit 77
26358 tarball_prereq abc.tar 540f196ceddcad9e7bd2f2d7533d0474 $TEST_DATA_DIR $TEST_DATA_URL || exit 77
26359
26360 echo Short Listing
26361 tar tf \$TEST_DATA_DIR/abc.tar
26362 echo Verbose Listing
26363 tar --utc -tvf \$TEST_DATA_DIR/abc.tar
26364 echo Extracted directory
26365 tar xf \$TEST_DATA_DIR/abc.tar
26366 find abc|sort
26367 )"
26368 echo volsize.at:32 >"$at_check_line_file"
26369
26370 at_trace_this=
26371 if test -n "$at_traceon"; then
26372     echo 'Not enabling shell tracing (command contains an embedded newline)'
26373 fi
26374
26375 if test -n "$at_trace_this"; then
26376     ( $at_traceon;
26377 mkdir gnu
26378 (cd gnu
26379 TEST_TAR_FORMAT=gnu
26380 export TEST_TAR_FORMAT
26381 TAR_OPTIONS="-H gnu"
26382 export TAR_OPTIONS
26383 rm -rf *
26384
26385
26386 test -z "`sort < /dev/null 2>&1`" || exit 77
26387
26388
26389 test -z "$TEST_DATA_DIR" && exit 77
26390 tarball_prereq abc.tar 540f196ceddcad9e7bd2f2d7533d0474 $TEST_DATA_DIR $TEST_DATA_URL || exit 77
26391
26392 echo Short Listing
26393 tar tf $TEST_DATA_DIR/abc.tar
26394 echo Verbose Listing
26395 tar --utc -tvf $TEST_DATA_DIR/abc.tar
26396 echo Extracted directory
26397 tar xf $TEST_DATA_DIR/abc.tar
26398 find abc|sort
26399 ) ) >"$at_stdout" 2>"$at_stder1"
26400     at_status=$?
26401     grep '^ *+' "$at_stder1" >&2
26402     grep -v '^ *+' "$at_stder1" >"$at_stderr"
26403 else
26404     ( :;
26405 mkdir gnu
26406 (cd gnu
26407 TEST_TAR_FORMAT=gnu
26408 export TEST_TAR_FORMAT
26409 TAR_OPTIONS="-H gnu"
26410 export TAR_OPTIONS
26411 rm -rf *
26412
26413
26414 test -z "`sort < /dev/null 2>&1`" || exit 77
26415
26416
26417 test -z "$TEST_DATA_DIR" && exit 77
26418 tarball_prereq abc.tar 540f196ceddcad9e7bd2f2d7533d0474 $TEST_DATA_DIR $TEST_DATA_URL || exit 77
26419
26420 echo Short Listing
26421 tar tf $TEST_DATA_DIR/abc.tar
26422 echo Verbose Listing
26423 tar --utc -tvf $TEST_DATA_DIR/abc.tar
26424 echo Extracted directory
26425 tar xf $TEST_DATA_DIR/abc.tar
26426 find abc|sort
26427 ) ) >"$at_stdout" 2>"$at_stderr"
26428     at_status=$?
26429 fi
26430
26431 at_failed=false
26432 echo >>"$at_stderr"; echo "tar: Record size = 5 blocks
26433 tar: Record size = 5 blocks
26434 " | $at_diff - "$at_stderr" || at_failed=:
26435 echo >>"$at_stdout"; echo "Short Listing
26436 abc/not-a-file.gif
26437 abc/CCC
26438 Verbose Listing
26439 V--------- 0/0            1536 2006-05-08 22:07 abc/not-a-file.gif--Volume Header--
26440 -rw-r--r-- tom/users         0 2006-04-22 19:52 abc/CCC
26441 Extracted directory
26442 abc
26443 abc/CCC
26444 " | $at_diff - "$at_stdout" || at_failed=:
26445 case $at_status in
26446    77) echo 77 > "$at_status_file"; exit 77;;
26447    0) ;;
26448    *) echo "$at_srcdir/volsize.at:32: exit code was $at_status, expected 0"
26449       at_failed=:;;
26450 esac
26451 if $at_failed; then
26452
26453
26454   echo 1 > "$at_status_file"
26455   exit 1
26456 fi
26457
26458 $at_traceon
26459
26460
26461
26462       $at_traceoff
26463       $at_times_p && times >"$at_times_file"
26464     ) 5>&1 2>&1 | eval $at_tee_pipe
26465     at_status=`cat "$at_status_file"`
26466     ;;
26467
26468   67 ) # 67. comprec.at:21: compressed format recognition
26469     at_setup_line='comprec.at:21'
26470     at_desc="compressed format recognition"
26471     $at_quiet $ECHO_N " 67: compressed format recognition                  $ECHO_C"
26472     at_xfail=no
26473       test -f $XFAILFILE && at_xfail=yes
26474     echo "#                             -*- compilation -*-" >> "$at_group_log"
26475     (
26476       echo "67. comprec.at:21: testing ..."
26477       $at_traceon
26478
26479
26480
26481
26482
26483
26484   $at_traceoff
26485 echo "$at_srcdir/comprec.at:25:
26486 mkdir v7
26487 (cd v7
26488 TEST_TAR_FORMAT=v7
26489 export TEST_TAR_FORMAT
26490 TAR_OPTIONS=\"-H v7\"
26491 export TAR_OPTIONS
26492 rm -rf *
26493
26494
26495 cat /dev/null | gzip - > /dev/null 2>&1 || exit 77
26496
26497 genfile --length 10240 --file file1
26498 echo \"separator\"
26499 tar cfz archive file1
26500 echo \"separator\"
26501 mv file1 orig
26502 tar xfv archive
26503 cmp orig file1
26504 )"
26505 echo comprec.at:25 >"$at_check_line_file"
26506
26507 at_trace_this=
26508 if test -n "$at_traceon"; then
26509     echo 'Not enabling shell tracing (command contains an embedded newline)'
26510 fi
26511
26512 if test -n "$at_trace_this"; then
26513     ( $at_traceon;
26514 mkdir v7
26515 (cd v7
26516 TEST_TAR_FORMAT=v7
26517 export TEST_TAR_FORMAT
26518 TAR_OPTIONS="-H v7"
26519 export TAR_OPTIONS
26520 rm -rf *
26521
26522
26523 cat /dev/null | gzip - > /dev/null 2>&1 || exit 77
26524
26525 genfile --length 10240 --file file1
26526 echo "separator"
26527 tar cfz archive file1
26528 echo "separator"
26529 mv file1 orig
26530 tar xfv archive
26531 cmp orig file1
26532 ) ) >"$at_stdout" 2>"$at_stder1"
26533     at_status=$?
26534     grep '^ *+' "$at_stder1" >&2
26535     grep -v '^ *+' "$at_stder1" >"$at_stderr"
26536 else
26537     ( :;
26538 mkdir v7
26539 (cd v7
26540 TEST_TAR_FORMAT=v7
26541 export TEST_TAR_FORMAT
26542 TAR_OPTIONS="-H v7"
26543 export TAR_OPTIONS
26544 rm -rf *
26545
26546
26547 cat /dev/null | gzip - > /dev/null 2>&1 || exit 77
26548
26549 genfile --length 10240 --file file1
26550 echo "separator"
26551 tar cfz archive file1
26552 echo "separator"
26553 mv file1 orig
26554 tar xfv archive
26555 cmp orig file1
26556 ) ) >"$at_stdout" 2>"$at_stderr"
26557     at_status=$?
26558 fi
26559
26560 at_failed=false
26561 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
26562 echo >>"$at_stdout"; echo "separator
26563 separator
26564 file1
26565 " | $at_diff - "$at_stdout" || at_failed=:
26566 case $at_status in
26567    77) echo 77 > "$at_status_file"; exit 77;;
26568    0) ;;
26569    *) echo "$at_srcdir/comprec.at:25: exit code was $at_status, expected 0"
26570       at_failed=:;;
26571 esac
26572 if $at_failed; then
26573
26574
26575   echo 1 > "$at_status_file"
26576   exit 1
26577 fi
26578
26579 $at_traceon
26580 $at_traceoff
26581 echo "$at_srcdir/comprec.at:25:
26582 mkdir oldgnu
26583 (cd oldgnu
26584 TEST_TAR_FORMAT=oldgnu
26585 export TEST_TAR_FORMAT
26586 TAR_OPTIONS=\"-H oldgnu\"
26587 export TAR_OPTIONS
26588 rm -rf *
26589
26590
26591 cat /dev/null | gzip - > /dev/null 2>&1 || exit 77
26592
26593 genfile --length 10240 --file file1
26594 echo \"separator\"
26595 tar cfz archive file1
26596 echo \"separator\"
26597 mv file1 orig
26598 tar xfv archive
26599 cmp orig file1
26600 )"
26601 echo comprec.at:25 >"$at_check_line_file"
26602
26603 at_trace_this=
26604 if test -n "$at_traceon"; then
26605     echo 'Not enabling shell tracing (command contains an embedded newline)'
26606 fi
26607
26608 if test -n "$at_trace_this"; then
26609     ( $at_traceon;
26610 mkdir oldgnu
26611 (cd oldgnu
26612 TEST_TAR_FORMAT=oldgnu
26613 export TEST_TAR_FORMAT
26614 TAR_OPTIONS="-H oldgnu"
26615 export TAR_OPTIONS
26616 rm -rf *
26617
26618
26619 cat /dev/null | gzip - > /dev/null 2>&1 || exit 77
26620
26621 genfile --length 10240 --file file1
26622 echo "separator"
26623 tar cfz archive file1
26624 echo "separator"
26625 mv file1 orig
26626 tar xfv archive
26627 cmp orig file1
26628 ) ) >"$at_stdout" 2>"$at_stder1"
26629     at_status=$?
26630     grep '^ *+' "$at_stder1" >&2
26631     grep -v '^ *+' "$at_stder1" >"$at_stderr"
26632 else
26633     ( :;
26634 mkdir oldgnu
26635 (cd oldgnu
26636 TEST_TAR_FORMAT=oldgnu
26637 export TEST_TAR_FORMAT
26638 TAR_OPTIONS="-H oldgnu"
26639 export TAR_OPTIONS
26640 rm -rf *
26641
26642
26643 cat /dev/null | gzip - > /dev/null 2>&1 || exit 77
26644
26645 genfile --length 10240 --file file1
26646 echo "separator"
26647 tar cfz archive file1
26648 echo "separator"
26649 mv file1 orig
26650 tar xfv archive
26651 cmp orig file1
26652 ) ) >"$at_stdout" 2>"$at_stderr"
26653     at_status=$?
26654 fi
26655
26656 at_failed=false
26657 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
26658 echo >>"$at_stdout"; echo "separator
26659 separator
26660 file1
26661 " | $at_diff - "$at_stdout" || at_failed=:
26662 case $at_status in
26663    77) echo 77 > "$at_status_file"; exit 77;;
26664    0) ;;
26665    *) echo "$at_srcdir/comprec.at:25: exit code was $at_status, expected 0"
26666       at_failed=:;;
26667 esac
26668 if $at_failed; then
26669
26670
26671   echo 1 > "$at_status_file"
26672   exit 1
26673 fi
26674
26675 $at_traceon
26676 $at_traceoff
26677 echo "$at_srcdir/comprec.at:25:
26678 mkdir ustar
26679 (cd ustar
26680 TEST_TAR_FORMAT=ustar
26681 export TEST_TAR_FORMAT
26682 TAR_OPTIONS=\"-H ustar\"
26683 export TAR_OPTIONS
26684 rm -rf *
26685
26686
26687 cat /dev/null | gzip - > /dev/null 2>&1 || exit 77
26688
26689 genfile --length 10240 --file file1
26690 echo \"separator\"
26691 tar cfz archive file1
26692 echo \"separator\"
26693 mv file1 orig
26694 tar xfv archive
26695 cmp orig file1
26696 )"
26697 echo comprec.at:25 >"$at_check_line_file"
26698
26699 at_trace_this=
26700 if test -n "$at_traceon"; then
26701     echo 'Not enabling shell tracing (command contains an embedded newline)'
26702 fi
26703
26704 if test -n "$at_trace_this"; then
26705     ( $at_traceon;
26706 mkdir ustar
26707 (cd ustar
26708 TEST_TAR_FORMAT=ustar
26709 export TEST_TAR_FORMAT
26710 TAR_OPTIONS="-H ustar"
26711 export TAR_OPTIONS
26712 rm -rf *
26713
26714
26715 cat /dev/null | gzip - > /dev/null 2>&1 || exit 77
26716
26717 genfile --length 10240 --file file1
26718 echo "separator"
26719 tar cfz archive file1
26720 echo "separator"
26721 mv file1 orig
26722 tar xfv archive
26723 cmp orig file1
26724 ) ) >"$at_stdout" 2>"$at_stder1"
26725     at_status=$?
26726     grep '^ *+' "$at_stder1" >&2
26727     grep -v '^ *+' "$at_stder1" >"$at_stderr"
26728 else
26729     ( :;
26730 mkdir ustar
26731 (cd ustar
26732 TEST_TAR_FORMAT=ustar
26733 export TEST_TAR_FORMAT
26734 TAR_OPTIONS="-H ustar"
26735 export TAR_OPTIONS
26736 rm -rf *
26737
26738
26739 cat /dev/null | gzip - > /dev/null 2>&1 || exit 77
26740
26741 genfile --length 10240 --file file1
26742 echo "separator"
26743 tar cfz archive file1
26744 echo "separator"
26745 mv file1 orig
26746 tar xfv archive
26747 cmp orig file1
26748 ) ) >"$at_stdout" 2>"$at_stderr"
26749     at_status=$?
26750 fi
26751
26752 at_failed=false
26753 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
26754 echo >>"$at_stdout"; echo "separator
26755 separator
26756 file1
26757 " | $at_diff - "$at_stdout" || at_failed=:
26758 case $at_status in
26759    77) echo 77 > "$at_status_file"; exit 77;;
26760    0) ;;
26761    *) echo "$at_srcdir/comprec.at:25: exit code was $at_status, expected 0"
26762       at_failed=:;;
26763 esac
26764 if $at_failed; then
26765
26766
26767   echo 1 > "$at_status_file"
26768   exit 1
26769 fi
26770
26771 $at_traceon
26772 $at_traceoff
26773 echo "$at_srcdir/comprec.at:25:
26774 mkdir posix
26775 (cd posix
26776 TEST_TAR_FORMAT=posix
26777 export TEST_TAR_FORMAT
26778 TAR_OPTIONS=\"-H posix\"
26779 export TAR_OPTIONS
26780 rm -rf *
26781
26782
26783 cat /dev/null | gzip - > /dev/null 2>&1 || exit 77
26784
26785 genfile --length 10240 --file file1
26786 echo \"separator\"
26787 tar cfz archive file1
26788 echo \"separator\"
26789 mv file1 orig
26790 tar xfv archive
26791 cmp orig file1
26792 )"
26793 echo comprec.at:25 >"$at_check_line_file"
26794
26795 at_trace_this=
26796 if test -n "$at_traceon"; then
26797     echo 'Not enabling shell tracing (command contains an embedded newline)'
26798 fi
26799
26800 if test -n "$at_trace_this"; then
26801     ( $at_traceon;
26802 mkdir posix
26803 (cd posix
26804 TEST_TAR_FORMAT=posix
26805 export TEST_TAR_FORMAT
26806 TAR_OPTIONS="-H posix"
26807 export TAR_OPTIONS
26808 rm -rf *
26809
26810
26811 cat /dev/null | gzip - > /dev/null 2>&1 || exit 77
26812
26813 genfile --length 10240 --file file1
26814 echo "separator"
26815 tar cfz archive file1
26816 echo "separator"
26817 mv file1 orig
26818 tar xfv archive
26819 cmp orig file1
26820 ) ) >"$at_stdout" 2>"$at_stder1"
26821     at_status=$?
26822     grep '^ *+' "$at_stder1" >&2
26823     grep -v '^ *+' "$at_stder1" >"$at_stderr"
26824 else
26825     ( :;
26826 mkdir posix
26827 (cd posix
26828 TEST_TAR_FORMAT=posix
26829 export TEST_TAR_FORMAT
26830 TAR_OPTIONS="-H posix"
26831 export TAR_OPTIONS
26832 rm -rf *
26833
26834
26835 cat /dev/null | gzip - > /dev/null 2>&1 || exit 77
26836
26837 genfile --length 10240 --file file1
26838 echo "separator"
26839 tar cfz archive file1
26840 echo "separator"
26841 mv file1 orig
26842 tar xfv archive
26843 cmp orig file1
26844 ) ) >"$at_stdout" 2>"$at_stderr"
26845     at_status=$?
26846 fi
26847
26848 at_failed=false
26849 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
26850 echo >>"$at_stdout"; echo "separator
26851 separator
26852 file1
26853 " | $at_diff - "$at_stdout" || at_failed=:
26854 case $at_status in
26855    77) echo 77 > "$at_status_file"; exit 77;;
26856    0) ;;
26857    *) echo "$at_srcdir/comprec.at:25: exit code was $at_status, expected 0"
26858       at_failed=:;;
26859 esac
26860 if $at_failed; then
26861
26862
26863   echo 1 > "$at_status_file"
26864   exit 1
26865 fi
26866
26867 $at_traceon
26868 $at_traceoff
26869 echo "$at_srcdir/comprec.at:25:
26870 mkdir gnu
26871 (cd gnu
26872 TEST_TAR_FORMAT=gnu
26873 export TEST_TAR_FORMAT
26874 TAR_OPTIONS=\"-H gnu\"
26875 export TAR_OPTIONS
26876 rm -rf *
26877
26878
26879 cat /dev/null | gzip - > /dev/null 2>&1 || exit 77
26880
26881 genfile --length 10240 --file file1
26882 echo \"separator\"
26883 tar cfz archive file1
26884 echo \"separator\"
26885 mv file1 orig
26886 tar xfv archive
26887 cmp orig file1
26888 )"
26889 echo comprec.at:25 >"$at_check_line_file"
26890
26891 at_trace_this=
26892 if test -n "$at_traceon"; then
26893     echo 'Not enabling shell tracing (command contains an embedded newline)'
26894 fi
26895
26896 if test -n "$at_trace_this"; then
26897     ( $at_traceon;
26898 mkdir gnu
26899 (cd gnu
26900 TEST_TAR_FORMAT=gnu
26901 export TEST_TAR_FORMAT
26902 TAR_OPTIONS="-H gnu"
26903 export TAR_OPTIONS
26904 rm -rf *
26905
26906
26907 cat /dev/null | gzip - > /dev/null 2>&1 || exit 77
26908
26909 genfile --length 10240 --file file1
26910 echo "separator"
26911 tar cfz archive file1
26912 echo "separator"
26913 mv file1 orig
26914 tar xfv archive
26915 cmp orig file1
26916 ) ) >"$at_stdout" 2>"$at_stder1"
26917     at_status=$?
26918     grep '^ *+' "$at_stder1" >&2
26919     grep -v '^ *+' "$at_stder1" >"$at_stderr"
26920 else
26921     ( :;
26922 mkdir gnu
26923 (cd gnu
26924 TEST_TAR_FORMAT=gnu
26925 export TEST_TAR_FORMAT
26926 TAR_OPTIONS="-H gnu"
26927 export TAR_OPTIONS
26928 rm -rf *
26929
26930
26931 cat /dev/null | gzip - > /dev/null 2>&1 || exit 77
26932
26933 genfile --length 10240 --file file1
26934 echo "separator"
26935 tar cfz archive file1
26936 echo "separator"
26937 mv file1 orig
26938 tar xfv archive
26939 cmp orig file1
26940 ) ) >"$at_stdout" 2>"$at_stderr"
26941     at_status=$?
26942 fi
26943
26944 at_failed=false
26945 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
26946 echo >>"$at_stdout"; echo "separator
26947 separator
26948 file1
26949 " | $at_diff - "$at_stdout" || at_failed=:
26950 case $at_status in
26951    77) echo 77 > "$at_status_file"; exit 77;;
26952    0) ;;
26953    *) echo "$at_srcdir/comprec.at:25: exit code was $at_status, expected 0"
26954       at_failed=:;;
26955 esac
26956 if $at_failed; then
26957
26958
26959   echo 1 > "$at_status_file"
26960   exit 1
26961 fi
26962
26963 $at_traceon
26964
26965
26966
26967       $at_traceoff
26968       $at_times_p && times >"$at_times_file"
26969     ) 5>&1 2>&1 | eval $at_tee_pipe
26970     at_status=`cat "$at_status_file"`
26971     ;;
26972
26973   68 ) # 68. shortfile.at:26: short input files
26974     at_setup_line='shortfile.at:26'
26975     at_desc="short input files"
26976     $at_quiet $ECHO_N " 68: short input files                              $ECHO_C"
26977     at_xfail=no
26978       test -f $XFAILFILE && at_xfail=yes
26979     echo "#                             -*- compilation -*-" >> "$at_group_log"
26980     (
26981       echo "68. shortfile.at:26: testing ..."
26982       $at_traceon
26983
26984
26985
26986
26987
26988   $at_traceoff
26989 echo "$at_srcdir/shortfile.at:29:
26990 mkdir gnu
26991 (cd gnu
26992 TEST_TAR_FORMAT=gnu
26993 export TEST_TAR_FORMAT
26994 TAR_OPTIONS=\"-H gnu\"
26995 export TAR_OPTIONS
26996 rm -rf *
26997
26998 genfile --length 511 --file foo || exit 5
26999 tar tf foo
27000 )"
27001 echo shortfile.at:29 >"$at_check_line_file"
27002
27003 at_trace_this=
27004 if test -n "$at_traceon"; then
27005     echo 'Not enabling shell tracing (command contains an embedded newline)'
27006 fi
27007
27008 if test -n "$at_trace_this"; then
27009     ( $at_traceon;
27010 mkdir gnu
27011 (cd gnu
27012 TEST_TAR_FORMAT=gnu
27013 export TEST_TAR_FORMAT
27014 TAR_OPTIONS="-H gnu"
27015 export TAR_OPTIONS
27016 rm -rf *
27017
27018 genfile --length 511 --file foo || exit 5
27019 tar tf foo
27020 ) ) >"$at_stdout" 2>"$at_stder1"
27021     at_status=$?
27022     grep '^ *+' "$at_stder1" >&2
27023     grep -v '^ *+' "$at_stder1" >"$at_stderr"
27024 else
27025     ( :;
27026 mkdir gnu
27027 (cd gnu
27028 TEST_TAR_FORMAT=gnu
27029 export TEST_TAR_FORMAT
27030 TAR_OPTIONS="-H gnu"
27031 export TAR_OPTIONS
27032 rm -rf *
27033
27034 genfile --length 511 --file foo || exit 5
27035 tar tf foo
27036 ) ) >"$at_stdout" 2>"$at_stderr"
27037     at_status=$?
27038 fi
27039
27040 at_failed=false
27041 echo >>"$at_stderr"; echo "tar: This does not look like a tar archive
27042 tar: Exiting with failure status due to previous errors
27043 " | $at_diff - "$at_stderr" || at_failed=:
27044 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
27045 case $at_status in
27046    77) echo 77 > "$at_status_file"; exit 77;;
27047    2) ;;
27048    *) echo "$at_srcdir/shortfile.at:29: exit code was $at_status, expected 2"
27049       at_failed=:;;
27050 esac
27051 if $at_failed; then
27052
27053
27054   echo 1 > "$at_status_file"
27055   exit 1
27056 fi
27057
27058 $at_traceon
27059
27060
27061
27062       $at_traceoff
27063       $at_times_p && times >"$at_times_file"
27064     ) 5>&1 2>&1 | eval $at_tee_pipe
27065     at_status=`cat "$at_status_file"`
27066     ;;
27067
27068   69 ) # 69. shortupd.at:29: updating short archives
27069     at_setup_line='shortupd.at:29'
27070     at_desc="updating short archives"
27071     $at_quiet $ECHO_N " 69: updating short archives                        $ECHO_C"
27072     at_xfail=no
27073       test -f $XFAILFILE && at_xfail=yes
27074     echo "#                             -*- compilation -*-" >> "$at_group_log"
27075     (
27076       echo "69. shortupd.at:29: testing ..."
27077       $at_traceon
27078
27079
27080
27081
27082
27083   $at_traceoff
27084 echo "$at_srcdir/shortupd.at:32:
27085 mkdir v7
27086 (cd v7
27087 TEST_TAR_FORMAT=v7
27088 export TEST_TAR_FORMAT
27089 TAR_OPTIONS=\"-H v7\"
27090 export TAR_OPTIONS
27091 rm -rf *
27092
27093 touch foo
27094 tar uf archive foo
27095 )"
27096 echo shortupd.at:32 >"$at_check_line_file"
27097
27098 at_trace_this=
27099 if test -n "$at_traceon"; then
27100     echo 'Not enabling shell tracing (command contains an embedded newline)'
27101 fi
27102
27103 if test -n "$at_trace_this"; then
27104     ( $at_traceon;
27105 mkdir v7
27106 (cd v7
27107 TEST_TAR_FORMAT=v7
27108 export TEST_TAR_FORMAT
27109 TAR_OPTIONS="-H v7"
27110 export TAR_OPTIONS
27111 rm -rf *
27112
27113 touch foo
27114 tar uf archive foo
27115 ) ) >"$at_stdout" 2>"$at_stder1"
27116     at_status=$?
27117     grep '^ *+' "$at_stder1" >&2
27118     grep -v '^ *+' "$at_stder1" >"$at_stderr"
27119 else
27120     ( :;
27121 mkdir v7
27122 (cd v7
27123 TEST_TAR_FORMAT=v7
27124 export TEST_TAR_FORMAT
27125 TAR_OPTIONS="-H v7"
27126 export TAR_OPTIONS
27127 rm -rf *
27128
27129 touch foo
27130 tar uf archive foo
27131 ) ) >"$at_stdout" 2>"$at_stderr"
27132     at_status=$?
27133 fi
27134
27135 at_failed=false
27136 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
27137 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
27138 case $at_status in
27139    77) echo 77 > "$at_status_file"; exit 77;;
27140    0) ;;
27141    *) echo "$at_srcdir/shortupd.at:32: exit code was $at_status, expected 0"
27142       at_failed=:;;
27143 esac
27144 if $at_failed; then
27145
27146
27147   echo 1 > "$at_status_file"
27148   exit 1
27149 fi
27150
27151 $at_traceon
27152 $at_traceoff
27153 echo "$at_srcdir/shortupd.at:32:
27154 mkdir oldgnu
27155 (cd oldgnu
27156 TEST_TAR_FORMAT=oldgnu
27157 export TEST_TAR_FORMAT
27158 TAR_OPTIONS=\"-H oldgnu\"
27159 export TAR_OPTIONS
27160 rm -rf *
27161
27162 touch foo
27163 tar uf archive foo
27164 )"
27165 echo shortupd.at:32 >"$at_check_line_file"
27166
27167 at_trace_this=
27168 if test -n "$at_traceon"; then
27169     echo 'Not enabling shell tracing (command contains an embedded newline)'
27170 fi
27171
27172 if test -n "$at_trace_this"; then
27173     ( $at_traceon;
27174 mkdir oldgnu
27175 (cd oldgnu
27176 TEST_TAR_FORMAT=oldgnu
27177 export TEST_TAR_FORMAT
27178 TAR_OPTIONS="-H oldgnu"
27179 export TAR_OPTIONS
27180 rm -rf *
27181
27182 touch foo
27183 tar uf archive foo
27184 ) ) >"$at_stdout" 2>"$at_stder1"
27185     at_status=$?
27186     grep '^ *+' "$at_stder1" >&2
27187     grep -v '^ *+' "$at_stder1" >"$at_stderr"
27188 else
27189     ( :;
27190 mkdir oldgnu
27191 (cd oldgnu
27192 TEST_TAR_FORMAT=oldgnu
27193 export TEST_TAR_FORMAT
27194 TAR_OPTIONS="-H oldgnu"
27195 export TAR_OPTIONS
27196 rm -rf *
27197
27198 touch foo
27199 tar uf archive foo
27200 ) ) >"$at_stdout" 2>"$at_stderr"
27201     at_status=$?
27202 fi
27203
27204 at_failed=false
27205 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
27206 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
27207 case $at_status in
27208    77) echo 77 > "$at_status_file"; exit 77;;
27209    0) ;;
27210    *) echo "$at_srcdir/shortupd.at:32: exit code was $at_status, expected 0"
27211       at_failed=:;;
27212 esac
27213 if $at_failed; then
27214
27215
27216   echo 1 > "$at_status_file"
27217   exit 1
27218 fi
27219
27220 $at_traceon
27221 $at_traceoff
27222 echo "$at_srcdir/shortupd.at:32:
27223 mkdir ustar
27224 (cd ustar
27225 TEST_TAR_FORMAT=ustar
27226 export TEST_TAR_FORMAT
27227 TAR_OPTIONS=\"-H ustar\"
27228 export TAR_OPTIONS
27229 rm -rf *
27230
27231 touch foo
27232 tar uf archive foo
27233 )"
27234 echo shortupd.at:32 >"$at_check_line_file"
27235
27236 at_trace_this=
27237 if test -n "$at_traceon"; then
27238     echo 'Not enabling shell tracing (command contains an embedded newline)'
27239 fi
27240
27241 if test -n "$at_trace_this"; then
27242     ( $at_traceon;
27243 mkdir ustar
27244 (cd ustar
27245 TEST_TAR_FORMAT=ustar
27246 export TEST_TAR_FORMAT
27247 TAR_OPTIONS="-H ustar"
27248 export TAR_OPTIONS
27249 rm -rf *
27250
27251 touch foo
27252 tar uf archive foo
27253 ) ) >"$at_stdout" 2>"$at_stder1"
27254     at_status=$?
27255     grep '^ *+' "$at_stder1" >&2
27256     grep -v '^ *+' "$at_stder1" >"$at_stderr"
27257 else
27258     ( :;
27259 mkdir ustar
27260 (cd ustar
27261 TEST_TAR_FORMAT=ustar
27262 export TEST_TAR_FORMAT
27263 TAR_OPTIONS="-H ustar"
27264 export TAR_OPTIONS
27265 rm -rf *
27266
27267 touch foo
27268 tar uf archive foo
27269 ) ) >"$at_stdout" 2>"$at_stderr"
27270     at_status=$?
27271 fi
27272
27273 at_failed=false
27274 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
27275 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
27276 case $at_status in
27277    77) echo 77 > "$at_status_file"; exit 77;;
27278    0) ;;
27279    *) echo "$at_srcdir/shortupd.at:32: exit code was $at_status, expected 0"
27280       at_failed=:;;
27281 esac
27282 if $at_failed; then
27283
27284
27285   echo 1 > "$at_status_file"
27286   exit 1
27287 fi
27288
27289 $at_traceon
27290 $at_traceoff
27291 echo "$at_srcdir/shortupd.at:32:
27292 mkdir posix
27293 (cd posix
27294 TEST_TAR_FORMAT=posix
27295 export TEST_TAR_FORMAT
27296 TAR_OPTIONS=\"-H posix\"
27297 export TAR_OPTIONS
27298 rm -rf *
27299
27300 touch foo
27301 tar uf archive foo
27302 )"
27303 echo shortupd.at:32 >"$at_check_line_file"
27304
27305 at_trace_this=
27306 if test -n "$at_traceon"; then
27307     echo 'Not enabling shell tracing (command contains an embedded newline)'
27308 fi
27309
27310 if test -n "$at_trace_this"; then
27311     ( $at_traceon;
27312 mkdir posix
27313 (cd posix
27314 TEST_TAR_FORMAT=posix
27315 export TEST_TAR_FORMAT
27316 TAR_OPTIONS="-H posix"
27317 export TAR_OPTIONS
27318 rm -rf *
27319
27320 touch foo
27321 tar uf archive foo
27322 ) ) >"$at_stdout" 2>"$at_stder1"
27323     at_status=$?
27324     grep '^ *+' "$at_stder1" >&2
27325     grep -v '^ *+' "$at_stder1" >"$at_stderr"
27326 else
27327     ( :;
27328 mkdir posix
27329 (cd posix
27330 TEST_TAR_FORMAT=posix
27331 export TEST_TAR_FORMAT
27332 TAR_OPTIONS="-H posix"
27333 export TAR_OPTIONS
27334 rm -rf *
27335
27336 touch foo
27337 tar uf archive foo
27338 ) ) >"$at_stdout" 2>"$at_stderr"
27339     at_status=$?
27340 fi
27341
27342 at_failed=false
27343 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
27344 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
27345 case $at_status in
27346    77) echo 77 > "$at_status_file"; exit 77;;
27347    0) ;;
27348    *) echo "$at_srcdir/shortupd.at:32: exit code was $at_status, expected 0"
27349       at_failed=:;;
27350 esac
27351 if $at_failed; then
27352
27353
27354   echo 1 > "$at_status_file"
27355   exit 1
27356 fi
27357
27358 $at_traceon
27359 $at_traceoff
27360 echo "$at_srcdir/shortupd.at:32:
27361 mkdir gnu
27362 (cd gnu
27363 TEST_TAR_FORMAT=gnu
27364 export TEST_TAR_FORMAT
27365 TAR_OPTIONS=\"-H gnu\"
27366 export TAR_OPTIONS
27367 rm -rf *
27368
27369 touch foo
27370 tar uf archive foo
27371 )"
27372 echo shortupd.at:32 >"$at_check_line_file"
27373
27374 at_trace_this=
27375 if test -n "$at_traceon"; then
27376     echo 'Not enabling shell tracing (command contains an embedded newline)'
27377 fi
27378
27379 if test -n "$at_trace_this"; then
27380     ( $at_traceon;
27381 mkdir gnu
27382 (cd gnu
27383 TEST_TAR_FORMAT=gnu
27384 export TEST_TAR_FORMAT
27385 TAR_OPTIONS="-H gnu"
27386 export TAR_OPTIONS
27387 rm -rf *
27388
27389 touch foo
27390 tar uf archive foo
27391 ) ) >"$at_stdout" 2>"$at_stder1"
27392     at_status=$?
27393     grep '^ *+' "$at_stder1" >&2
27394     grep -v '^ *+' "$at_stder1" >"$at_stderr"
27395 else
27396     ( :;
27397 mkdir gnu
27398 (cd gnu
27399 TEST_TAR_FORMAT=gnu
27400 export TEST_TAR_FORMAT
27401 TAR_OPTIONS="-H gnu"
27402 export TAR_OPTIONS
27403 rm -rf *
27404
27405 touch foo
27406 tar uf archive foo
27407 ) ) >"$at_stdout" 2>"$at_stderr"
27408     at_status=$?
27409 fi
27410
27411 at_failed=false
27412 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
27413 $at_diff "$at_devnull" "$at_stdout" || at_failed=:
27414 case $at_status in
27415    77) echo 77 > "$at_status_file"; exit 77;;
27416    0) ;;
27417    *) echo "$at_srcdir/shortupd.at:32: exit code was $at_status, expected 0"
27418       at_failed=:;;
27419 esac
27420 if $at_failed; then
27421
27422
27423   echo 1 > "$at_status_file"
27424   exit 1
27425 fi
27426
27427 $at_traceon
27428
27429
27430
27431       $at_traceoff
27432       $at_times_p && times >"$at_times_file"
27433     ) 5>&1 2>&1 | eval $at_tee_pipe
27434     at_status=`cat "$at_status_file"`
27435     ;;
27436
27437   70 ) # 70. truncate.at:29: truncate
27438     at_setup_line='truncate.at:29'
27439     at_desc="truncate"
27440     $at_quiet $ECHO_N " 70: truncate                                       $ECHO_C"
27441     at_xfail=no
27442       test -f $XFAILFILE && at_xfail=yes
27443     echo "#                             -*- compilation -*-" >> "$at_group_log"
27444     (
27445       echo "70. truncate.at:29: testing ..."
27446       $at_traceon
27447
27448
27449
27450
27451
27452   $at_traceoff
27453 echo "$at_srcdir/truncate.at:32:
27454 mkdir v7
27455 (cd v7
27456 TEST_TAR_FORMAT=v7
27457 export TEST_TAR_FORMAT
27458 TAR_OPTIONS=\"-H v7\"
27459 export TAR_OPTIONS
27460 rm -rf *
27461
27462 genfile --file foo --length 50000k
27463 genfile --file baz
27464 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 49995k --truncate foo
27465 echo Exit status: \$?
27466 echo separator
27467 sleep 1
27468 genfile --file foo --seek 49995k --length 5k --pattern=zeros
27469 tar dvf bar)"
27470 echo truncate.at:32 >"$at_check_line_file"
27471
27472 at_trace_this=
27473 if test -n "$at_traceon"; then
27474     echo 'Not enabling shell tracing (command contains an embedded newline)'
27475 fi
27476
27477 if test -n "$at_trace_this"; then
27478     ( $at_traceon;
27479 mkdir v7
27480 (cd v7
27481 TEST_TAR_FORMAT=v7
27482 export TEST_TAR_FORMAT
27483 TAR_OPTIONS="-H v7"
27484 export TAR_OPTIONS
27485 rm -rf *
27486
27487 genfile --file foo --length 50000k
27488 genfile --file baz
27489 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 49995k --truncate foo
27490 echo Exit status: $?
27491 echo separator
27492 sleep 1
27493 genfile --file foo --seek 49995k --length 5k --pattern=zeros
27494 tar dvf bar) ) >"$at_stdout" 2>"$at_stder1"
27495     at_status=$?
27496     grep '^ *+' "$at_stder1" >&2
27497     grep -v '^ *+' "$at_stder1" >"$at_stderr"
27498 else
27499     ( :;
27500 mkdir v7
27501 (cd v7
27502 TEST_TAR_FORMAT=v7
27503 export TEST_TAR_FORMAT
27504 TAR_OPTIONS="-H v7"
27505 export TAR_OPTIONS
27506 rm -rf *
27507
27508 genfile --file foo --length 50000k
27509 genfile --file baz
27510 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 49995k --truncate foo
27511 echo Exit status: $?
27512 echo separator
27513 sleep 1
27514 genfile --file foo --seek 49995k --length 5k --pattern=zeros
27515 tar dvf bar) ) >"$at_stdout" 2>"$at_stderr"
27516     at_status=$?
27517 fi
27518
27519 at_failed=false
27520 echo >>"$at_stderr"; echo "tar: foo: File shrank by 5120 bytes; padding with zeros
27521 " | $at_diff - "$at_stderr" || at_failed=:
27522 echo >>"$at_stdout"; echo "foo
27523 baz
27524 Exit status: 1
27525 separator
27526 foo
27527 foo: Mod time differs
27528 baz
27529 " | $at_diff - "$at_stdout" || at_failed=:
27530 case $at_status in
27531    77) echo 77 > "$at_status_file"; exit 77;;
27532    1) ;;
27533    *) echo "$at_srcdir/truncate.at:32: exit code was $at_status, expected 1"
27534       at_failed=:;;
27535 esac
27536 if $at_failed; then
27537
27538
27539   echo 1 > "$at_status_file"
27540   exit 1
27541 fi
27542
27543 $at_traceon
27544 $at_traceoff
27545 echo "$at_srcdir/truncate.at:32:
27546 mkdir oldgnu
27547 (cd oldgnu
27548 TEST_TAR_FORMAT=oldgnu
27549 export TEST_TAR_FORMAT
27550 TAR_OPTIONS=\"-H oldgnu\"
27551 export TAR_OPTIONS
27552 rm -rf *
27553
27554 genfile --file foo --length 50000k
27555 genfile --file baz
27556 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 49995k --truncate foo
27557 echo Exit status: \$?
27558 echo separator
27559 sleep 1
27560 genfile --file foo --seek 49995k --length 5k --pattern=zeros
27561 tar dvf bar)"
27562 echo truncate.at:32 >"$at_check_line_file"
27563
27564 at_trace_this=
27565 if test -n "$at_traceon"; then
27566     echo 'Not enabling shell tracing (command contains an embedded newline)'
27567 fi
27568
27569 if test -n "$at_trace_this"; then
27570     ( $at_traceon;
27571 mkdir oldgnu
27572 (cd oldgnu
27573 TEST_TAR_FORMAT=oldgnu
27574 export TEST_TAR_FORMAT
27575 TAR_OPTIONS="-H oldgnu"
27576 export TAR_OPTIONS
27577 rm -rf *
27578
27579 genfile --file foo --length 50000k
27580 genfile --file baz
27581 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 49995k --truncate foo
27582 echo Exit status: $?
27583 echo separator
27584 sleep 1
27585 genfile --file foo --seek 49995k --length 5k --pattern=zeros
27586 tar dvf bar) ) >"$at_stdout" 2>"$at_stder1"
27587     at_status=$?
27588     grep '^ *+' "$at_stder1" >&2
27589     grep -v '^ *+' "$at_stder1" >"$at_stderr"
27590 else
27591     ( :;
27592 mkdir oldgnu
27593 (cd oldgnu
27594 TEST_TAR_FORMAT=oldgnu
27595 export TEST_TAR_FORMAT
27596 TAR_OPTIONS="-H oldgnu"
27597 export TAR_OPTIONS
27598 rm -rf *
27599
27600 genfile --file foo --length 50000k
27601 genfile --file baz
27602 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 49995k --truncate foo
27603 echo Exit status: $?
27604 echo separator
27605 sleep 1
27606 genfile --file foo --seek 49995k --length 5k --pattern=zeros
27607 tar dvf bar) ) >"$at_stdout" 2>"$at_stderr"
27608     at_status=$?
27609 fi
27610
27611 at_failed=false
27612 echo >>"$at_stderr"; echo "tar: foo: File shrank by 5120 bytes; padding with zeros
27613 " | $at_diff - "$at_stderr" || at_failed=:
27614 echo >>"$at_stdout"; echo "foo
27615 baz
27616 Exit status: 1
27617 separator
27618 foo
27619 foo: Mod time differs
27620 baz
27621 " | $at_diff - "$at_stdout" || at_failed=:
27622 case $at_status in
27623    77) echo 77 > "$at_status_file"; exit 77;;
27624    1) ;;
27625    *) echo "$at_srcdir/truncate.at:32: exit code was $at_status, expected 1"
27626       at_failed=:;;
27627 esac
27628 if $at_failed; then
27629
27630
27631   echo 1 > "$at_status_file"
27632   exit 1
27633 fi
27634
27635 $at_traceon
27636 $at_traceoff
27637 echo "$at_srcdir/truncate.at:32:
27638 mkdir ustar
27639 (cd ustar
27640 TEST_TAR_FORMAT=ustar
27641 export TEST_TAR_FORMAT
27642 TAR_OPTIONS=\"-H ustar\"
27643 export TAR_OPTIONS
27644 rm -rf *
27645
27646 genfile --file foo --length 50000k
27647 genfile --file baz
27648 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 49995k --truncate foo
27649 echo Exit status: \$?
27650 echo separator
27651 sleep 1
27652 genfile --file foo --seek 49995k --length 5k --pattern=zeros
27653 tar dvf bar)"
27654 echo truncate.at:32 >"$at_check_line_file"
27655
27656 at_trace_this=
27657 if test -n "$at_traceon"; then
27658     echo 'Not enabling shell tracing (command contains an embedded newline)'
27659 fi
27660
27661 if test -n "$at_trace_this"; then
27662     ( $at_traceon;
27663 mkdir ustar
27664 (cd ustar
27665 TEST_TAR_FORMAT=ustar
27666 export TEST_TAR_FORMAT
27667 TAR_OPTIONS="-H ustar"
27668 export TAR_OPTIONS
27669 rm -rf *
27670
27671 genfile --file foo --length 50000k
27672 genfile --file baz
27673 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 49995k --truncate foo
27674 echo Exit status: $?
27675 echo separator
27676 sleep 1
27677 genfile --file foo --seek 49995k --length 5k --pattern=zeros
27678 tar dvf bar) ) >"$at_stdout" 2>"$at_stder1"
27679     at_status=$?
27680     grep '^ *+' "$at_stder1" >&2
27681     grep -v '^ *+' "$at_stder1" >"$at_stderr"
27682 else
27683     ( :;
27684 mkdir ustar
27685 (cd ustar
27686 TEST_TAR_FORMAT=ustar
27687 export TEST_TAR_FORMAT
27688 TAR_OPTIONS="-H ustar"
27689 export TAR_OPTIONS
27690 rm -rf *
27691
27692 genfile --file foo --length 50000k
27693 genfile --file baz
27694 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 49995k --truncate foo
27695 echo Exit status: $?
27696 echo separator
27697 sleep 1
27698 genfile --file foo --seek 49995k --length 5k --pattern=zeros
27699 tar dvf bar) ) >"$at_stdout" 2>"$at_stderr"
27700     at_status=$?
27701 fi
27702
27703 at_failed=false
27704 echo >>"$at_stderr"; echo "tar: foo: File shrank by 5120 bytes; padding with zeros
27705 " | $at_diff - "$at_stderr" || at_failed=:
27706 echo >>"$at_stdout"; echo "foo
27707 baz
27708 Exit status: 1
27709 separator
27710 foo
27711 foo: Mod time differs
27712 baz
27713 " | $at_diff - "$at_stdout" || at_failed=:
27714 case $at_status in
27715    77) echo 77 > "$at_status_file"; exit 77;;
27716    1) ;;
27717    *) echo "$at_srcdir/truncate.at:32: exit code was $at_status, expected 1"
27718       at_failed=:;;
27719 esac
27720 if $at_failed; then
27721
27722
27723   echo 1 > "$at_status_file"
27724   exit 1
27725 fi
27726
27727 $at_traceon
27728 $at_traceoff
27729 echo "$at_srcdir/truncate.at:32:
27730 mkdir posix
27731 (cd posix
27732 TEST_TAR_FORMAT=posix
27733 export TEST_TAR_FORMAT
27734 TAR_OPTIONS=\"-H posix\"
27735 export TAR_OPTIONS
27736 rm -rf *
27737
27738 genfile --file foo --length 50000k
27739 genfile --file baz
27740 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 49995k --truncate foo
27741 echo Exit status: \$?
27742 echo separator
27743 sleep 1
27744 genfile --file foo --seek 49995k --length 5k --pattern=zeros
27745 tar dvf bar)"
27746 echo truncate.at:32 >"$at_check_line_file"
27747
27748 at_trace_this=
27749 if test -n "$at_traceon"; then
27750     echo 'Not enabling shell tracing (command contains an embedded newline)'
27751 fi
27752
27753 if test -n "$at_trace_this"; then
27754     ( $at_traceon;
27755 mkdir posix
27756 (cd posix
27757 TEST_TAR_FORMAT=posix
27758 export TEST_TAR_FORMAT
27759 TAR_OPTIONS="-H posix"
27760 export TAR_OPTIONS
27761 rm -rf *
27762
27763 genfile --file foo --length 50000k
27764 genfile --file baz
27765 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 49995k --truncate foo
27766 echo Exit status: $?
27767 echo separator
27768 sleep 1
27769 genfile --file foo --seek 49995k --length 5k --pattern=zeros
27770 tar dvf bar) ) >"$at_stdout" 2>"$at_stder1"
27771     at_status=$?
27772     grep '^ *+' "$at_stder1" >&2
27773     grep -v '^ *+' "$at_stder1" >"$at_stderr"
27774 else
27775     ( :;
27776 mkdir posix
27777 (cd posix
27778 TEST_TAR_FORMAT=posix
27779 export TEST_TAR_FORMAT
27780 TAR_OPTIONS="-H posix"
27781 export TAR_OPTIONS
27782 rm -rf *
27783
27784 genfile --file foo --length 50000k
27785 genfile --file baz
27786 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 49995k --truncate foo
27787 echo Exit status: $?
27788 echo separator
27789 sleep 1
27790 genfile --file foo --seek 49995k --length 5k --pattern=zeros
27791 tar dvf bar) ) >"$at_stdout" 2>"$at_stderr"
27792     at_status=$?
27793 fi
27794
27795 at_failed=false
27796 echo >>"$at_stderr"; echo "tar: foo: File shrank by 5120 bytes; padding with zeros
27797 " | $at_diff - "$at_stderr" || at_failed=:
27798 echo >>"$at_stdout"; echo "foo
27799 baz
27800 Exit status: 1
27801 separator
27802 foo
27803 foo: Mod time differs
27804 baz
27805 " | $at_diff - "$at_stdout" || at_failed=:
27806 case $at_status in
27807    77) echo 77 > "$at_status_file"; exit 77;;
27808    1) ;;
27809    *) echo "$at_srcdir/truncate.at:32: exit code was $at_status, expected 1"
27810       at_failed=:;;
27811 esac
27812 if $at_failed; then
27813
27814
27815   echo 1 > "$at_status_file"
27816   exit 1
27817 fi
27818
27819 $at_traceon
27820 $at_traceoff
27821 echo "$at_srcdir/truncate.at:32:
27822 mkdir gnu
27823 (cd gnu
27824 TEST_TAR_FORMAT=gnu
27825 export TEST_TAR_FORMAT
27826 TAR_OPTIONS=\"-H gnu\"
27827 export TAR_OPTIONS
27828 rm -rf *
27829
27830 genfile --file foo --length 50000k
27831 genfile --file baz
27832 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 49995k --truncate foo
27833 echo Exit status: \$?
27834 echo separator
27835 sleep 1
27836 genfile --file foo --seek 49995k --length 5k --pattern=zeros
27837 tar dvf bar)"
27838 echo truncate.at:32 >"$at_check_line_file"
27839
27840 at_trace_this=
27841 if test -n "$at_traceon"; then
27842     echo 'Not enabling shell tracing (command contains an embedded newline)'
27843 fi
27844
27845 if test -n "$at_trace_this"; then
27846     ( $at_traceon;
27847 mkdir gnu
27848 (cd gnu
27849 TEST_TAR_FORMAT=gnu
27850 export TEST_TAR_FORMAT
27851 TAR_OPTIONS="-H gnu"
27852 export TAR_OPTIONS
27853 rm -rf *
27854
27855 genfile --file foo --length 50000k
27856 genfile --file baz
27857 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 49995k --truncate foo
27858 echo Exit status: $?
27859 echo separator
27860 sleep 1
27861 genfile --file foo --seek 49995k --length 5k --pattern=zeros
27862 tar dvf bar) ) >"$at_stdout" 2>"$at_stder1"
27863     at_status=$?
27864     grep '^ *+' "$at_stder1" >&2
27865     grep -v '^ *+' "$at_stder1" >"$at_stderr"
27866 else
27867     ( :;
27868 mkdir gnu
27869 (cd gnu
27870 TEST_TAR_FORMAT=gnu
27871 export TEST_TAR_FORMAT
27872 TAR_OPTIONS="-H gnu"
27873 export TAR_OPTIONS
27874 rm -rf *
27875
27876 genfile --file foo --length 50000k
27877 genfile --file baz
27878 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 49995k --truncate foo
27879 echo Exit status: $?
27880 echo separator
27881 sleep 1
27882 genfile --file foo --seek 49995k --length 5k --pattern=zeros
27883 tar dvf bar) ) >"$at_stdout" 2>"$at_stderr"
27884     at_status=$?
27885 fi
27886
27887 at_failed=false
27888 echo >>"$at_stderr"; echo "tar: foo: File shrank by 5120 bytes; padding with zeros
27889 " | $at_diff - "$at_stderr" || at_failed=:
27890 echo >>"$at_stdout"; echo "foo
27891 baz
27892 Exit status: 1
27893 separator
27894 foo
27895 foo: Mod time differs
27896 baz
27897 " | $at_diff - "$at_stdout" || at_failed=:
27898 case $at_status in
27899    77) echo 77 > "$at_status_file"; exit 77;;
27900    1) ;;
27901    *) echo "$at_srcdir/truncate.at:32: exit code was $at_status, expected 1"
27902       at_failed=:;;
27903 esac
27904 if $at_failed; then
27905
27906
27907   echo 1 > "$at_status_file"
27908   exit 1
27909 fi
27910
27911 $at_traceon
27912
27913
27914
27915       $at_traceoff
27916       $at_times_p && times >"$at_times_file"
27917     ) 5>&1 2>&1 | eval $at_tee_pipe
27918     at_status=`cat "$at_status_file"`
27919     ;;
27920
27921   71 ) # 71. grow.at:24: grow
27922     at_setup_line='grow.at:24'
27923     at_desc="grow"
27924     $at_quiet $ECHO_N " 71: grow                                           $ECHO_C"
27925     at_xfail=no
27926       test -f $XFAILFILE && at_xfail=yes
27927     echo "#                             -*- compilation -*-" >> "$at_group_log"
27928     (
27929       echo "71. grow.at:24: testing ..."
27930       $at_traceon
27931
27932
27933
27934
27935
27936   $at_traceoff
27937 echo "$at_srcdir/grow.at:27:
27938 mkdir v7
27939 (cd v7
27940 TEST_TAR_FORMAT=v7
27941 export TEST_TAR_FORMAT
27942 TAR_OPTIONS=\"-H v7\"
27943 export TAR_OPTIONS
27944 rm -rf *
27945
27946 genfile --file foo --length 50000k
27947 genfile --file baz
27948 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 1024 \\
27949         --append foo
27950 )"
27951 echo grow.at:27 >"$at_check_line_file"
27952
27953 at_trace_this=
27954 if test -n "$at_traceon"; then
27955     echo 'Not enabling shell tracing (command contains an embedded newline)'
27956 fi
27957
27958 if test -n "$at_trace_this"; then
27959     ( $at_traceon;
27960 mkdir v7
27961 (cd v7
27962 TEST_TAR_FORMAT=v7
27963 export TEST_TAR_FORMAT
27964 TAR_OPTIONS="-H v7"
27965 export TAR_OPTIONS
27966 rm -rf *
27967
27968 genfile --file foo --length 50000k
27969 genfile --file baz
27970 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 1024 \
27971         --append foo
27972 ) ) >"$at_stdout" 2>"$at_stder1"
27973     at_status=$?
27974     grep '^ *+' "$at_stder1" >&2
27975     grep -v '^ *+' "$at_stder1" >"$at_stderr"
27976 else
27977     ( :;
27978 mkdir v7
27979 (cd v7
27980 TEST_TAR_FORMAT=v7
27981 export TEST_TAR_FORMAT
27982 TAR_OPTIONS="-H v7"
27983 export TAR_OPTIONS
27984 rm -rf *
27985
27986 genfile --file foo --length 50000k
27987 genfile --file baz
27988 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 1024 \
27989         --append foo
27990 ) ) >"$at_stdout" 2>"$at_stderr"
27991     at_status=$?
27992 fi
27993
27994 at_failed=false
27995 echo >>"$at_stderr"; echo "tar: foo: file changed as we read it
27996 " | $at_diff - "$at_stderr" || at_failed=:
27997 echo >>"$at_stdout"; echo "foo
27998 baz
27999 " | $at_diff - "$at_stdout" || at_failed=:
28000 case $at_status in
28001    77) echo 77 > "$at_status_file"; exit 77;;
28002    1) ;;
28003    *) echo "$at_srcdir/grow.at:27: exit code was $at_status, expected 1"
28004       at_failed=:;;
28005 esac
28006 if $at_failed; then
28007
28008
28009   echo 1 > "$at_status_file"
28010   exit 1
28011 fi
28012
28013 $at_traceon
28014 $at_traceoff
28015 echo "$at_srcdir/grow.at:27:
28016 mkdir oldgnu
28017 (cd oldgnu
28018 TEST_TAR_FORMAT=oldgnu
28019 export TEST_TAR_FORMAT
28020 TAR_OPTIONS=\"-H oldgnu\"
28021 export TAR_OPTIONS
28022 rm -rf *
28023
28024 genfile --file foo --length 50000k
28025 genfile --file baz
28026 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 1024 \\
28027         --append foo
28028 )"
28029 echo grow.at:27 >"$at_check_line_file"
28030
28031 at_trace_this=
28032 if test -n "$at_traceon"; then
28033     echo 'Not enabling shell tracing (command contains an embedded newline)'
28034 fi
28035
28036 if test -n "$at_trace_this"; then
28037     ( $at_traceon;
28038 mkdir oldgnu
28039 (cd oldgnu
28040 TEST_TAR_FORMAT=oldgnu
28041 export TEST_TAR_FORMAT
28042 TAR_OPTIONS="-H oldgnu"
28043 export TAR_OPTIONS
28044 rm -rf *
28045
28046 genfile --file foo --length 50000k
28047 genfile --file baz
28048 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 1024 \
28049         --append foo
28050 ) ) >"$at_stdout" 2>"$at_stder1"
28051     at_status=$?
28052     grep '^ *+' "$at_stder1" >&2
28053     grep -v '^ *+' "$at_stder1" >"$at_stderr"
28054 else
28055     ( :;
28056 mkdir oldgnu
28057 (cd oldgnu
28058 TEST_TAR_FORMAT=oldgnu
28059 export TEST_TAR_FORMAT
28060 TAR_OPTIONS="-H oldgnu"
28061 export TAR_OPTIONS
28062 rm -rf *
28063
28064 genfile --file foo --length 50000k
28065 genfile --file baz
28066 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 1024 \
28067         --append foo
28068 ) ) >"$at_stdout" 2>"$at_stderr"
28069     at_status=$?
28070 fi
28071
28072 at_failed=false
28073 echo >>"$at_stderr"; echo "tar: foo: file changed as we read it
28074 " | $at_diff - "$at_stderr" || at_failed=:
28075 echo >>"$at_stdout"; echo "foo
28076 baz
28077 " | $at_diff - "$at_stdout" || at_failed=:
28078 case $at_status in
28079    77) echo 77 > "$at_status_file"; exit 77;;
28080    1) ;;
28081    *) echo "$at_srcdir/grow.at:27: exit code was $at_status, expected 1"
28082       at_failed=:;;
28083 esac
28084 if $at_failed; then
28085
28086
28087   echo 1 > "$at_status_file"
28088   exit 1
28089 fi
28090
28091 $at_traceon
28092 $at_traceoff
28093 echo "$at_srcdir/grow.at:27:
28094 mkdir ustar
28095 (cd ustar
28096 TEST_TAR_FORMAT=ustar
28097 export TEST_TAR_FORMAT
28098 TAR_OPTIONS=\"-H ustar\"
28099 export TAR_OPTIONS
28100 rm -rf *
28101
28102 genfile --file foo --length 50000k
28103 genfile --file baz
28104 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 1024 \\
28105         --append foo
28106 )"
28107 echo grow.at:27 >"$at_check_line_file"
28108
28109 at_trace_this=
28110 if test -n "$at_traceon"; then
28111     echo 'Not enabling shell tracing (command contains an embedded newline)'
28112 fi
28113
28114 if test -n "$at_trace_this"; then
28115     ( $at_traceon;
28116 mkdir ustar
28117 (cd ustar
28118 TEST_TAR_FORMAT=ustar
28119 export TEST_TAR_FORMAT
28120 TAR_OPTIONS="-H ustar"
28121 export TAR_OPTIONS
28122 rm -rf *
28123
28124 genfile --file foo --length 50000k
28125 genfile --file baz
28126 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 1024 \
28127         --append foo
28128 ) ) >"$at_stdout" 2>"$at_stder1"
28129     at_status=$?
28130     grep '^ *+' "$at_stder1" >&2
28131     grep -v '^ *+' "$at_stder1" >"$at_stderr"
28132 else
28133     ( :;
28134 mkdir ustar
28135 (cd ustar
28136 TEST_TAR_FORMAT=ustar
28137 export TEST_TAR_FORMAT
28138 TAR_OPTIONS="-H ustar"
28139 export TAR_OPTIONS
28140 rm -rf *
28141
28142 genfile --file foo --length 50000k
28143 genfile --file baz
28144 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 1024 \
28145         --append foo
28146 ) ) >"$at_stdout" 2>"$at_stderr"
28147     at_status=$?
28148 fi
28149
28150 at_failed=false
28151 echo >>"$at_stderr"; echo "tar: foo: file changed as we read it
28152 " | $at_diff - "$at_stderr" || at_failed=:
28153 echo >>"$at_stdout"; echo "foo
28154 baz
28155 " | $at_diff - "$at_stdout" || at_failed=:
28156 case $at_status in
28157    77) echo 77 > "$at_status_file"; exit 77;;
28158    1) ;;
28159    *) echo "$at_srcdir/grow.at:27: exit code was $at_status, expected 1"
28160       at_failed=:;;
28161 esac
28162 if $at_failed; then
28163
28164
28165   echo 1 > "$at_status_file"
28166   exit 1
28167 fi
28168
28169 $at_traceon
28170 $at_traceoff
28171 echo "$at_srcdir/grow.at:27:
28172 mkdir posix
28173 (cd posix
28174 TEST_TAR_FORMAT=posix
28175 export TEST_TAR_FORMAT
28176 TAR_OPTIONS=\"-H posix\"
28177 export TAR_OPTIONS
28178 rm -rf *
28179
28180 genfile --file foo --length 50000k
28181 genfile --file baz
28182 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 1024 \\
28183         --append foo
28184 )"
28185 echo grow.at:27 >"$at_check_line_file"
28186
28187 at_trace_this=
28188 if test -n "$at_traceon"; then
28189     echo 'Not enabling shell tracing (command contains an embedded newline)'
28190 fi
28191
28192 if test -n "$at_trace_this"; then
28193     ( $at_traceon;
28194 mkdir posix
28195 (cd posix
28196 TEST_TAR_FORMAT=posix
28197 export TEST_TAR_FORMAT
28198 TAR_OPTIONS="-H posix"
28199 export TAR_OPTIONS
28200 rm -rf *
28201
28202 genfile --file foo --length 50000k
28203 genfile --file baz
28204 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 1024 \
28205         --append foo
28206 ) ) >"$at_stdout" 2>"$at_stder1"
28207     at_status=$?
28208     grep '^ *+' "$at_stder1" >&2
28209     grep -v '^ *+' "$at_stder1" >"$at_stderr"
28210 else
28211     ( :;
28212 mkdir posix
28213 (cd posix
28214 TEST_TAR_FORMAT=posix
28215 export TEST_TAR_FORMAT
28216 TAR_OPTIONS="-H posix"
28217 export TAR_OPTIONS
28218 rm -rf *
28219
28220 genfile --file foo --length 50000k
28221 genfile --file baz
28222 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 1024 \
28223         --append foo
28224 ) ) >"$at_stdout" 2>"$at_stderr"
28225     at_status=$?
28226 fi
28227
28228 at_failed=false
28229 echo >>"$at_stderr"; echo "tar: foo: file changed as we read it
28230 " | $at_diff - "$at_stderr" || at_failed=:
28231 echo >>"$at_stdout"; echo "foo
28232 baz
28233 " | $at_diff - "$at_stdout" || at_failed=:
28234 case $at_status in
28235    77) echo 77 > "$at_status_file"; exit 77;;
28236    1) ;;
28237    *) echo "$at_srcdir/grow.at:27: exit code was $at_status, expected 1"
28238       at_failed=:;;
28239 esac
28240 if $at_failed; then
28241
28242
28243   echo 1 > "$at_status_file"
28244   exit 1
28245 fi
28246
28247 $at_traceon
28248 $at_traceoff
28249 echo "$at_srcdir/grow.at:27:
28250 mkdir gnu
28251 (cd gnu
28252 TEST_TAR_FORMAT=gnu
28253 export TEST_TAR_FORMAT
28254 TAR_OPTIONS=\"-H gnu\"
28255 export TAR_OPTIONS
28256 rm -rf *
28257
28258 genfile --file foo --length 50000k
28259 genfile --file baz
28260 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 1024 \\
28261         --append foo
28262 )"
28263 echo grow.at:27 >"$at_check_line_file"
28264
28265 at_trace_this=
28266 if test -n "$at_traceon"; then
28267     echo 'Not enabling shell tracing (command contains an embedded newline)'
28268 fi
28269
28270 if test -n "$at_trace_this"; then
28271     ( $at_traceon;
28272 mkdir gnu
28273 (cd gnu
28274 TEST_TAR_FORMAT=gnu
28275 export TEST_TAR_FORMAT
28276 TAR_OPTIONS="-H gnu"
28277 export TAR_OPTIONS
28278 rm -rf *
28279
28280 genfile --file foo --length 50000k
28281 genfile --file baz
28282 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 1024 \
28283         --append foo
28284 ) ) >"$at_stdout" 2>"$at_stder1"
28285     at_status=$?
28286     grep '^ *+' "$at_stder1" >&2
28287     grep -v '^ *+' "$at_stder1" >"$at_stderr"
28288 else
28289     ( :;
28290 mkdir gnu
28291 (cd gnu
28292 TEST_TAR_FORMAT=gnu
28293 export TEST_TAR_FORMAT
28294 TAR_OPTIONS="-H gnu"
28295 export TAR_OPTIONS
28296 rm -rf *
28297
28298 genfile --file foo --length 50000k
28299 genfile --file baz
28300 genfile --run 'tar -vcf bar foo baz' --checkpoint 10 --length 1024 \
28301         --append foo
28302 ) ) >"$at_stdout" 2>"$at_stderr"
28303     at_status=$?
28304 fi
28305
28306 at_failed=false
28307 echo >>"$at_stderr"; echo "tar: foo: file changed as we read it
28308 " | $at_diff - "$at_stderr" || at_failed=:
28309 echo >>"$at_stdout"; echo "foo
28310 baz
28311 " | $at_diff - "$at_stdout" || at_failed=:
28312 case $at_status in
28313    77) echo 77 > "$at_status_file"; exit 77;;
28314    1) ;;
28315    *) echo "$at_srcdir/grow.at:27: exit code was $at_status, expected 1"
28316       at_failed=:;;
28317 esac
28318 if $at_failed; then
28319
28320
28321   echo 1 > "$at_status_file"
28322   exit 1
28323 fi
28324
28325 $at_traceon
28326
28327
28328
28329       $at_traceoff
28330       $at_times_p && times >"$at_times_file"
28331     ) 5>&1 2>&1 | eval $at_tee_pipe
28332     at_status=`cat "$at_status_file"`
28333     ;;
28334
28335   72 ) # 72. gtarfail.at:21: gtarfail
28336     at_setup_line='gtarfail.at:21'
28337     at_desc="gtarfail"
28338     $at_quiet $ECHO_N " 72: gtarfail                                       $ECHO_C"
28339     at_xfail=no
28340     echo "#                             -*- compilation -*-" >> "$at_group_log"
28341     (
28342       echo "72. gtarfail.at:21: testing ..."
28343       $at_traceon
28344
28345
28346
28347 unset TAR_OPTIONS
28348
28349 $at_traceoff
28350 echo "$at_srcdir/gtarfail.at:26:
28351
28352 test -z "$STAR_TESTSCRIPTS" && exit 77
28353 tarball_prereq gtarfail.tar bf7612e401aaa679edbb07ae1183811b $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28354
28355
28356 tar --utc -tvf \$STAR_TESTSCRIPTS/gtarfail.tar
28357 "
28358 echo gtarfail.at:26 >"$at_check_line_file"
28359
28360 at_trace_this=
28361 if test -n "$at_traceon"; then
28362     echo 'Not enabling shell tracing (command contains an embedded newline)'
28363 fi
28364
28365 if test -n "$at_trace_this"; then
28366     ( $at_traceon;
28367
28368 test -z "$STAR_TESTSCRIPTS" && exit 77
28369 tarball_prereq gtarfail.tar bf7612e401aaa679edbb07ae1183811b $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28370
28371
28372 tar --utc -tvf $STAR_TESTSCRIPTS/gtarfail.tar
28373  ) >"$at_stdout" 2>"$at_stder1"
28374     at_status=$?
28375     grep '^ *+' "$at_stder1" >&2
28376     grep -v '^ *+' "$at_stder1" >"$at_stderr"
28377 else
28378     ( :;
28379
28380 test -z "$STAR_TESTSCRIPTS" && exit 77
28381 tarball_prereq gtarfail.tar bf7612e401aaa679edbb07ae1183811b $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28382
28383
28384 tar --utc -tvf $STAR_TESTSCRIPTS/gtarfail.tar
28385  ) >"$at_stdout" 2>"$at_stderr"
28386     at_status=$?
28387 fi
28388
28389 at_failed=false
28390 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
28391 echo >>"$at_stdout"; echo "-rw-r--r-- jes/glone       518 2001-05-25 14:41 vedpowered.gif
28392 -rw-r--r-- jes/glone      6825 1997-04-29 00:19 cd.gif
28393 -rw-r--r-- jes/glone     33354 1999-06-22 12:17 DSCN0049c.JPG
28394 -rw-r--r-- jes/glone     86159 2001-06-05 18:16 Window1.jpg
28395 -rw-r--r-- jes/glone      1310 2001-05-25 13:05 vipower.gif
28396 -rw-rw-rw- jes/glone    148753 1998-09-15 13:08 billyboy.jpg
28397 " | $at_diff - "$at_stdout" || at_failed=:
28398 case $at_status in
28399    77) echo 77 > "$at_status_file"; exit 77;;
28400    0) ;;
28401    *) echo "$at_srcdir/gtarfail.at:26: exit code was $at_status, expected 0"
28402       at_failed=:;;
28403 esac
28404 if $at_failed; then
28405
28406
28407   echo 1 > "$at_status_file"
28408   exit 1
28409 fi
28410
28411 $at_traceon
28412
28413
28414       $at_traceoff
28415       $at_times_p && times >"$at_times_file"
28416     ) 5>&1 2>&1 | eval $at_tee_pipe
28417     at_status=`cat "$at_status_file"`
28418     ;;
28419
28420   73 ) # 73. gtarfail2.at:21: gtarfail2
28421     at_setup_line='gtarfail2.at:21'
28422     at_desc="gtarfail2"
28423     $at_quiet $ECHO_N " 73: gtarfail2                                      $ECHO_C"
28424     at_xfail=no
28425     echo "#                             -*- compilation -*-" >> "$at_group_log"
28426     (
28427       echo "73. gtarfail2.at:21: testing ..."
28428       $at_traceon
28429
28430
28431
28432 unset TAR_OPTIONS
28433
28434 $at_traceoff
28435 echo "$at_srcdir/gtarfail2.at:26:
28436
28437 test -z "$STAR_TESTSCRIPTS" && exit 77
28438 tarball_prereq gtarfail2.tar 6b607d1faec14b82f69525d9c5b66e53 $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28439
28440 tar --utc -tvf \$STAR_TESTSCRIPTS/gtarfail2.tar
28441 "
28442 echo gtarfail2.at:26 >"$at_check_line_file"
28443
28444 at_trace_this=
28445 if test -n "$at_traceon"; then
28446     echo 'Not enabling shell tracing (command contains an embedded newline)'
28447 fi
28448
28449 if test -n "$at_trace_this"; then
28450     ( $at_traceon;
28451
28452 test -z "$STAR_TESTSCRIPTS" && exit 77
28453 tarball_prereq gtarfail2.tar 6b607d1faec14b82f69525d9c5b66e53 $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28454
28455 tar --utc -tvf $STAR_TESTSCRIPTS/gtarfail2.tar
28456  ) >"$at_stdout" 2>"$at_stder1"
28457     at_status=$?
28458     grep '^ *+' "$at_stder1" >&2
28459     grep -v '^ *+' "$at_stder1" >"$at_stderr"
28460 else
28461     ( :;
28462
28463 test -z "$STAR_TESTSCRIPTS" && exit 77
28464 tarball_prereq gtarfail2.tar 6b607d1faec14b82f69525d9c5b66e53 $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28465
28466 tar --utc -tvf $STAR_TESTSCRIPTS/gtarfail2.tar
28467  ) >"$at_stdout" 2>"$at_stderr"
28468     at_status=$?
28469 fi
28470
28471 at_failed=false
28472 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
28473 echo >>"$at_stdout"; echo "-rwxr-xr-x jes/glone       214 2001-09-21 14:08 .clean
28474 lrwxrwxrwx jes/cats          0 1998-05-07 12:39 RULES -> makefiles/RULES
28475 drwxr-sr-x jes/glone         0 2001-12-10 00:00 build/
28476 -rw-r--r-- jes/glone    312019 2001-12-10 00:00 build/smake-1.2.tar.gz
28477 drwxr-sr-x jes/glone         0 2001-11-09 18:20 build/psmake/
28478 -rwxr-xr-x jes/glone       259 2000-01-09 16:36 build/psmake/MAKE
28479 -rwxr-xr-x jes/glone      4820 2001-02-25 22:45 build/psmake/MAKE.sh
28480 -rw-r--r-- jes/glone       647 2001-02-25 23:50 build/psmake/Makefile
28481 lrwxrwxrwx jes/glone         0 2001-08-29 10:53 build/psmake/archconf.c -> ../archconf.c
28482 lrwxrwxrwx jes/glone         0 2001-08-29 10:54 build/psmake/astoi.c -> ../../lib/astoi.c
28483 " | $at_diff - "$at_stdout" || at_failed=:
28484 case $at_status in
28485    77) echo 77 > "$at_status_file"; exit 77;;
28486    0) ;;
28487    *) echo "$at_srcdir/gtarfail2.at:26: exit code was $at_status, expected 0"
28488       at_failed=:;;
28489 esac
28490 if $at_failed; then
28491
28492
28493   echo 1 > "$at_status_file"
28494   exit 1
28495 fi
28496
28497 $at_traceon
28498
28499
28500       $at_traceoff
28501       $at_times_p && times >"$at_times_file"
28502     ) 5>&1 2>&1 | eval $at_tee_pipe
28503     at_status=`cat "$at_status_file"`
28504     ;;
28505
28506   74 ) # 74. multi-fail.at:21: multi-fail
28507     at_setup_line='multi-fail.at:21'
28508     at_desc="multi-fail"
28509     $at_quiet $ECHO_N " 74: multi-fail                                     $ECHO_C"
28510     at_xfail=no
28511     echo "#                             -*- compilation -*-" >> "$at_group_log"
28512     (
28513       echo "74. multi-fail.at:21: testing ..."
28514       $at_traceon
28515
28516
28517
28518 unset TAR_OPTIONS
28519
28520 $at_traceoff
28521 echo "$at_srcdir/multi-fail.at:26:
28522
28523 test -z "$STAR_TESTSCRIPTS" && exit 77
28524 tarball_prereq gnu-multi-fail-volume1.gtar 7c28663dd98b0bd91ceb4be7af55254e $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28525
28526
28527 test -z "$STAR_TESTSCRIPTS" && exit 77
28528 tarball_prereq gnu-multi-fail-volume2.gtar b5d41c4c3ec440687d4a44957b5079a8 $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28529
28530
28531 tar --utc -tvM -f \$STAR_TESTSCRIPTS/gnu-multi-fail-volume1.gtar \\
28532                -f \$STAR_TESTSCRIPTS/gnu-multi-fail-volume2.gtar <&-
28533 "
28534 echo multi-fail.at:26 >"$at_check_line_file"
28535
28536 at_trace_this=
28537 if test -n "$at_traceon"; then
28538     echo 'Not enabling shell tracing (command contains an embedded newline)'
28539 fi
28540
28541 if test -n "$at_trace_this"; then
28542     ( $at_traceon;
28543
28544 test -z "$STAR_TESTSCRIPTS" && exit 77
28545 tarball_prereq gnu-multi-fail-volume1.gtar 7c28663dd98b0bd91ceb4be7af55254e $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28546
28547
28548 test -z "$STAR_TESTSCRIPTS" && exit 77
28549 tarball_prereq gnu-multi-fail-volume2.gtar b5d41c4c3ec440687d4a44957b5079a8 $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28550
28551
28552 tar --utc -tvM -f $STAR_TESTSCRIPTS/gnu-multi-fail-volume1.gtar \
28553                -f $STAR_TESTSCRIPTS/gnu-multi-fail-volume2.gtar <&-
28554  ) >"$at_stdout" 2>"$at_stder1"
28555     at_status=$?
28556     grep '^ *+' "$at_stder1" >&2
28557     grep -v '^ *+' "$at_stder1" >"$at_stderr"
28558 else
28559     ( :;
28560
28561 test -z "$STAR_TESTSCRIPTS" && exit 77
28562 tarball_prereq gnu-multi-fail-volume1.gtar 7c28663dd98b0bd91ceb4be7af55254e $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28563
28564
28565 test -z "$STAR_TESTSCRIPTS" && exit 77
28566 tarball_prereq gnu-multi-fail-volume2.gtar b5d41c4c3ec440687d4a44957b5079a8 $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28567
28568
28569 tar --utc -tvM -f $STAR_TESTSCRIPTS/gnu-multi-fail-volume1.gtar \
28570                -f $STAR_TESTSCRIPTS/gnu-multi-fail-volume2.gtar <&-
28571  ) >"$at_stdout" 2>"$at_stderr"
28572     at_status=$?
28573 fi
28574
28575 at_failed=false
28576 $at_diff "$at_devnull" "$at_stderr" || at_failed=:
28577 echo >>"$at_stdout"; echo "drwxrwsr-x joerg/bs          0 2003-10-11 14:32 OBJ/i386-sunos5-gcc/
28578 -rw-r--r-- joerg/bs          1 2003-10-11 14:32 OBJ/i386-sunos5-gcc/Dnull
28579 -rw-r--r-- joerg/bs       1743 2003-10-10 18:06 OBJ/i386-sunos5-gcc/star.d
28580 -rw-r--r-- joerg/bs       1460 2003-10-11 11:53 OBJ/i386-sunos5-gcc/header.d
28581 -rw-r--r-- joerg/bs       1540 2003-10-10 18:06 OBJ/i386-sunos5-gcc/cpiohdr.d
28582 -rw-r--r-- joerg/bs       2245 2003-10-10 18:06 OBJ/i386-sunos5-gcc/xheader.d
28583 -rw-r--r-- joerg/bs       1254 2003-10-10 18:06 OBJ/i386-sunos5-gcc/xattr.d
28584 -rw-r--r-- joerg/bs       1330 2003-10-10 18:06 OBJ/i386-sunos5-gcc/list.d
28585 -rw-r--r-- joerg/bs       1745 2003-10-10 18:06 OBJ/i386-sunos5-gcc/extract.d
28586 -rw-r--r-- joerg/bs       1518 2003-10-10 18:06 OBJ/i386-sunos5-gcc/create.d
28587 -rw-r--r-- joerg/bs       1235 2003-10-10 18:06 OBJ/i386-sunos5-gcc/append.d
28588 -rw-r--r-- joerg/bs       1368 2003-10-10 18:06 OBJ/i386-sunos5-gcc/diff.d
28589 -rw-r--r-- joerg/bs       1423 2003-10-10 18:06 OBJ/i386-sunos5-gcc/remove.d
28590 -rw-r--r-- joerg/bs       1493 2003-10-10 18:07 OBJ/i386-sunos5-gcc/star_unix.d
28591 -rw-r--r-- joerg/bs       1572 2003-10-10 18:07 OBJ/i386-sunos5-gcc/acl_unix.d
28592 -rw-r--r-- joerg/bs       1453 2003-10-10 18:07 OBJ/i386-sunos5-gcc/fflags.d
28593 -rw-r--r-- joerg/bs       2257 2003-10-11 14:32 OBJ/i386-sunos5-gcc/buffer.d
28594 -rw-r--r-- joerg/bs        969 2003-10-07 17:53 OBJ/i386-sunos5-gcc/dirtime.d
28595 -rw-r--r-- joerg/bs       1308 2003-10-10 18:07 OBJ/i386-sunos5-gcc/lhash.d
28596 -rw-r--r-- joerg/bs       1287 2003-10-10 18:07 OBJ/i386-sunos5-gcc/hole.d
28597 -rw-r--r-- joerg/bs       1105 2003-10-10 18:07 OBJ/i386-sunos5-gcc/longnames.d
28598 -rw-r--r-- joerg/bs       1230 2003-10-10 18:07 OBJ/i386-sunos5-gcc/names.d
28599 -rw-r--r-- joerg/bs       1091 2003-10-10 18:07 OBJ/i386-sunos5-gcc/movearch.d
28600 -rw-r--r-- joerg/bs        961 2003-10-07 17:53 OBJ/i386-sunos5-gcc/table.d
28601 -rw-r--r-- joerg/bs       1113 2003-10-10 18:07 OBJ/i386-sunos5-gcc/props.d
28602 -rw-r--r-- joerg/bs       2146 2003-10-10 18:07 OBJ/i386-sunos5-gcc/fetchdir.d
28603 -rw-r--r-- joerg/bs       1093 2003-10-10 18:07 OBJ/i386-sunos5-gcc/unicode.d
28604 -rw-r--r-- joerg/bs       1211 2003-10-10 18:07 OBJ/i386-sunos5-gcc/subst.d
28605 -rw-r--r-- joerg/bs       2076 2003-10-11 11:53 OBJ/i386-sunos5-gcc/volhdr.d
28606 -rw-r--r-- joerg/bs       1480 2003-10-10 18:07 OBJ/i386-sunos5-gcc/chdir.d
28607 -rw-r--r-- joerg/bs      42460 2003-10-10 18:07 OBJ/i386-sunos5-gcc/star.o
28608 -rw-r--r-- joerg/bs      22564 2003-10-11 11:53 OBJ/i386-sunos5-gcc/header.o
28609 -rw-r--r-- joerg/bs       7880 2003-10-10 18:07 OBJ/i386-sunos5-gcc/cpiohdr.o
28610 -rw-r--r-- joerg/bs      14624 2003-10-10 18:07 OBJ/i386-sunos5-gcc/xheader.o
28611 -rw-r--r-- joerg/bs        924 2003-10-10 18:07 OBJ/i386-sunos5-gcc/xattr.o
28612 -rw-r--r-- joerg/bs       6120 2003-10-10 18:07 OBJ/i386-sunos5-gcc/list.o
28613 -rw-r--r-- joerg/bs      12764 2003-10-10 18:07 OBJ/i386-sunos5-gcc/extract.o
28614 -rw-r--r-- joerg/bs      14668 2003-10-10 18:07 OBJ/i386-sunos5-gcc/create.o
28615 -rw-r--r-- joerg/bs       2576 2003-10-10 18:07 OBJ/i386-sunos5-gcc/append.o
28616 -rw-r--r-- joerg/bs       7636 2003-10-10 18:07 OBJ/i386-sunos5-gcc/diff.o
28617 -rw-r--r-- joerg/bs       3072 2003-10-10 18:07 OBJ/i386-sunos5-gcc/remove.o
28618 -rw-r--r-- joerg/bs       5612 2003-10-10 18:07 OBJ/i386-sunos5-gcc/star_unix.o
28619 -rw-r--r-- joerg/bs       6220 2003-10-10 18:07 OBJ/i386-sunos5-gcc/acl_unix.o
28620 -rw-r--r-- joerg/bs       1092 2003-10-10 18:07 OBJ/i386-sunos5-gcc/fflags.o
28621 -rw-r--r-- joerg/bs      20996 2003-10-11 14:32 OBJ/i386-sunos5-gcc/buffer.o
28622 -rw-r--r-- joerg/bs       2060 2003-10-07 17:53 OBJ/i386-sunos5-gcc/dirtime.o
28623 -rw-r--r-- joerg/bs       1664 2003-10-10 18:07 OBJ/i386-sunos5-gcc/lhash.o
28624 -rw-r--r-- joerg/bs      10564 2003-10-10 18:07 OBJ/i386-sunos5-gcc/hole.o
28625 -rw-r--r-- joerg/bs       3864 2003-10-10 18:07 OBJ/i386-sunos5-gcc/longnames.o
28626 -rw-r--r-- joerg/bs       2576 2003-10-10 18:07 OBJ/i386-sunos5-gcc/names.o
28627 -rw-r--r-- joerg/bs        952 2003-10-10 18:07 OBJ/i386-sunos5-gcc/movearch.o
28628 -rw-r--r-- joerg/bs       2756 2003-10-07 17:53 OBJ/i386-sunos5-gcc/table.o
28629 " | $at_diff - "$at_stdout" || at_failed=:
28630 case $at_status in
28631    77) echo 77 > "$at_status_file"; exit 77;;
28632    0) ;;
28633    *) echo "$at_srcdir/multi-fail.at:26: exit code was $at_status, expected 0"
28634       at_failed=:;;
28635 esac
28636 if $at_failed; then
28637
28638
28639   echo 1 > "$at_status_file"
28640   exit 1
28641 fi
28642
28643 $at_traceon
28644
28645
28646       $at_traceoff
28647       $at_times_p && times >"$at_times_file"
28648     ) 5>&1 2>&1 | eval $at_tee_pipe
28649     at_status=`cat "$at_status_file"`
28650     ;;
28651
28652   75 ) # 75. ustar-big-2g.at:21: ustar-big-2g
28653     at_setup_line='ustar-big-2g.at:21'
28654     at_desc="ustar-big-2g"
28655     $at_quiet $ECHO_N " 75: ustar-big-2g                                   $ECHO_C"
28656     at_xfail=no
28657     echo "#                             -*- compilation -*-" >> "$at_group_log"
28658     (
28659       echo "75. ustar-big-2g.at:21: testing ..."
28660       $at_traceon
28661
28662
28663
28664 unset TAR_OPTIONS
28665
28666 $at_traceoff
28667 echo "$at_srcdir/ustar-big-2g.at:26:
28668
28669 cat /dev/null | bzip2 - > /dev/null 2>&1 || exit 77
28670
28671
28672 test -z "$STAR_TESTSCRIPTS" && exit 77
28673 tarball_prereq ustar-big-2g.tar.bz2 b63979733629c8fcdf40b60065422767 $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28674
28675
28676 tar --utc -tvjf \$STAR_TESTSCRIPTS/ustar-big-2g.tar.bz2
28677 "
28678 echo ustar-big-2g.at:26 >"$at_check_line_file"
28679
28680 at_trace_this=
28681 if test -n "$at_traceon"; then
28682     echo 'Not enabling shell tracing (command contains an embedded newline)'
28683 fi
28684
28685 if test -n "$at_trace_this"; then
28686     ( $at_traceon;
28687
28688 cat /dev/null | bzip2 - > /dev/null 2>&1 || exit 77
28689
28690
28691 test -z "$STAR_TESTSCRIPTS" && exit 77
28692 tarball_prereq ustar-big-2g.tar.bz2 b63979733629c8fcdf40b60065422767 $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28693
28694
28695 tar --utc -tvjf $STAR_TESTSCRIPTS/ustar-big-2g.tar.bz2
28696  ) >"$at_stdout" 2>"$at_stder1"
28697     at_status=$?
28698     grep '^ *+' "$at_stder1" >&2
28699     grep -v '^ *+' "$at_stder1" >"$at_stderr"
28700 else
28701     ( :;
28702
28703 cat /dev/null | bzip2 - > /dev/null 2>&1 || exit 77
28704
28705
28706 test -z "$STAR_TESTSCRIPTS" && exit 77
28707 tarball_prereq ustar-big-2g.tar.bz2 b63979733629c8fcdf40b60065422767 $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28708
28709
28710 tar --utc -tvjf $STAR_TESTSCRIPTS/ustar-big-2g.tar.bz2
28711  ) >"$at_stdout" 2>"$at_stderr"
28712     at_status=$?
28713 fi
28714
28715 at_failed=false
28716 echo stderr:; tee stderr <"$at_stderr"
28717 echo >>"$at_stdout"; echo "-rw------- jes/glone 2147483647 2002-06-15 14:53 big
28718 -rw-r--r-- jes/glone          0 2002-06-15 14:53 file
28719 " | $at_diff - "$at_stdout" || at_failed=:
28720 case $at_status in
28721    77) echo 77 > "$at_status_file"; exit 77;;
28722    0) ;;
28723    *) echo "$at_srcdir/ustar-big-2g.at:26: exit code was $at_status, expected 0"
28724       at_failed=:;;
28725 esac
28726 if $at_failed; then
28727
28728
28729   echo 1 > "$at_status_file"
28730   exit 1
28731 fi
28732
28733 $at_traceon
28734
28735
28736
28737 cat >stderr.re <<'_ATEOF'
28738 tar: Record size = .*
28739 _ATEOF
28740
28741 awk '{print NR " " $0}' stderr > $$.1
28742 awk '{print NR " " $0}' stderr.re | join - $$.1 |
28743 while read NUM RE LINE
28744 do
28745   echo "$LINE" | grep -- "$RE" >/dev/null || exit 1
28746 done
28747
28748
28749       $at_traceoff
28750       $at_times_p && times >"$at_times_file"
28751     ) 5>&1 2>&1 | eval $at_tee_pipe
28752     at_status=`cat "$at_status_file"`
28753     ;;
28754
28755   76 ) # 76. ustar-big-8g.at:21: ustar-big-8g
28756     at_setup_line='ustar-big-8g.at:21'
28757     at_desc="ustar-big-8g"
28758     $at_quiet $ECHO_N " 76: ustar-big-8g                                   $ECHO_C"
28759     at_xfail=no
28760     echo "#                             -*- compilation -*-" >> "$at_group_log"
28761     (
28762       echo "76. ustar-big-8g.at:21: testing ..."
28763       $at_traceon
28764
28765
28766
28767 unset TAR_OPTIONS
28768
28769 $at_traceoff
28770 echo "$at_srcdir/ustar-big-8g.at:26:
28771
28772 cat /dev/null | bzip2 - > /dev/null 2>&1 || exit 77
28773
28774
28775 test -z "$STAR_TESTSCRIPTS" && exit 77
28776 tarball_prereq ustar-big-8g.tar.bz2 60ff503fa4b8288bef7ada89e9c91b0f $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28777
28778
28779 tar --utc -tvjf \$STAR_TESTSCRIPTS/ustar-big-8g.tar.bz2
28780 "
28781 echo ustar-big-8g.at:26 >"$at_check_line_file"
28782
28783 at_trace_this=
28784 if test -n "$at_traceon"; then
28785     echo 'Not enabling shell tracing (command contains an embedded newline)'
28786 fi
28787
28788 if test -n "$at_trace_this"; then
28789     ( $at_traceon;
28790
28791 cat /dev/null | bzip2 - > /dev/null 2>&1 || exit 77
28792
28793
28794 test -z "$STAR_TESTSCRIPTS" && exit 77
28795 tarball_prereq ustar-big-8g.tar.bz2 60ff503fa4b8288bef7ada89e9c91b0f $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28796
28797
28798 tar --utc -tvjf $STAR_TESTSCRIPTS/ustar-big-8g.tar.bz2
28799  ) >"$at_stdout" 2>"$at_stder1"
28800     at_status=$?
28801     grep '^ *+' "$at_stder1" >&2
28802     grep -v '^ *+' "$at_stder1" >"$at_stderr"
28803 else
28804     ( :;
28805
28806 cat /dev/null | bzip2 - > /dev/null 2>&1 || exit 77
28807
28808
28809 test -z "$STAR_TESTSCRIPTS" && exit 77
28810 tarball_prereq ustar-big-8g.tar.bz2 60ff503fa4b8288bef7ada89e9c91b0f $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28811
28812
28813 tar --utc -tvjf $STAR_TESTSCRIPTS/ustar-big-8g.tar.bz2
28814  ) >"$at_stdout" 2>"$at_stderr"
28815     at_status=$?
28816 fi
28817
28818 at_failed=false
28819 echo stderr:; tee stderr <"$at_stderr"
28820 echo >>"$at_stdout"; echo "-rw------- jes/glone 8589934591 2002-06-15 15:08 8gb-1
28821 -rw-r--r-- jes/glone          0 2002-06-15 14:53 file
28822 " | $at_diff - "$at_stdout" || at_failed=:
28823 case $at_status in
28824    77) echo 77 > "$at_status_file"; exit 77;;
28825    0) ;;
28826    *) echo "$at_srcdir/ustar-big-8g.at:26: exit code was $at_status, expected 0"
28827       at_failed=:;;
28828 esac
28829 if $at_failed; then
28830
28831
28832   echo 1 > "$at_status_file"
28833   exit 1
28834 fi
28835
28836 $at_traceon
28837
28838
28839
28840 cat >stderr.re <<'_ATEOF'
28841 tar: Record size = .*
28842 _ATEOF
28843
28844 awk '{print NR " " $0}' stderr > $$.1
28845 awk '{print NR " " $0}' stderr.re | join - $$.1 |
28846 while read NUM RE LINE
28847 do
28848   echo "$LINE" | grep -- "$RE" >/dev/null || exit 1
28849 done
28850
28851
28852       $at_traceoff
28853       $at_times_p && times >"$at_times_file"
28854     ) 5>&1 2>&1 | eval $at_tee_pipe
28855     at_status=`cat "$at_status_file"`
28856     ;;
28857
28858   77 ) # 77. pax-big-10g.at:21: pax-big-10g
28859     at_setup_line='pax-big-10g.at:21'
28860     at_desc="pax-big-10g"
28861     $at_quiet $ECHO_N " 77: pax-big-10g                                    $ECHO_C"
28862     at_xfail=no
28863     echo "#                             -*- compilation -*-" >> "$at_group_log"
28864     (
28865       echo "77. pax-big-10g.at:21: testing ..."
28866       $at_traceon
28867
28868
28869
28870 unset TAR_OPTIONS
28871
28872 $at_traceoff
28873 echo "$at_srcdir/pax-big-10g.at:26:
28874
28875 cat /dev/null | bzip2 - > /dev/null 2>&1 || exit 77
28876
28877
28878 test -z "$STAR_TESTSCRIPTS" && exit 77
28879 tarball_prereq pax-big-10g.tar.bz2 ca15c23acc8d8bb1f27e60113a5f8bff $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28880
28881
28882 tar --utc -tvjf \$STAR_TESTSCRIPTS/pax-big-10g.tar.bz2
28883 "
28884 echo pax-big-10g.at:26 >"$at_check_line_file"
28885
28886 at_trace_this=
28887 if test -n "$at_traceon"; then
28888     echo 'Not enabling shell tracing (command contains an embedded newline)'
28889 fi
28890
28891 if test -n "$at_trace_this"; then
28892     ( $at_traceon;
28893
28894 cat /dev/null | bzip2 - > /dev/null 2>&1 || exit 77
28895
28896
28897 test -z "$STAR_TESTSCRIPTS" && exit 77
28898 tarball_prereq pax-big-10g.tar.bz2 ca15c23acc8d8bb1f27e60113a5f8bff $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28899
28900
28901 tar --utc -tvjf $STAR_TESTSCRIPTS/pax-big-10g.tar.bz2
28902  ) >"$at_stdout" 2>"$at_stder1"
28903     at_status=$?
28904     grep '^ *+' "$at_stder1" >&2
28905     grep -v '^ *+' "$at_stder1" >"$at_stderr"
28906 else
28907     ( :;
28908
28909 cat /dev/null | bzip2 - > /dev/null 2>&1 || exit 77
28910
28911
28912 test -z "$STAR_TESTSCRIPTS" && exit 77
28913 tarball_prereq pax-big-10g.tar.bz2 ca15c23acc8d8bb1f27e60113a5f8bff $STAR_TESTSCRIPTS $STAR_DATA_URL || exit 77
28914
28915
28916 tar --utc -tvjf $STAR_TESTSCRIPTS/pax-big-10g.tar.bz2
28917  ) >"$at_stdout" 2>"$at_stderr"
28918     at_status=$?
28919 fi
28920
28921 at_failed=false
28922 echo stderr:; tee stderr <"$at_stderr"
28923 echo >>"$at_stdout"; echo "-rw------- jes/glone 10737418240 2002-06-15 21:18 10g
28924 -rw-r--r-- jes/glone           0 2002-06-15 14:53 file
28925 " | $at_diff - "$at_stdout" || at_failed=:
28926 case $at_status in
28927    77) echo 77 > "$at_status_file"; exit 77;;
28928    0) ;;
28929    *) echo "$at_srcdir/pax-big-10g.at:26: exit code was $at_status, expected 0"
28930       at_failed=:;;
28931 esac
28932 if $at_failed; then
28933
28934
28935   echo 1 > "$at_status_file"
28936   exit 1
28937 fi
28938
28939 $at_traceon
28940
28941
28942
28943 cat >stderr.re <<'_ATEOF'
28944 tar: Record size = .*
28945 _ATEOF
28946
28947 awk '{print NR " " $0}' stderr > $$.1
28948 awk '{print NR " " $0}' stderr.re | join - $$.1 |
28949 while read NUM RE LINE
28950 do
28951   echo "$LINE" | grep -- "$RE" >/dev/null || exit 1
28952 done
28953
28954
28955       $at_traceoff
28956       $at_times_p && times >"$at_times_file"
28957     ) 5>&1 2>&1 | eval $at_tee_pipe
28958     at_status=`cat "$at_status_file"`
28959     ;;
28960
28961
28962   * )
28963     echo "$as_me: no such test group: $at_group" >&2
28964     continue
28965     ;;
28966   esac
28967
28968   # Be sure to come back to the suite directory, in particular
28969   # since below we might `rm' the group directory we are in currently.
28970   cd "$at_suite_dir"
28971
28972   case $at_group in
28973     banner-*) ;;
28974     *)
28975       if test ! -f "$at_check_line_file"; then
28976         sed "s/^ */$as_me: warning: /" <<_ATEOF
28977         A failure happened in a test group before any test could be
28978         run. This means that test suite is improperly designed.  Please
28979         report this failure to <bug-tar@gnu.org>.
28980 _ATEOF
28981         echo "$at_setup_line" >"$at_check_line_file"
28982       fi
28983       at_group_count=`expr 1 + $at_group_count`
28984       $at_verbose $ECHO_N "$at_group. $at_setup_line: $ECHO_C"
28985       echo $ECHO_N "$at_group. $at_setup_line: $ECHO_C" >> "$at_group_log"
28986       case $at_xfail:$at_status in
28987         yes:0)
28988             at_msg="UNEXPECTED PASS"
28989             at_xpass_list="$at_xpass_list $at_group"
28990             at_errexit=$at_errexit_p
28991             ;;
28992         no:0)
28993             at_msg="ok"
28994             at_pass_list="$at_pass_list $at_group"
28995             at_errexit=false
28996             ;;
28997         *:77)
28998             at_msg='skipped ('`cat "$at_check_line_file"`')'
28999             at_skip_list="$at_skip_list $at_group"
29000             at_errexit=false
29001             ;;
29002         yes:*)
29003             at_msg='expected failure ('`cat "$at_check_line_file"`')'
29004             at_xfail_list="$at_xfail_list $at_group"
29005             at_errexit=false
29006             ;;
29007         no:*)
29008             at_msg='FAILED ('`cat "$at_check_line_file"`')'
29009             at_fail_list="$at_fail_list $at_group"
29010             at_errexit=$at_errexit_p
29011             ;;
29012       esac
29013       # Make sure there is a separator even with long titles.
29014       echo " $at_msg"
29015       at_log_msg="$at_group. $at_desc ($at_setup_line): $at_msg"
29016       case $at_status in
29017         0|77)
29018           # $at_times_file is only available if the group succeeded.
29019           # We're not including the group log, so the success message
29020           # is written in the global log separately.  But we also
29021           # write to the group log in case they're using -d.
29022           if test -f "$at_times_file"; then
29023             at_log_msg="$at_log_msg     ("`sed 1d "$at_times_file"`')'
29024             rm -f "$at_times_file"
29025           fi
29026           echo "$at_log_msg" >> "$at_group_log"
29027           echo "$at_log_msg" >&5
29028
29029           # Cleanup the group directory, unless the user wants the files.
29030           if $at_debug_p ; then
29031                   {
29032             echo "#! /bin/sh"
29033             echo 'test "${ZSH_VERSION+set}" = set && alias -g '\''${1+"$@"}'\''='\''"$@"'\'''
29034             echo "cd '$at_dir'"
29035             echo 'exec ${CONFIG_SHELL-'"$SHELL"'}' "$0" \
29036                  '-v -d' "$at_debug_args" "$at_group" '${1+"$@"}'
29037             echo 'exit 1'
29038           } >$at_group_dir/run
29039           chmod +x $at_group_dir/run
29040
29041           elif test -d "$at_group_dir"; then
29042             find "$at_group_dir" -type d ! -perm -700 -exec chmod u+rwx \{\} \;
29043             rm -fr "$at_group_dir"
29044           fi
29045           ;;
29046         *)
29047           # Upon failure, include the log into the testsuite's global
29048           # log.  The failure message is written in the group log.  It
29049           # is later included in the global log.
29050           echo "$at_log_msg" >> "$at_group_log"
29051
29052           # Upon failure, keep the group directory for autopsy, and
29053           # create the debugging script.
29054                   {
29055             echo "#! /bin/sh"
29056             echo 'test "${ZSH_VERSION+set}" = set && alias -g '\''${1+"$@"}'\''='\''"$@"'\'''
29057             echo "cd '$at_dir'"
29058             echo 'exec ${CONFIG_SHELL-'"$SHELL"'}' "$0" \
29059                  '-v -d' "$at_debug_args" "$at_group" '${1+"$@"}'
29060             echo 'exit 1'
29061           } >$at_group_dir/run
29062           chmod +x $at_group_dir/run
29063
29064           $at_errexit && break
29065           ;;
29066       esac
29067       ;;
29068   esac
29069 done
29070
29071 # Back to the top directory.
29072 cd "$at_dir"
29073
29074 # Compute the duration of the suite.
29075 at_stop_date=`date`
29076 at_stop_time=`date +%s 2>/dev/null`
29077 echo "$as_me: ending at: $at_stop_date" >&5
29078 case $at_start_time,$at_stop_time in
29079   [0-9]*,[0-9]*)
29080     at_duration_s=`expr $at_stop_time - $at_start_time`
29081     at_duration_m=`expr $at_duration_s / 60`
29082     at_duration_h=`expr $at_duration_m / 60`
29083     at_duration_s=`expr $at_duration_s % 60`
29084     at_duration_m=`expr $at_duration_m % 60`
29085     at_duration="${at_duration_h}h ${at_duration_m}m ${at_duration_s}s"
29086     echo "$as_me: test suite duration: $at_duration" >&5
29087     ;;
29088 esac
29089
29090 # Wrap up the test suite with summary statistics.
29091 at_skip_count=`set dummy $at_skip_list; shift; echo $#`
29092 at_fail_count=`set dummy $at_fail_list; shift; echo $#`
29093 at_xpass_count=`set dummy $at_xpass_list; shift; echo $#`
29094 at_xfail_count=`set dummy $at_xfail_list; shift; echo $#`
29095
29096 at_run_count=`expr $at_group_count - $at_skip_count`
29097 at_unexpected_count=`expr $at_xpass_count + $at_fail_count`
29098 at_total_fail_count=`expr $at_xfail_count + $at_fail_count`
29099
29100 echo
29101 cat <<\_ASBOX
29102 ## ------------- ##
29103 ## Test results. ##
29104 ## ------------- ##
29105 _ASBOX
29106 echo
29107 {
29108   echo
29109   cat <<\_ASBOX
29110 ## ------------- ##
29111 ## Test results. ##
29112 ## ------------- ##
29113 _ASBOX
29114   echo
29115 } >&5
29116
29117 if test $at_run_count = 1; then
29118   at_result="1 test"
29119   at_were=was
29120 else
29121   at_result="$at_run_count tests"
29122   at_were=were
29123 fi
29124 if $at_errexit_p && test $at_unexpected_count != 0; then
29125   if test $at_xpass_count = 1; then
29126     at_result="$at_result $at_were run, one passed"
29127   else
29128     at_result="$at_result $at_were run, one failed"
29129   fi
29130   at_result="$at_result unexpectedly and inhibited subsequent tests."
29131 else
29132   # Don't you just love exponential explosion of the number of cases?
29133   case $at_xpass_count:$at_fail_count:$at_xfail_count in
29134     # So far, so good.
29135     0:0:0) at_result="$at_result $at_were successful." ;;
29136     0:0:*) at_result="$at_result behaved as expected." ;;
29137
29138     # Some unexpected failures
29139     0:*:0) at_result="$at_result $at_were run,
29140 $at_fail_count failed unexpectedly." ;;
29141
29142     # Some failures, both expected and unexpected
29143     0:*:1) at_result="$at_result $at_were run,
29144 $at_total_fail_count failed ($at_xfail_count expected failure)." ;;
29145     0:*:*) at_result="$at_result $at_were run,
29146 $at_total_fail_count failed ($at_xfail_count expected failures)." ;;
29147
29148     # No unexpected failures, but some xpasses
29149     *:0:*) at_result="$at_result $at_were run,
29150 $at_xpass_count passed unexpectedly." ;;
29151
29152     # No expected failures, but failures and xpasses
29153     *:1:0) at_result="$at_result $at_were run,
29154 $at_unexpected_count did not behave as expected ($at_fail_count unexpected failure)." ;;
29155     *:*:0) at_result="$at_result $at_were run,
29156 $at_unexpected_count did not behave as expected ($at_fail_count unexpected failures)." ;;
29157
29158     # All of them.
29159     *:*:1) at_result="$at_result $at_were run,
29160 $at_xpass_count passed unexpectedly,
29161 $at_total_fail_count failed ($at_xfail_count expected failure)." ;;
29162     *:*:*) at_result="$at_result $at_were run,
29163 $at_xpass_count passed unexpectedly,
29164 $at_total_fail_count failed ($at_xfail_count expected failures)." ;;
29165   esac
29166
29167   if test $at_skip_count = 0 && test $at_run_count -gt 1; then
29168     at_result="All $at_result"
29169   fi
29170 fi
29171
29172 # Now put skips in the mix.
29173 case $at_skip_count in
29174   0) ;;
29175   1) at_result="$at_result
29176 1 test was skipped." ;;
29177   *) at_result="$at_result
29178 $at_skip_count tests were skipped." ;;
29179 esac
29180
29181 if test $at_unexpected_count = 0; then
29182   echo "$at_result"
29183   echo "$at_result" >&5
29184 else
29185   echo "ERROR: $at_result" >&2
29186   echo "ERROR: $at_result" >&5
29187   {
29188     echo
29189     cat <<\_ASBOX
29190 ## ------------------------ ##
29191 ## Summary of the failures. ##
29192 ## ------------------------ ##
29193 _ASBOX
29194
29195     # Summary of failed and skipped tests.
29196     if test $at_fail_count != 0; then
29197       echo "Failed tests:"
29198       $SHELL "$0" $at_fail_list --list
29199       echo
29200     fi
29201     if test $at_skip_count != 0; then
29202       echo "Skipped tests:"
29203       $SHELL "$0" $at_skip_list --list
29204       echo
29205     fi
29206     if test $at_xpass_count != 0; then
29207       echo "Unexpected passes:"
29208       $SHELL "$0" $at_xpass_list --list
29209       echo
29210     fi
29211     if test $at_fail_count != 0; then
29212       cat <<\_ASBOX
29213 ## ---------------------- ##
29214 ## Detailed failed tests. ##
29215 ## ---------------------- ##
29216 _ASBOX
29217       echo
29218       for at_group in $at_fail_list
29219       do
29220         at_group_normalized=$at_group
29221
29222   while :; do
29223     case $at_group_normalized in #(
29224     $at_format*) break;;
29225     esac
29226     at_group_normalized=0$at_group_normalized
29227   done
29228
29229         cat "$at_suite_dir/$at_group_normalized/$as_me.log"
29230         echo
29231       done
29232       echo
29233     fi
29234     if test -n "$at_top_srcdir"; then
29235       sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
29236 ## ${at_top_build_prefix}config.log ##
29237 _ASBOX
29238       sed 's/^/| /' ${at_top_build_prefix}config.log
29239       echo
29240     fi
29241   } >&5
29242
29243   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
29244 ## $as_me.log was created. ##
29245 _ASBOX
29246
29247   echo
29248   echo "Please send \`${at_testdir+${at_testdir}/}$as_me.log' and all information you think might help:"
29249   echo
29250   echo "   To: <bug-tar@gnu.org>"
29251   echo "   Subject: [GNU tar 1.21] $as_me:$at_fail_list${at_fail_list:+ failed${at_xpass_list:+,}}$at_xpass_list${at_xpass_list:+ passed unexpectedly}"
29252   echo
29253   if test $at_debug_p = false; then
29254     echo
29255     echo 'You may investigate any problem if you feel able to do so, in which'
29256     echo 'case the test suite provides a good starting point.  Its output may'
29257     echo "be found below \`${at_testdir+${at_testdir}/}$as_me.dir'."
29258     echo
29259   fi
29260     exit 1
29261 fi
29262
29263 exit 0
29264
29265
29266