--- a/make-rules/prep-patch.mk Fri Sep 02 16:39:26 2016 -0500
+++ b/make-rules/prep-patch.mk Thu Sep 08 17:49:01 2016 -0700
@@ -57,7 +57,11 @@
-name '$(PATCH_PATTERN)' 2>/dev/null | \
LC_COLLATE=C sort)
-PCH_SUFFIXES = $(patsubst .patch_%,%, $(filter-out .patch,$(suffix $(PATCHES))))
+# Patches for different source tarballs have _X filename extensions to
+# match the _X extensions to the COMPONENT_* make variables. Find these
+# extensions, using $(sort) to uniq them to prevent multiple rules from
+# getting generated.
+PCH_SUFFIXES = $(sort $(patsubst .patch_%,%, $(filter-out .patch,$(suffix $(PATCHES)))))
define patch-rule