- Avoid literal appearances of "$FreeBSD:...$" in patch-util_diff.in. - While we are here: - Make the affected sed pattern more flexible with regard to the repository path from which the port was checked out. - When handling -d <dir>, if the port's directory does not exist, fix the path used in the first check for an alternative path. - Bump PORTREVISION. @committer: the patch below of files/patch-util_diff.in might fail, because of differing implementations of the expansion of "$FreeBSD:...$FreeBSD:...$". The patch below ist against the current version of the port as obtained with cvs, which expands both instances of "$FreeBSD:...$" in the sed pattern (which used to set PORTBASENAME_HEADER in util_diff). In a ports tree obtained by csup, only the first "$FreeBSD:...$" is expanded, but not the second one (possibly because they overlap at the "$"). So if this hunk of the patch fails for you, please manually replace line 93 of files/patch-util_diff.in with its new version: + PORTBASENAME_HEADER=`sed -n -E -e '1,/^($|[^#].*$)|\\$FreeBSD\:/s%^#.*\\$FreeBSD\:[[:space:]]*([^/]+/)*([^/]+)/Makefile.*\\$%\2%p' Makefile` Sorry for any inconvenience - but ports dealing with ports seem to have an increased fun factor:-) Generated with FreeBSD Port Tools 0.99_6 (mode: change, diff: CVSauto)
Oops, I didn't include the How-To-Repeat section in my first mail. So here's an easy way to see the broken sed pattern "at work", which is caused by CVS expansion of "$FreeBSD:...$" in the checked out version of ports-mgmt/porttools/files/patch-util_diff.in: >How-To-Repeat: % cd /usr/ports/ports-mgmt/porttools % grep FreeBSD Makefile # $FreeBSD: ports/ports-mgmt/porttools/Makefile,v 1.31 2012/04/01 20:06:07 amdmi3 Exp $ % port | head -1 FreeBSD Port Tools 0.99_5 % port submit -P | head -4 Default diff mode is /usr/ports sed: 1: "1,/^($|[^#].*$)|\$FreeB ...": extra characters at the end of p command Warning: current directory name differs from Makefile header: porttools != ===> Generating patch %
Responsible Changed From-To: freebsd-ports-bugs->dhn I'll take it.
State Changed From-To: open->closed Committed. Thanks!
dhn 2012-04-28 07:58:13 UTC FreeBSD ports repository Modified files: ports-mgmt/porttools Makefile ports-mgmt/porttools/files patch-util_diff.in Log: - Avoid literal appearances of "$FreeBSD:...$" in patch-util_diff.in. - While we are here: - Make the affected sed pattern more flexible with regard to the repository path from which the port was checked out. - When handling -d <dir>, if the port's directory does not exist, fix the path used in the first check for an alternative path. - Bump PORTREVISION. PR: ports/166593 Submitted by: Johannes Joemann <joemann@beefree.free.de> (maintainer) Revision Changes Path 1.32 +1 -1 ports/ports-mgmt/porttools/Makefile 1.6 +2 -2 ports/ports-mgmt/porttools/files/patch-util_diff.in _______________________________________________ cvs-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/cvs-all To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"