/[svn]/Makefile.types
ViewVC logotype

Contents of /Makefile.types

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1443 - (show annotations)
Tue Jul 10 18:50:20 2007 UTC (5 years, 10 months ago) by abate
File size: 1925 byte(s)
[r2005-02-01 13:10:25 by afrisch] Cleanup

Original author: afrisch
Date: 2005-02-01 13:10:26+00:00
1 DIRS= misc types
2
3 SRC= \
4 misc/serialize.mli \
5 misc/serialize.ml \
6 misc/custom.ml \
7 misc/custom.ml \
8 misc/encodings.mli \
9 misc/encodings.ml \
10 misc/imap.mli \
11 misc/imap.ml \
12 misc/state.mli \
13 misc/state.ml \
14 misc/pool.mli \
15 misc/pool.ml \
16 misc/ns.mli \
17 misc/ns.ml \
18 types/sortedList.mli \
19 types/sortedList.ml \
20 types/atoms.mli \
21 types/atoms.ml \
22 misc/bool.mli \
23 misc/bool.ml \
24 types/chars.mli \
25 types/chars.ml \
26 types/ident.ml \
27 types/intervals.mli \
28 types/intervals.ml \
29 misc/inttbl.mli \
30 misc/inttbl.ml \
31 types/normal.mli \
32 types/normal.ml \
33 misc/pretty.mli \
34 misc/pretty.ml \
35 misc/stats.mli \
36 misc/stats.ml \
37 types/ident.ml \
38 types/types.mli \
39 types/types.ml
40
41 ML_SRC=$(filter %.ml,$(SRC))
42 OBJECTS=$(ML_SRC:.ml=.$(EXT))
43
44
45 CAMLC=ocamlc
46 CAMLOPT=ocamlopt
47 ifeq ($(NATIVE),true)
48 EXT=cmx
49 EXTA=cmxa
50 CAML=$(CAMLOPT)
51 else
52 EXT=cmo
53 EXTA=cma
54 CAML=$(CAMLC)
55 endif
56
57 cduce_types.cmo: $(OBJECTS)
58 $(CAML) -pack -o cduce_types.$(EXT) $(INCLUDES) $^
59 $(CAML) -a -o cduce_types.$(EXTA) $(INCLUDES) cduce_types.$(EXT)
60
61 HIDE=@
62 INCLUDES = $(DIRS:%=-I %)
63
64
65 types/intervals.$(EXT): types/intervals.ml cat1 types/intervals_int.ml
66 $(CAML) -c $(INCLUDES) -pp './cat1 types/intervals_int.ml' $<
67
68 types/intervals.cmi: types/intervals.mli cat1 types/intervals_int.mli
69 $(CAML) -c $(INCLUDES) -pp './cat1 types/intervals_int.mli' $<
70
71 misc/stats.$(EXT): misc/stats.ml
72 $(CAML) -c $(INCLUDES) -pp 'sed s/Unix\\.gettimeofday\(\)/0./' $<
73
74 cat1:
75 echo "cat \$$1" > cat1
76 chmod +x cat1
77
78 .SUFFIXES: .ml .mli .cmo .cmi .cmx
79
80 .ml.cmo:
81 @echo "Build $@"
82 $(HIDE)$(CAMLC) -c $(INCLUDES) $<
83
84 .ml.cmx:
85 @echo "Build $@"
86 $(HIDE)$(CAMLOPT) -c $(INCLUDES) $<
87
88 .mli.cmi:
89 @echo "Build $@"
90 $(HIDE)$(CAMLC) -c $(INCLUDES) $<
91
92
93 .PHONY: compute_depend
94 compute_depend:
95 ocamldep $(INCLUDES) $(SRC) > types_depend
96
97 include types_depend
98
99 clean:
100 for i in $(DIRS); do \
101 (cd $$i; rm -f *.cmi *.cmo *.cma *.cmx *.o *.a *.cmxa *~); \
102 done

CVS Admin">CVS Admin
ViewVC Help
Powered by ViewVC 1.1.5