Fix building of optional packages
authorIan Lynagh <igloo@earth.li>
Sun, 12 Jun 2011 18:58:04 +0000 (19:58 +0100)
committerIan Lynagh <igloo@earth.li>
Sun, 12 Jun 2011 19:00:43 +0000 (20:00 +0100)
The change to the packages file format broke it

packages
rules/extra-packages.mk

index 1489f3e..923b620 100644 (file)
--- a/packages
+++ b/packages
@@ -1,5 +1,8 @@
 # Despite the name "package", this file contains the master list of 
-# the *repositories* that make up GHC. It is parsed by boot and sync-all.
+# the *repositories* that make up GHC. It is parsed by
+# * boot
+# * sync-all
+# * rules/extra-packages.mk
 #
 # Some of this information is duplicated elsewhere in the build system:
 #    See Trac #3896
index 1cef9ad..e3af94f 100644 (file)
@@ -27,7 +27,7 @@
 #        add P to the list of packages
 
 define extra-packages
-$$(foreach p,$$(patsubst libraries/%,%,$$(wildcard $$(shell grep '^[^ #][^ ]* \+\(dph\|extra\) \+[^ ]\+ \+[^ ]\+ \+[^ ]\+' packages | sed 's/ .*//'))),\
+$$(foreach p,$$(patsubst libraries/%,%,$$(wildcard $$(shell grep '^[^ #][^ ]* \+\(dph\|extra\) \+[^ ]\+ \+[^ ]\+$$$$' packages | sed 's/ .*//'))),\
     $$(if $$(wildcard libraries/$$p/ghc-packages),\
         $$(eval BUILD_DIRS += libraries/$$p) \
         $$(foreach q,$$(shell cat libraries/$$p/ghc-packages2),$$(eval $$(call extra-package,$$p,$$p/$$q))),\