1996-02-22 04:52:45 -08:00
|
|
|
# Makefile for the "num" (exact rational arithmetic) library
|
|
|
|
|
|
|
|
!include ..\..\config\Makefile.nt
|
|
|
|
|
|
|
|
# Compilation options
|
|
|
|
CC=$(BYTECC)
|
|
|
|
CFLAGS=-O -I.\bignum\h -I..\..\byterun $(BYTECCCOMPOPTS)
|
1996-04-30 07:53:58 -07:00
|
|
|
CAMLC=..\..\boot\ocamlrun ..\..\boot\ocamlc -I ..\..\boot
|
|
|
|
CAMLOPT=..\..\boot\ocamlrun ..\..\ocamlopt -I ..\..\stdlib
|
1996-02-22 04:52:45 -08:00
|
|
|
|
|
|
|
CAMLOBJS=int_misc.cmo string_misc.cmo nat.cmo big_int.cmo arith_flags.cmo \
|
|
|
|
ratio.cmo num.cmo arith_status.cmo
|
|
|
|
|
|
|
|
CAMLINTF=big_int.cmi nat.cmi num.cmi ratio.cmi arith_status.cmi
|
|
|
|
|
|
|
|
COBJS=nat_stubs.obj
|
|
|
|
|
|
|
|
all: libnums.lib nums.cma $(CMIFILES)
|
|
|
|
|
|
|
|
allopt: libnums.lib nums.cmxa $(CMIFILES)
|
|
|
|
|
|
|
|
nums.cma: $(CAMLOBJS)
|
|
|
|
$(CAMLC) -a -o nums.cma $(CAMLOBJS)
|
|
|
|
|
|
|
|
nums.cmxa: $(CAMLOBJS:.cmo=.cmx)
|
|
|
|
$(CAMLOPT) -a -o nums.cmxa $(CAMLOBJS:.cmo=.cmx)
|
|
|
|
|
|
|
|
libnums.lib: bignum\libbignum.lib $(COBJS)
|
|
|
|
$(MKLIB)libnums.lib bignum\libbignum.lib $(COBJS)
|
|
|
|
|
|
|
|
bignum\libbignum.lib:
|
|
|
|
cd bignum & $(MAKEREC)
|
|
|
|
|
1996-04-30 07:53:58 -07:00
|
|
|
$(CAMLOBJS:.cmo=.cmx): ..\..\ocamlopt
|
1996-02-22 04:52:45 -08:00
|
|
|
|
|
|
|
install:
|
|
|
|
cp libnums.lib $(LIBDIR)\libnums.lib
|
|
|
|
cp nums.cma $(CAMLINTF) $(LIBDIR)
|
|
|
|
|
|
|
|
installopt:
|
|
|
|
cp $(CAMLOBJS:.cmo=.cmx) nums.cmxa nums.lib $(LIBDIR)
|
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -f *.cm*
|
|
|
|
|
|
|
|
realclean: clean
|
|
|
|
rm -f *.lib *.obj
|
|
|
|
cd bignum & $(MAKEREC) clean
|
|
|
|
cd test & $(MAKEREC) clean
|
|
|
|
|
1996-10-07 07:03:20 -07:00
|
|
|
.SUFFIXES: .ml .mli .cmi .cmo .cmx
|
1996-02-22 04:52:45 -08:00
|
|
|
|
|
|
|
.mli.cmi:
|
|
|
|
$(CAMLC) -c $(COMPFLAGS) $<
|
|
|
|
|
|
|
|
.ml.cmo:
|
|
|
|
$(CAMLC) -c $(COMPFLAGS) $<
|
|
|
|
|
|
|
|
.ml.cmx:
|
|
|
|
$(CAMLOPT) -c $(COMPFLAGS) $<
|
|
|
|
|
|
|
|
nat_stubs.obj: nat.h
|
|
|
|
|
|
|
|
depend:
|
|
|
|
sed -e "s/\.o/.obj/g" .depend > .depend.nt
|
|
|
|
|
|
|
|
!include .depend.nt
|