Patches for NetBSD and pkgsrc

This repository contains my patches for various pkgsrc packages as
well as the NetBSD distribution itself. It also contains scripts
that make it easier to write patches.

The pkg* scripts are designed to be used in conjunction with the
scripts from the pkgtools/pkgdiff package, as they depend on the
existence of .orig files. The *ex scripts operate on existing
patches, i.e. those in ~/patches.

   Use `pkgdiffs' to make a patch containing multiple changes.
   Use `pkgdiffex' to make a patch containing new changes only.
   Use `pkgpatch' to apply a patch to a source directory.
   Use `pkgpatchex' to apply all existing patches.
   Use `pkgundo' to reinstate the original files.

The following scripts do not depend on pkgtools/pkgdiff:

   Use `convpatch' to make a patch from `git diff' output.
   Use `savepatch' to save a patch in ~/patches.
   Use `psu' to undo all patches applied to a pkgsrc build.
   Use `psx' to fetch and extract a pkgsrc package.

The `psu' and `psx' scripts are only to be used within pkgsrc
package directories. They do nothing within the NetBSD source tree.

                    Applying pkgsrc patches

To have `make do-patch' apply local patches, be sure to set the
LOCALPATCHES variable in mk.conf:

	echo LOCALPATCHES = ~/patches >> /etc/mk.conf

To rebuild a package with new patches, something along the following
lines should be performed:

	psu -x
	make do-patch
	make do-build
	make do-install
	# pkg_delete PACKAGE
	make reinstall # or make replace