common Makefile.common,1.142,1.143

Dennis Gilmore ausil at fedoraproject.org
Mon Jun 28 21:39:24 UTC 2010


Author: ausil

Update of /cvs/pkgs/common
In directory cvs01.phx2.fedoraproject.org:/tmp/cvs-serv15543

Modified Files:
	Makefile.common 
Log Message:
more robust unused patch checking courtosy of https://fedorahosted.org/fedora-infrastructure/ticket/1881



Index: Makefile.common
===================================================================
RCS file: /cvs/pkgs/common/Makefile.common,v
retrieving revision 1.142
retrieving revision 1.143
diff -u -p -r1.142 -r1.143
--- Makefile.common	30 Apr 2010 01:26:26 -0000	1.142
+++ Makefile.common	28 Jun 2010 21:39:23 -0000	1.143
@@ -700,7 +700,7 @@ unused-patches:
 	@for f in *.patch; do if [ -e $$f ]; then grep -q $$f $(SPECFILE) || echo $$f; fi; done
 
 unused-fedora-patches:
-	@for f in *.patch; do if [ -e $$f ]; then (egrep -q "^Patch[[:digit:]]+:[[:space:]]+$$f" $(SPECFILE) || echo "Unused:    $$f") && egrep -q "^ApplyPatch[[:space:]]+$$f" $(SPECFILE) || echo "Unapplied: $$f"; fi; done
+	@for f in *.patch; do if [ -e $$f ]; then n="$$(sed -n "s/^Patch\([[:digit:]]\+\):[[:space:]]\+$$f$$/\1/p" <$(SPECFILE))"; (test -n "$$n" || echo "Unused:    $$f"); grep -q "^\(ApplyPatch[[:space:]]\+$$f$$\|%patch$$n\($$\| \)\)" $(SPECFILE) || echo "Unapplied: $$f"; fi; done
 
 ##################### EXPERIMENTAL ##########################
 # this stuff is very experimental in nature and should not be



More information about the scm-commits mailing list