bug-automake
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

recent GNU tar does not deal well with long paths and -o


From: Raphaël Poss
Subject: recent GNU tar does not deal well with long paths and -o
Date: Fri, 26 Mar 2004 09:19:27 +0100
User-agent: Mozilla Thunderbird 0.5 (X11/20040306)

Hi,

Using:
  Automake 1.8, GNU tar 1.13.93, on Debian GNU/Linux unstable x86
  Automake 1.5, GNU tar 1.13.25, on Debian GNU/Linux stable x86

Problem:

  Automake (all versions) calls tar with option -o.

  GNU tar does not support long file names with -o in recent versions.
  (test case below)

  Because of this, "make dist" using Automake fails to distribute
  files properly.

Suggestion:

  1) Add warning in GNU tar when long file names cannot be handled.
  2) do not use -o in Automake, or add error condition when long
     paths are detected.
  3) in Automake, compare the file listing and the directory tree
     after the archive is created.

Test case, using tar 1.13.93 :

 $ # Cleanup
 $ rm -rf this_is*

 $ # Creating some test data
 $ mkdir this_is_a_very_long_name_for_a_directory_which_causes_problems
 $ touch this_is*/this_is_a_very_long_file_name_which_raises_issues.c

 $ # Creating an archive in compat mode
 $ tar -chof - this_is*/ >foo.tar

 $ # Uncompressing the archive and test
 $ rm -rf this_is* && tar -xf foo.tar && ls
 this_is_a_very_long_name_for_a_directory_which_causes_problems/
 this_is_a_very_long_file_name_which_raises_issues.c

Note how the file was not prepended with its directory name. Running "hexdump" on the archive file shows that the directory name is not stored in front of the file name.

GNU tar 1.13.25 does not exhibit this behaviour.

Regards,
rp

--
.                                                  . . _ - --------\
: Raphaël Poss                  JID address@hidden · ICQ 1757157 |
| EPITA CSI 2003 · http://raphael.poss.name · GnuPG fp ...3b72e72b :
\------ - _ . .                                                    '

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]