-/* based on the Makefile that comes with "gmp" */
+#-----------------------------------------------------------------------------
+# $Id: Makefile,v 1.2 1996/11/21 16:48:25 simonm Exp $
+
+TOP=../../..
+include $(TOP)/ghc/mk/ghc.mk
GMP_OBJS = $(MPZ_OBJS) $(MPQ_OBJS) $(MPN_OBJS) $(IMPL_OBJS) mp_bases.o
CC_OPTS = -I.
-SuffixRule_c_o()
-
all depend :: gmp-mparam.h
-
libgmp.a :: stamp-stddefh
-NormalLibraryTarget(gmp,$(GMP_OBJS))
+ARCHIVE = libgmp.a
+LIBOBJS = $(GMP_OBJS)
+DESTDIR = $(INSTLIBDIR_GHC)
+C_DEP_SRCS = $(IMPL_SRCS) $(MPZ_SRCS) $(MPQ_SRCS) $(MPN_SRCS)
-#if DoInstallGHCSystem == YES
-InstallLibraryTarget(gmp,$(INSTLIBDIR_GHC))
-#endif /* DoInstallGHCSystem */
+clean ::
+ $(RM) test-with-stddefh.c stamp-stddefh \
+ cre-mparam gmp-mparam.h mp_bases.c cre-conv-tab
-ExtraStuffToClean(test-with-stddefh.c stamp-stddefh cre-mparam gmp-mparam.h mp_bases.c cre-conv-tab)
+# ToDo: something to make the doc
-/* ToDo: something to make the doc */
+# from here on, it is magic from the original Makefile
-/* from here on, it is magic from the original Makefile */
-
-XCOMM If you cross compile on a machine with the same sizes of the integral
-XCOMM types ("int", "long int", "short int", and "char") define this as the
-XCOMM local compiler. Otherwise, you need look for the uses of LOCAL_CC below,
-XCOMM and handle those cases manually.
+# If you cross compile on a machine with the same sizes of the integral
+# types ("int", "long int", "short int", and "char") define this as the
+# local compiler. Otherwise, you need look for the uses of LOCAL_CC below,
+# and handle those cases manually.
LOCAL_CC = $(CC)
cre-mparam: cre-mparam.c stamp-stddefh gmp.h
$(LOCAL_CC) $(CFLAGS) cre-mparam.c -o $@
-/* OK, this is my own idea again: */
-
-CDependTarget( $(IMPL_SRCS) $(MPZ_SRCS) $(MPQ_SRCS) $(MPN_SRCS) )
+include $(TOP)/mk/lib.mk