# Generated automatically from Makefile.in by configure.
include ../Makefile.config
include Makefile.fortest

# The executable file to generate (default a.out under Unix)

################ End of user's variables #####################

all: test
opt: test.opt

clean::
	rm -f test test.opt *.cm* *.o out.image screen.bmp

LINKFLAGS= $(LINKFLAGS_CAMLIMAGES)

test: test.ml
	$(CAMLC) $(COMPFLAGS_CAMLIMAGES) $(LINKFLAGS) -o $@ test.ml

test.opt: test.ml
	$(CAMLOPT) $(COMPFLAGS_CAMLIMAGES) $(LINKFLAGS:.cma=.cmxa) -o $@ test.ml

depend: .depend

.depend:
	$(CAMLDEP) $(COMPFLAGS) */*.mli */*.ml > .depend

.SUFFIXES:
.SUFFIXES: .ml .mli .cmo .cmi .cmx .mll .mly .c .o

.ml.cmo:
	$(CAMLC) $(COMPFLAGS) -c $<

.mli.cmi:
	$(CAMLC) $(COMPFLAGS) -c $<

.ml.cmx:
	$(CAMLOPT) $(COMPFLAGS) -c $<

.mll.cmo:
	$(CAMLLEX) $<
	$(CAMLC) $(COMPFLAGS) -c $*.ml

.mll.cmx:
	$(CAMLLEX) $<
	$(CAMLOPT) $(COMPFLAGS) -c $*.ml

.mly.cmo:
	$(CAMLYACC) $<
	$(CAMLC) $(COMPFLAGS) -c $*.mli
	$(CAMLC) $(COMPFLAGS) -c $*.ml

.mly.cmx:
	$(CAMLYACC) $<
	$(CAMLOPT) $(COMPFLAGS) -c $*.mli
	$(CAMLOPT) $(COMPFLAGS) -c $*.ml

.mly.cmi:
	$(CAMLYACC) $<
	$(CAMLC) $(COMPFLAGS) -c $*.mli

.mll.ml:
	$(CAMLLEX) $<

.mly.ml:
	$(CAMLYACC) $<

.c.o:
	$(CAMLC) -ccopt "-o `echo $< | sed -e s/\.c$$/.o/`" -c $< 

include .depend
