Fix build on cygwin: Normalise slashes in .depend files to be /
[ghc-hetmet.git] / rules / build-package.mk
index b4763b6..cd02646 100644 (file)
@@ -133,7 +133,7 @@ $(call includes-sources,$1,$2)
 $1_$2_WAYS_DASHED = $$(subst $$(space),,$$(patsubst %,-%,$$(strip $$($1_$2_WAYS))))
 $1_$2_depfile_base = $1/$2/build/.depend$$($1_$2_WAYS_DASHED)
 
-$(call build-dependencies,$1,$2)
+$(call build-dependencies,$1,$2,$3)
 
 # --- BUILDING
 
@@ -161,7 +161,9 @@ $$(foreach way,$$($1_$2_WAYS),$$(eval \
     $$(call build-package-way,$1,$2,$$(way),$3) \
   ))
 
+ifneq "$$($1_$2_HADDOCK_ME)" "NO"
 $(call haddock,$1,$2)
+endif
 
 endif # package-data.mk exists