patchfiles and specifying -p
Rainer Müller
raimue at macports.org
Mon May 17 03:59:31 PDT 2010
On 2010-05-16 01:59 , Blair Zajac wrote:
>>> The format could be
>>>
>>> patchfiles foo.diff:2
>>>
>>> which would be equivalent to "patch -p2 < foo.diff".
>>
>> The colon is already being used to specify subdirectories and tags for
>> fetching in the same way as it is being used in distfiles:
>>
>> patchfiles foo.diff:tag
>> patchfiles foo.diff:subdir:tag
>
> Maybe then # to indicate the number of directories to trim?
Whatever syntax we choose, it should probably be generalized to allow
any special patch options to be passed. I agree that -p will probably be
the most used argument. But it could also be required to ignore
whitespace with -l or increase the fuzz factor with -F.
Just adding another colon separated parameter looks a bit strange if you
have no subdir or tag or just one of them:
patchfiles foo.diff:subdir:tag:-p2
patchfiles foo.diff::tag:-p2
patchfiles foo.diff:subdir::-p2
patchfiles foo.diff:::-p2
Another option would be to make it a list:
patchfiles {foo.diff -p2} bar.diff
Other ideas?
Rainer
More information about the macports-dev
mailing list