1 #note: if you add a file (a .mli or .ml), dont forget to do a make depend
3 -include ..
/Makefile.config
7 SRC
=flag_ctl.ml ast_ctl.ml pretty_print_ctl.ml ctl_engine.ml wrapper_ctl.ml
9 SYSLIBS
=str.cma unix.cma
10 LIBS
=..
/commons
/commons.cma ..
/globals
/globals.cma
12 INCLUDES
=-I ..
/commons
-I ..
/commons
/ocamlextra
-I ..
/globals
17 #for profiling: -p -inline 0 with OCAMLOPT
18 OCAMLCFLAGS ?
= -g
-dtypes
19 OCAMLC
=ocamlc
$(OPTBIN
) $(OCAMLCFLAGS
) $(INCLUDES
)
20 OCAMLOPT
= ocamlopt
$(OPTBIN
) $(OPTFLAGS
) $(INCLUDES
)
21 OCAMLDEP
= ocamldep
$(OPTBIN
) $(INCLUDES
)
22 OCAMLMKTOP
=ocamlmktop
-g
-custom
$(INCLUDES
)
27 OPTLIB
=$(LIB
:.cma
=.cmxa
)
29 OBJS
= $(SRC
:.ml
=.cmo
)
30 OPTOBJS
= $(SRC
:.ml
=.cmx
)
35 $(TARGET
).top
: $(LIB
) test_ctl.cmo
36 $(OCAMLMKTOP
) -o
$(TARGET
).top
$(SYSLIBS
) $(LIBS
) $(OBJS
) test_ctl.cmo
39 $(OCAMLC
) -a
-o
$(LIB
) $(OBJS
)
42 $(OCAMLOPT
) -a
-o
$(OPTLIB
) $(OPTOBJS
)
45 rm -f
$(LIB
) $(OPTLIB
) $(LIB
:.cma
=.a
) $(TARGET
).top
49 .SUFFIXES
: .ml .mli .cmo .cmi .cmx
63 # clean rule for others files
65 rm -f
*.cm
[iox
] *.o
*.annot
69 $(OCAMLDEP
) *.mli
*.ml
> .depend
75 $(OCAMLDEP
) *.mli
*.ml
> .depend