85 lines
2.4 KiB
Makefile
85 lines
2.4 KiB
Makefile
#########################################################################
|
|
# #
|
|
# Objective Caml #
|
|
# #
|
|
# Xavier Leroy, projet Cristal, INRIA Rocquencourt #
|
|
# #
|
|
# Copyright 1999 Institut National de Recherche en Informatique et #
|
|
# en Automatique. All rights reserved. This file is distributed #
|
|
# under the terms of the GNU Library General Public License. #
|
|
# #
|
|
#########################################################################
|
|
|
|
# $Id$
|
|
|
|
include ..\..\config\Makefile.nt
|
|
|
|
CC=$(BYTECC)
|
|
CFLAGS=-I..\..\byterun -I..\win32unix
|
|
CAMLC=..\..\boot\ocamlrun ..\..\ocamlc -I ..\..\stdlib -I ..\win32unix
|
|
CAMLOPT=..\..\boot\ocamlrun ..\..\ocamlopt -I ..\..\stdlib -I ..\win32unix
|
|
|
|
C_OBJS=bigarray_stubs.obj mmap_win32.obj
|
|
|
|
CAML_OBJS=bigarray.cmo
|
|
|
|
all: dllbigarray.dll libbigarray.lib bigarray.cma
|
|
|
|
allopt: libbigarray.lib bigarray.cmxa
|
|
|
|
dllbigarray.dll: $(C_OBJS:.obj=.dobj)
|
|
link /nologo /dll /out:dllbigarray.dll /implib:tmp.lib \
|
|
$(C_OBJS:.obj=.dobj) ..\..\byterun\ocamlrun.lib
|
|
rm tmp.*
|
|
|
|
libbigarray.lib: $(C_OBJS:.obj=.sobj)
|
|
rm -f libunix.lib
|
|
$(MKLIB)libbigarray.lib $(C_OBJS:.obj=.sobj)
|
|
|
|
bigarray.cma: $(CAML_OBJS)
|
|
$(CAMLC) -a -linkall -o bigarray.cma $(CAML_OBJS) \
|
|
-dllib -lbigarray -cclib -lbigarray
|
|
|
|
bigarray.cmxa: $(CAML_OBJS:.cmo=.cmx)
|
|
$(CAMLOPT) -a -linkall -o bigarray.cmxa \
|
|
$(CAML_OBJS:.cmo=.cmx) -cclib -lbigarray
|
|
|
|
install:
|
|
cp dllbigarray.dll libbigarray.lib $(LIBDIR)
|
|
cp bigarray.cmi bigarray.mli bigarray.cma $(LIBDIR)
|
|
cp bigarray.h $(LIBDIR)/caml/bigarray.h
|
|
|
|
installopt:
|
|
cp bigarray.lib $(CAML_OBJS:.cmo=.cmx) bigarray.cmxa $(LIBDIR)
|
|
|
|
partialclean:
|
|
rm -f *.cm*
|
|
|
|
clean: partialclean
|
|
rm -f *.dll *.lib *.dobj *.sobj
|
|
|
|
.SUFFIXES: .ml .mli .cmo .cmi .cmx .dobj .sobj
|
|
|
|
.mli.cmi:
|
|
$(CAMLC) -c $(COMPFLAGS) $<
|
|
|
|
.ml.cmo:
|
|
$(CAMLC) -c $(COMPFLAGS) $<
|
|
|
|
.ml.cmx:
|
|
$(CAMLOPT) -c $(COMPFLAGS) $<
|
|
|
|
.c.dobj:
|
|
$(BYTECC) $(DLLCCCOMPOPTS) $(CFLAGS) -c $<
|
|
mv $*.obj $*.dobj
|
|
|
|
.c.sobj:
|
|
$(BYTECC) $(BYTECCCOMPOPTS) $(CFLAGS) -c $<
|
|
mv $*.obj $*.sobj
|
|
|
|
depend:
|
|
gcc -MM $(CFLAGS) *.c > .depend
|
|
..\..\boot\ocamlrun ..\..\tools\ocamldep *.mli *.ml >> .depend
|
|
|
|
include .depend
|