Jean Delvare wrote:
On 2005-08-10, Jerome Lacoste wrote:
I am having problems to generate a patch with a new empty file.
Wow, great timing. I've just been updating the version of quilt we use
locally, and I have a patch for this that I was planning to propose to
add to quilt.
As you found out, this is caused by a limitations in diff (or more
precisely, in the diff output format, which is even worse). As long as
quilt uses diff to generate patch files, there's anything we can do.
Actually, there is. The problem is that quilt forces the "-E" option
when it invokes patch. If this option is not specified, patch can
determine the difference between an empty file and a removed or added
file by looking at the patch file names (/dev/null "to" file means
removed, on "from" file means added) or the file timestamps (epoch means
removed/added).
The only downside I can see is that some people may not be generating
patches with the correct headers (e.g., not using "-N" option to diff).
quilt generates correct headers on the patches it creates or refreshes.
I would suggest removing the "-E" on patch application, and letting
users add it to "QUILT_PATCH_OPTS" if they wish to.
I've attached a sample patch to remove this option. Warning: I've just
updated this to 0.42; I haven't tested it yet, but it's fairly
straightforward.
--
Joe Green <[EMAIL PROTECTED]>
MontaVista Software, Inc.
_______________________________________________
Quilt-dev mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/quilt-dev