On 10/21/2011 12:17 PM, David Lowe wrote:
> Okeh, so i'm trying to apply a new patch to the latest version of
> FreeCiv. I thought i was really getting the hang of this - i made the patch
> as a p1 rather than p0, etc. Then when fink goes to build the package, the
> build stops because the checksums do not match, where the field for the
> expected checksum is blank. Deleting the reference to the Patch-MD5 didn't
> make a difference, what am i doing wrong?
A few points on what you attached:
1) The field is PatchFile-MD5, not Patch-MD5 like you have. The value
"a18d8aae141db0f71a05155b2bbfbc5f" is correct for the current patch as
you have supplied it.
2) The easiest way to make a patch that will feed into PatchScript is to
make a patched copy of the source that sits alongside the original
(which you have already done based on the submitted patch). Then, from
the directory that's above both sources (i.e. /Users/davidlowe/Downloads
in your example), run the 'diff' command using relative paths:
diff -Naur freeciv-2.3.0 freeciv-2.3.0-patched
This gives a patch that gets applied by -p1 (the default PatchScript
level). You can go deeper into the hierarchy
(freeciv.2.3.0-patched/utility/netintf.c) if you want, but running it
from the level that contains the original and source trees is the easiest.
3) Your PatchScript doesn't use the PatchFile. Since you're adding a
step to the default script (the perl line), your PatchScript should
probably look like this:
PatchScript: <<
%{default_script} <- this applies the patch using the default
perl -pi -e ..... <- what you have now
<<
Hanspeter
------------------------------------------------------------------------------
The demand for IT networking professionals continues to grow, and the
demand for specialized networking skills is growing even more rapidly.
Take a complimentary Learning@Cisco Self-Assessment and learn
about Cisco certifications, training, and career opportunities.
http://p.sf.net/sfu/cisco-dev2dev
_______________________________________________
Fink-devel mailing list
[email protected]
List archive:
http://news.gmane.org/gmane.os.apple.fink.devel
Subscription management:
https://lists.sourceforge.net/lists/listinfo/fink-devel