Move all the warning workarounds to one place
authorIan Lynagh <igloo@earth.li>
Sat, 10 Jul 2010 16:17:23 +0000 (16:17 +0000)
committerIan Lynagh <igloo@earth.li>
Sat, 10 Jul 2010 16:17:23 +0000 (16:17 +0000)
ghc.mk
mk/validate-settings.mk

diff --git a/ghc.mk b/ghc.mk
index 1c41a4a..299fcb9 100644 (file)
--- a/ghc.mk
+++ b/ghc.mk
@@ -647,18 +647,6 @@ GhcBootLibHcOpts += -fno-warn-deprecated-flags
 # Add $(GhcLibHcOpts) to all library builds
 $(foreach pkg,$(PACKAGES) $(PACKAGES_STAGE2),$(eval libraries/$(pkg)_dist-install_HC_OPTS += $$(GhcLibHcOpts)))
 
-# XXX Hack; remove this
-# Use -Wwarn for dph
-$(foreach pkg,$(PACKAGES_STAGE2),$(eval libraries/$(pkg)_dist-install_HC_OPTS += -Wwarn))
-
-# XXX Hack; remove this
-# Use -Wwarn for 'binary' becuase it has redundant UNPACK pragmas
-libraries/binary_dist-install_HC_OPTS += -Wwarn
-libraries/binary_dist-boot_HC_OPTS += -Wwarn
-
-# XXX hack: haskeline has warnings about deprecated use of block/unblock
-libraries/haskeline_dist-install_HC_OPTS += -Wwarn
-
 # ----------------------------------------------
 # A useful pseudo-target
 .PHONY: stage1_libs
index 31c8853..e52a7cc 100644 (file)
@@ -37,13 +37,29 @@ GhcStage2HcOpts += -XGenerics -DDEBUG
 GhcLibHcOpts    += -XGenerics
 endif
 
+######################################################################
+# Disable some warnings in packages we use
+
 # Temporarily turn off unused-do-bind warnings for the time package
 libraries/time_dist-install_EXTRA_HC_OPTS += -fno-warn-unused-do-bind
 # On Windows, there are also some unused import warnings
 libraries/time_dist-install_EXTRA_HC_OPTS += -fno-warn-unused-imports
 
+# haskeline has warnings about deprecated use of block/unblock
+libraries/haskeline_dist-install_EXTRA_HC_OPTS += -fno-warn-deprecations
 libraries/haskeline_dist-install_EXTRA_HC_OPTS += -fno-warn-unused-imports
 
 # Temporarily turn off unused-import warnings for the binary package
 libraries/binary_dist-boot_EXTRA_HC_OPTS += -fno-warn-unused-imports
 libraries/binary_dist-install_EXTRA_HC_OPTS += -fno-warn-unused-imports
+# binary has unusable UNPACK pragmas
+libraries/binary_dist-boot_EXTRA_HC_OPTS += -Wwarn
+libraries/binary_dist-install_EXTRA_HC_OPTS += -Wwarn
+
+libraries/dph/dph-base_dist-install_EXTRA_HC_OPTS += -Wwarn
+libraries/dph/dph-prim-interface_dist-install_EXTRA_HC_OPTS += -Wwarn
+libraries/dph/dph-prim-seq_dist-install_EXTRA_HC_OPTS += -Wwarn
+libraries/dph/dph-prim-par_dist-install_EXTRA_HC_OPTS += -Wwarn
+libraries/dph/dph-seq_dist-install_EXTRA_HC_OPTS += -Wwarn
+libraries/dph/dph-par_dist-install_EXTRA_HC_OPTS += -Wwarn
+