--- libraries/Makefile.sav	2009-08-27 08:24:39.000000000 -0400
+++ libraries/Makefile	2009-08-27 08:29:44.000000000 -0400
@@ -123,7 +123,7 @@
 
 HERE_ABS=$(FPTOOLS_TOP_ABS)/libraries
 
-CABAL_GHC_FLAGS = -Wall
+CABAL_GHC_FLAGS = -Wall -pgmP "XXPATH_TO_GCCXX -E -undef -traditional" -pgmc XXPATH_TO_GCCXX -pgml XXPATH_TO_GCCXX -pgma XXPATH_TO_GCCXX
 ifeq "$(ghc_ge_605)" "NO"
 CABAL_GHC_FLAGS += -cpp
 endif
@@ -141,19 +141,19 @@
 bootstrapping.conf: cabal-bin
 	echo "[]" > $@.tmp
 	-cd extensible-exceptions && $(CABAL) clean     --distpref=dist-bootstrapping
-	cd extensible-exceptions && $(CABAL) configure --distpref=dist-bootstrapping --with-compiler=$(GHC) --with-hc-pkg=$(GHC_PKG) --package-db=$(HERE_ABS)/$@.tmp
+	cd extensible-exceptions && $(CABAL) configure  --distpref=dist-bootstrapping --with-compiler=$(GHC) --with-gcc=XXPATH_TO_GCCXX --ghc-options='$(CABAL_GHC_FLAGS)' --with-hc-pkg=$(GHC_PKG) --package-db=$(HERE_ABS)/$@.tmp
 	cd extensible-exceptions && $(CABAL) build     --distpref=dist-bootstrapping
 	cd extensible-exceptions && $(CABAL) install   --distpref=dist-bootstrapping --inplace
 	-cd filepath && $(CABAL) clean     --distpref=dist-bootstrapping
-	cd filepath && $(CABAL) configure --distpref=dist-bootstrapping --with-compiler=$(GHC) --with-hc-pkg=$(GHC_PKG) --package-db=$(HERE_ABS)/$@.tmp
+	cd filepath && $(CABAL) configure  --distpref=dist-bootstrapping --with-compiler=$(GHC) --with-gcc=XXPATH_TO_GCCXX --ghc-options='$(CABAL_GHC_FLAGS)' --with-hc-pkg=$(GHC_PKG) --package-db=$(HERE_ABS)/$@.tmp
 	cd filepath && $(CABAL) build     --distpref=dist-bootstrapping
 	cd filepath && $(CABAL) install   --distpref=dist-bootstrapping --inplace
 	-cd Cabal    && $(CABAL) clean     --distpref=dist-bootstrapping
-	cd Cabal    && $(CABAL) configure --distpref=dist-bootstrapping --with-compiler=$(GHC) --with-hc-pkg=$(GHC_PKG) --package-db=$(HERE_ABS)/$@.tmp
+	cd Cabal    && $(CABAL) configure  --distpref=dist-bootstrapping --with-compiler=$(GHC) --with-gcc=XXPATH_TO_GCCXX --ghc-options='$(CABAL_GHC_FLAGS)' --with-hc-pkg=$(GHC_PKG) --package-db=$(HERE_ABS)/$@.tmp
 	cd Cabal    && $(CABAL) build     --distpref=dist-bootstrapping
 	cd Cabal    && $(CABAL) install   --distpref=dist-bootstrapping --inplace
 	-cd hpc    && $(CABAL) clean     --distpref=dist-bootstrapping
-	cd hpc    && $(CABAL) configure --distpref=dist-bootstrapping --with-compiler=$(GHC) --with-hc-pkg=$(GHC_PKG) --package-db=$(HERE_ABS)/$@.tmp
+	cd hpc    && $(CABAL) configure  --distpref=dist-bootstrapping --with-compiler=$(GHC) --with-gcc=XXPATH_TO_GCCXX --ghc-options='$(CABAL_GHC_FLAGS)' --with-hc-pkg=$(GHC_PKG) --with-hsc2hs=XXPATH_TO_HSC2HSXX --package-db=$(HERE_ABS)/$@.tmp
 	cd hpc    && $(CABAL) build     --distpref=dist-bootstrapping
 	cd hpc    && $(CABAL) install   --distpref=dist-bootstrapping --inplace
 	mv $@.tmp $@
@@ -165,7 +165,7 @@
 ifeq "$(stage)" "2"
 	cd ifBuildable && ../$(HC) -Wall --make ifBuildable -o ifBuildable
 else
-	cd ifBuildable && $(GHC) -Wall --make ifBuildable -o ifBuildable
+	cd ifBuildable && $(GHC) -pgmc XXPATH_TO_GCCXX -pgml XXPATH_TO_GCCXX -pgma XXPATH_TO_GCCXX -Wall --make ifBuildable -o ifBuildable
 endif
 
 .PHONY: all build configure
