This is the mail archive of the cygwin-apps mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: upload: diffstat-1.40-1, tar-1.15.1-1


On Wed, Aug 17, 2005 at 05:04:32PM +0200, Corinna Vinschen wrote:
>On Aug 17 10:56, Christopher Faylor wrote:
>> On Wed, Aug 17, 2005 at 06:24:50AM -0600, Eric Blake wrote:
>> >tar: new maintainer, new upstream release.  Instead of linking against
>> >binmode.o and forcing text mode on the exceptions even on binary mounts,
>> 
>> I'm not sure what the above is implying but I didn't link with binmode.o
>> when I packaged tar.
>> 
>> >I fixed the source code to always request bin mode on the files where
>> >it matters, so that text files are created according to the mount
>> >point's mode.
>> 
>> This is not a fix.  It is a change in philosophy.  If you changed things
>> so that reading a file via -T uses the mount mode or if you changed it
>> so that reading the incremental information uses the mount mode, it
>> is actually a bug.
>> 
>> The philosophy that Corinna and I have decided upon for cygwin tools is
>> basically what is available with automode.o.  This makes the default
>> such that you open for read in text mode and open for write in binary
>> mode.  This produces files which do not have the CRLF line endings which
>> is appropriate since cygwin is a linux emulation.
>
>Am I missing something or shouldn't tar be one of those applications
>which should recreate *exactly* what they got?  In other words, shouldn't
>using binmode under all circumstances, regardless of mount mode, file
>type, or moon phase, be the way to go for tar?

When tar is extracting or storing files it should always create exactly
what it got, yes.

tar creates at least one file which is a "text" file when it is doing
incremental backups.  I'm saying that this file should always have
LF line endings.  Also, when reading a list of files via -T, it should
always read in text mode.

So, to summarize, there are several places within tar which operate on
"text" files.  I'm saying that they should ALWAYS be opened for read in
text mode and for write in binmode.  When performing a normal creation
or extraction, the file should always be opened in binmode.

cgf


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]