[project @ 1999-05-11 17:05:43 by keithw]
[ghc-hetmet.git] / ghc / lib / Makefile
index 1e256cd..0dfe5f2 100644 (file)
@@ -1,28 +1,21 @@
-#-----------------------------------------------------------------------------
-# $Id: Makefile,v 1.4 1997/01/07 13:19:38 simonm Exp $
+#################################################################################
+#
+#                          ghc/lib/Makefile
+#
+#              Makefile for building the GHC Prelude libraries umpteen ways
+#
+#      
+#################################################################################
 
-TOP = ../..
-include $(TOP)/ghc/mk/ghc.mk
+TOP = ..
+include $(TOP)/mk/boilerplate.mk
 
-SUBDIRS = cbits
-ifeq ($(IncludeTestDirsInBuild),YES)
-  SUBDIRS += tests
-endif
-include $(TOP)/mk/subdir.mk
-
-# per-build options: shared with runtime system
-include ../mk/buildflags.mk
-
-MAKEFILE=Makefile.libHS
-DESCR=libraries
-include $(TOP)/ghc/mk/ways.mk
+# posix must be before misc.
 
-# Shortcut for typical case when testing: just make the "normal" version
-# (simonm Todo: better way to do this?)
-libHS.a ::
-       $(MAKE)  -f Makefile.libHS suffix=norm
-
-# install MODULES file
+ifeq "$(GhcWithHscBuiltViaC)" "YES"
+SUBDIRS = std exts
+else
+SUBDIRS = std exts concurrent misc posix
+endif
 
-install ::
-       $(INSTALL) $(INSTDATAFLAGS) MODULES $(INSTDATADIR_GHC)/imports
+include $(TOP)/mk/target.mk