docs/82705: [PATCH] porters handbook - 4.6 patching - add note for context l

Pav Lucistnik pav at
Fri Jul 15 07:35:23 UTC 2005

Woody Carey píše v čt 14. 07. 2005 v 22:10 -0700:

> Key words:  "if you generate your patch from WRKDIR".  To do this is not 
> explicitly stated
> in the porters handbook.  Maybe add it?

Section 4.4 Patching have this sentence:

All patches should be relative to WRKSRC (generally the directory your
port's tarball unpacks itself into, that being where the build is done).

That's exactly what I had on mind. Maybe I'll change "should" to "must".

> Slow Porting:
> Write your port makefile in stages:
> 1) write it to 'make fetch' the tarball
> 2) write the part that does the 'extract'
> 3) Now hack on it in WRKDIR and generate your diffs from their, so that your 
> patches will apply cleanly.  Write your 'patch' target. (or do-patch or 
> $PATCH or whatever)
> 4) Now add your 'configure', 'build' and 'install' stages incrementally.

That's how every sane people do it, yes. But we're not writing How-To,
but a comprehensive Handbook which documents all possible aspect of
ports infrastructure. So this does not fit much in now.

Pav Lucistnik <pav at>
              <pav at>

On real UNIX, /usr/bin/more prints -More-.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 187 bytes
Desc: This is a digitally signed message part
URL: <>

More information about the freebsd-doc mailing list