eliminate "warning: overriding commnds..." from make when we're cleaning
[ghc-hetmet.git] / rules / build-perl.mk
index 468572c..5740676 100644 (file)
@@ -34,6 +34,8 @@ $(call clean-target,$1,$2,$1/$2 $$($1_$2_INPLACE))
 .PHONY: clean_$1
 clean_$1 : clean_$1_$2
 
+# INPLACE_BIN etc. might be empty if we're cleaning
+ifeq "$(findstring clean,$(MAKECMDGOALS))" ""
 ifneq "$$(BINDIST)" "YES"
 $1/$2/$$($1_$2_PROG).prl: $1/$$($1_PERL_SRC) $$(UNLIT)
        "$$(MKDIRHIER)" $1/$2
@@ -53,5 +55,6 @@ $$($1_$2_INPLACE): $1/$2/$$($1_$2_PROG)
        "$$(CP)" $$< $$@
        $$(EXECUTABLE_FILE) $$@
 endif
+endif
 
 endef