description GNU patch, for applying diffs to files
Patch takes a patch file containing a difference listing produced by the \
diff program and applies those differences to one or more original files, \
producing patched versions.
homepage http://www.gnu.org/software/patch/
distname patch-${version}
checksums rmd160 48c39a34ab3bf6c86da8d107f5687a9f56a6b638 \
sha256 aae676de9e95051f425af4507fcc9a019941a2a1f78405e7dbd40bccf786aa11
configure.args --program-prefix=g
xinstall -m 755 -d ${destroot}${prefix}/libexec/gnubin
foreach binary [glob -tails -directory ${destroot}${prefix}/bin g*] {
ln -s ${prefix}/bin/${binary} ${destroot}${prefix}/libexec/gnubin/[string range $binary 1 end]
xinstall -m 755 -d ${destroot}${prefix}/libexec/gnubin/man/man1
foreach manpage [glob -tails -directory ${destroot}${prefix}/share/man/man1 g*] {
ln -s ${prefix}/share/man/man1/${manpage}.gz ${destroot}${prefix}/libexec/gnubin/man/man1/[string range $manpage 1 end].gz
The patch tool provided by this port is prefixed with the character 'g' by default making it available as 'gpatch'.
If you want to use 'patch' and other GNU coreutils by default, add this directory to the front of your PATH environment variable:
${prefix}/libexec/gnubin/