make-rules/prep.mk
changeset 18 6da6bd662127
parent 12 41aeb1fd8c2d
child 34 d20b10eba317
--- a/make-rules/prep.mk	Thu Jun 10 15:08:47 2010 -0500
+++ b/make-rules/prep.mk	Thu Jun 10 15:16:47 2010 -0500
@@ -22,13 +22,14 @@
 #
 
 UNPACK =	$(TOOLS)/unpack.py
+FETCH =		$(TOOLS)/fetch.py
 
 ARCHIVES += $(COMPONENT_ARCHIVE)
 CLEAN_PATHS += $(COMPONENT_SRC)
 CLOBBER_PATHS += $(COMPONENT_ARCHIVE)
 
 PATCHES =	$(shell find . -type f -name '*.patch' | \
-			 sed -e 's;^\./;;' | sort)
+			 sed -e 's;^\./;;' | grep -v $(COMPONENT_SRC) | sort)
 STAMPS =	$(PATCHES:%=$(COMPONENT_SRC)/.%ed)
 
 $(COMPONENT_SRC)/.%ed:	%
@@ -36,7 +37,9 @@
 	$(TOUCH) [email protected]
 
 $(COMPONENT_ARCHIVE):
-	wget $(COMPONENT_ARCHIVE_URL)
+	$(FETCH) --file [email protected] \
+		$(COMPONENT_ARCHIVE_URL:%=--url %) \
+		$(COMPONENT_ARCHIVE_HASH:%=--hash %)
 
 $(COMPONENT_SRC)/.unpacked:	$(COMPONENT_ARCHIVE)
 	$(UNPACK) $(UNPACK_ARGS) $(COMPONENT_ARCHIVE)