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
|
|
|
|
|
|
|
|
!include ..\..\config\Makefile.nt
|
|
|
|
|
|
|
|
# Compilation options
|
|
|
|
CC=$(BYTECC)
|
2001-08-28 07:47:48 -07:00
|
|
|
CFLAGS=-I$(REGEXLIB) -I..\..\byterun
|
2000-02-05 04:16:09 -08:00
|
|
|
CAMLC=..\..\boot\ocamlrun ..\..\ocamlc -I ..\..\boot
|
1996-04-30 07:53:58 -07:00
|
|
|
CAMLOPT=..\..\boot\ocamlrun ..\..\ocamlopt -I ..\..\stdlib
|
1996-02-22 04:52:45 -08:00
|
|
|
REGEXLIB=regex-0.12
|
2001-08-28 07:47:48 -07:00
|
|
|
REGEXFLAGS=-DREGEX_MALLOC -DSTDC_HEADERS
|
1996-02-22 04:52:45 -08:00
|
|
|
COBJS=strstubs.obj $(REGEXLIB)\regex.obj
|
|
|
|
|
2001-10-30 06:48:26 -08:00
|
|
|
all: dllstr.dll libstr.lib str.cmi str.cma
|
1996-02-22 04:52:45 -08:00
|
|
|
|
|
|
|
allopt: libstr.lib str.cmi str.cmxa
|
|
|
|
|
2001-10-30 06:48:26 -08:00
|
|
|
dllstr.dll: $(COBJS:.obj=.dobj)
|
|
|
|
link /nologo /dll /out:dllstr.dll /implib:tmp.lib $(COBJS:.obj=.dobj) ..\..\byterun\ocamlrun.lib
|
2001-08-28 07:47:48 -07:00
|
|
|
rm tmp.*
|
|
|
|
|
|
|
|
libstr.lib: $(COBJS:.obj=.sobj)
|
|
|
|
$(MKLIB)libstr.lib $(COBJS:.obj=.sobj)
|
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
|
|
|
|
2001-08-28 07:47:48 -07:00
|
|
|
$(REGEXLIB)\regex.dobj: $(REGEXLIB)\regex.c $(REGEXLIB)\regex.h
|
|
|
|
cd $(REGEXLIB) & $(CC) $(REGEXFLAGS) $(DLLCCCOMPOPTS) -c regex.c
|
|
|
|
mv $(REGEXLIB)\regex.obj $(REGEXLIB)\regex.dobj
|
|
|
|
|
|
|
|
$(REGEXLIB)\regex.sobj: $(REGEXLIB)\regex.c $(REGEXLIB)\regex.h
|
|
|
|
cd $(REGEXLIB) & $(CC) $(REGEXFLAGS) $(BYTECCCOMPOPTS) -c regex.c
|
|
|
|
mv $(REGEXLIB)\regex.obj $(REGEXLIB)\regex.sobj
|
1996-02-22 04:52:45 -08:00
|
|
|
|
1996-04-30 07:53:58 -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
|
2001-08-28 07:47:48 -07:00
|
|
|
rm -f *.lib *.dll *.dobj *.sobj
|
|
|
|
rm -f $(REGEXLIB)/*.dobj $(REGEXLIB)/*.sobj
|
1996-02-22 04:52:45 -08:00
|
|
|
|
|
|
|
install:
|
2001-10-30 06:48:26 -08:00
|
|
|
cp dllstr.dll $(LIBDIR)\dllstr.dll
|
1996-02-22 04:52:45 -08:00
|
|
|
cp libstr.lib $(LIBDIR)\libstr.lib
|
|
|
|
cp str.cma str.cmi $(LIBDIR)
|
|
|
|
|
|
|
|
installopt:
|
|
|
|
cp str.cmx str.cmxa str.lib $(LIBDIR)
|
|
|
|
|
2001-08-28 07:47:48 -07:00
|
|
|
.SUFFIXES: .ml .mli .cmo .cmi .cmx .dobj .sobj
|
1996-02-22 04:52:45 -08:00
|
|
|
|
|
|
|
.mli.cmi:
|
|
|
|
$(CAMLC) -c $(COMPFLAGS) $<
|
|
|
|
|
|
|
|
.ml.cmo:
|
|
|
|
$(CAMLC) -c $(COMPFLAGS) $<
|
|
|
|
|
|
|
|
.ml.cmx:
|
|
|
|
$(CAMLOPT) -c $(COMPFLAGS) $<
|
|
|
|
|
2001-08-28 07:47:48 -07:00
|
|
|
.c.dobj:
|
|
|
|
$(BYTECC) $(DLLCCCOMPOPTS) $(CFLAGS) -c $<
|
|
|
|
mv $*.obj $*.dobj
|
|
|
|
|
|
|
|
.c.sobj:
|
|
|
|
$(BYTECC) $(BYTECCCOMPOPTS) $(CFLAGS) -c $<
|
|
|
|
mv $*.obj $*.sobj
|
|
|
|
|
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
|