# -----------------------------------------------------------------------------
-# $Id: Makefile,v 1.6 2001/09/13 11:35:09 simonmar Exp $
+# $Id: Makefile,v 1.9 2002/02/05 17:32:24 simonmar Exp $
TOP=..
include $(TOP)/mk/boilerplate.mk
System/Mem \
System/IO \
Text \
+ Text/Html \
Text/PrettyPrint \
Text/Regex \
Text/Show
PKG=core
-# dependencies between .hsc files
-GHC/IO.hs : GHC/Handle.hs
+# -----------------------------------------------------------------------------
+# PrimOpWrappers
+
+GHC/PrimopWrappers.hs: $(GHC_COMPILER_DIR)/prelude/primops.txt
+ rm -f $@
+ $(GHC_GENPRIMOP) --make-haskell-wrappers < $< > $@
+
+boot :: GHC/PrimOpWrappers.hs
+
+CLEAN_FILES += GHC/PrimopWrappers.hs
+
+# -----------------------------------------------------------------------------
+# GHC/Prim.hi-boot
-GHC/Prim.$(way_)hi : GHC/Prim.hi-boot
+GHC/Prim.$(way_)hi : GHC/Prim.hi-boot
cp $< $@
-lib : GHC/Prim.$(way_)hi
+ALL_PRIMS = GHC/Prim.hi $(foreach way, $(WAYS), GHC/Prim.$(way)_hi)
+
+lib : $(ALL_PRIMS)
+
+boot :: $(ALL_PRIMS)
+
+CLEAN_FILES += $(ALL_PRIMS)
+
+SRC_CPP_OPTS += -I$(GHC_INCLUDE_DIR) -traditional
# -----------------------------------------------------------------------------