RFC: Minor specfile rework for rawhide
Chuck Ebbert
cebbert at redhat.com
Tue Jan 22 18:47:09 UTC 2008
On 01/21/2008 05:22 PM, Adam Jackson wrote:
> http://people.freedesktop.org/~ajax/kernel-autopatch.patch
>
Using the below script, based on what you suggested, we can add lines like
this to specify patch options:
Patch101: a.patch
PATCH101_OPTS=-R -F2
And this to skip a patch:
Patch101: a.patch
PATCH101_OPTS=SKIP
With this change I'd say go for it.
awk '/^Patch.*:/ { print $1" %{_sourcedir}/"$2 }' %{_specdir}/%{name}.spec |
while read num patch ; do
optfield="$( echo $num | cut -f 1 -d : | tr [:lower:] [:upper:] )_OPTS"
opts="$( cat %{_specdir}/%{name}.spec | grep ^${optfield} | cut -f 2 -d = )"
[[ $opts == "SKIP" ]] && continue
if ! ApplyPatch "$patch" $opts ; then
set +x
echo Failed to apply $(basename $patch).
exit 1
fi
done || exit 1
More information about the Fedora-kernel-list
mailing list