1999-11-17 10:59:06 -08:00
|
|
|
#########################################################################
|
|
|
|
# #
|
|
|
|
# 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 #
|
2001-12-07 05:41:02 -08:00
|
|
|
# under the terms of the GNU Library General Public License, with #
|
|
|
|
# the special exception on linking described in file ../../LICENSE. #
|
1999-11-17 10:59:06 -08:00
|
|
|
# #
|
|
|
|
#########################################################################
|
|
|
|
|
|
|
|
# $Id$
|
|
|
|
|
1996-02-22 04:52:45 -08:00
|
|
|
# Makefile for the str library
|
|
|
|
|
2002-06-07 02:49:45 -07:00
|
|
|
include ../../config/Makefile
|
1996-02-22 04:52:45 -08:00
|
|
|
|
|
|
|
# Compilation options
|
|
|
|
CC=$(BYTECC)
|
2002-12-09 06:05:18 -08:00
|
|
|
CFLAGS=-I../../byterun
|
2002-06-07 02:49:45 -07:00
|
|
|
CAMLC=../../boot/ocamlrun ../../ocamlc -I ../../boot
|
|
|
|
CAMLOPT=../../boot/ocamlrun ../../ocamlopt -I ../../stdlib
|
2002-12-09 06:05:18 -08:00
|
|
|
DCOBJS=strstubs.$(DO)
|
|
|
|
SCOBJS=strstubs.$(SO)
|
1996-02-22 04:52:45 -08:00
|
|
|
|
2002-06-07 02:49:45 -07:00
|
|
|
all: dllstr.dll libstr.$(A) str.cmi str.cma
|
1996-02-22 04:52:45 -08:00
|
|
|
|
2002-06-07 02:49:45 -07:00
|
|
|
allopt: libstr.$(A) str.cmi str.cmxa
|
1996-02-22 04:52:45 -08:00
|
|
|
|
2002-06-07 02:49:45 -07:00
|
|
|
dllstr.dll: $(DCOBJS)
|
|
|
|
$(call MKDLL,dllstr.dll,tmp.$(A),$(DCOBJS) ../../byterun/ocamlrun.$(A))
|
2001-08-28 07:47:48 -07:00
|
|
|
rm tmp.*
|
|
|
|
|
2002-06-07 02:49:45 -07:00
|
|
|
libstr.$(A): $(SCOBJS)
|
|
|
|
$(call MKLIB,libstr.$(A),$(SCOBJS))
|
1996-02-22 04:52:45 -08:00
|
|
|
|
|
|
|
str.cma: str.cmo
|
2001-11-06 05:21:46 -08:00
|
|
|
$(CAMLC) -a -o str.cma str.cmo -dllib -lstr -cclib -lstr
|
1996-02-22 04:52:45 -08:00
|
|
|
|
|
|
|
str.cmxa: str.cmx
|
2000-03-16 05:35:20 -08:00
|
|
|
$(CAMLOPT) -a -o str.cmxa str.cmx -cclib -lstr
|
1996-02-22 04:52:45 -08:00
|
|
|
|
2002-06-07 02:49:45 -07:00
|
|
|
str.cmx: ../../ocamlopt
|
1996-02-22 04:52:45 -08:00
|
|
|
|
1997-02-16 05:36:42 -08:00
|
|
|
partialclean:
|
1996-02-22 04:52:45 -08:00
|
|
|
rm -f *.cm*
|
|
|
|
|
1997-02-16 05:36:42 -08:00
|
|
|
clean: partialclean
|
2002-06-07 02:49:45 -07:00
|
|
|
rm -f *.$(A) *.dll *.$(O) *.$(SO)
|
1996-02-22 04:52:45 -08:00
|
|
|
|
|
|
|
install:
|
2002-06-27 04:36:02 -07:00
|
|
|
cp dllstr.dll $(STUBLIBDIR)/dllstr.dll
|
2002-06-07 02:49:45 -07:00
|
|
|
cp libstr.$(A) $(LIBDIR)/libstr.$(A)
|
1996-02-22 04:52:45 -08:00
|
|
|
cp str.cma str.cmi $(LIBDIR)
|
|
|
|
|
|
|
|
installopt:
|
2002-06-07 02:49:45 -07:00
|
|
|
cp str.cmx str.cmxa str.$(A) $(LIBDIR)
|
1996-02-22 04:52:45 -08:00
|
|
|
|
2002-06-07 02:49:45 -07:00
|
|
|
.SUFFIXES: .ml .mli .cmo .cmi .cmx .$(DO) .$(SO)
|
1996-02-22 04:52:45 -08:00
|
|
|
|
|
|
|
.mli.cmi:
|
|
|
|
$(CAMLC) -c $(COMPFLAGS) $<
|
|
|
|
|
|
|
|
.ml.cmo:
|
|
|
|
$(CAMLC) -c $(COMPFLAGS) $<
|
|
|
|
|
|
|
|
.ml.cmx:
|
|
|
|
$(CAMLOPT) -c $(COMPFLAGS) $<
|
|
|
|
|
2002-06-07 02:49:45 -07:00
|
|
|
.c.$(DO):
|
2001-08-28 07:47:48 -07:00
|
|
|
$(BYTECC) $(DLLCCCOMPOPTS) $(CFLAGS) -c $<
|
2002-06-07 02:49:45 -07:00
|
|
|
mv $*.$(O) $*.$(DO)
|
2001-08-28 07:47:48 -07:00
|
|
|
|
2002-06-07 02:49:45 -07:00
|
|
|
.c.$(SO):
|
2001-08-28 07:47:48 -07:00
|
|
|
$(BYTECC) $(BYTECCCOMPOPTS) $(CFLAGS) -c $<
|
2002-06-07 02:49:45 -07:00
|
|
|
mv $*.$(O) $*.$(SO)
|
2001-08-28 07:47:48 -07:00
|
|
|
|
1996-02-22 04:52:45 -08:00
|
|
|
depend:
|
|
|
|
|
2001-08-28 07:47:48 -07:00
|
|
|
str.cmo: str.cmi
|
|
|
|
str.cmx: str.cmi
|