Source

clutter-ocaml / examples / Makefile.in

Full commit
# clutter-ocaml

PACKAGE		:= @PACKAGE_NAME@
VERSION		:= @PACKAGE_VERSION@

INSTALL		:= @INSTALL@

prefix		= @prefix@
exec_prefix	= @exec_prefix@
bindir		= @bindir@

pkg_lablgtk2	= @pkg_lablgtk2@
pkg_cairo	= @pkg_cairo@

OCAMLCPACKAGES	:= -package lablgtk2,bigarray,cairo

OCAMLCFLAGS	:= -g -w s -I ../src ../src/mlclutter.cma
OCAMLCLIBS	:= -cclib -L../src 

OCAMLOPTPACKAGES := -linkpkg $(OCAMLCPACKAGES)
OCAMLOPTFLAGS	:= -w s -I ../src
CLUTTER_FLAGS   := $(shell pkg-config --libs clutter-0.8)
CLUTTER_CAIRO_FLAGS := $(shell pkg-config --libs clutter-cairo-0.8)
OCAMLOPTLIBS	:= $(OCAMLCLIBS) -cclib '$(CLUTTER_FLAGS)' -cclib '$(CLUTTER_CAIRO_FLAGS)' -cclib -lclutter-ocaml ../src/mlclutter.cmxa

# test-cogl-primitives test-cogl-tex-file
TARGETS         := actor1 actor2 behave cogl-actor effects flowers
BYTE_TARGETS	:= $(TARGETS:=.byte)
OPT_TARGETS	:= $(TARGETS:=.opt)

all: $(OPT_TARGETS)
byte: $(BYTE_TARGETS)

actor1: actor1.cmo
	ocamlfind ocamlc $(OCAMLCPACKAGES) $(OCAMLCFLAGS) $(OCAMLCLIBS) -o $@ $^

actor1.opt: actor1.cmx
	ocamlfind ocamlopt $(OCAMLOPTPACKAGES) $(OCAMLOPTFLAGS) $(OCAMLOPTLIBS) -o $@ $^

actor2: actor2.cmo
	ocamlfind ocamlc $(OCAMLCPACKAGES) $(OCAMLCFLAGS) $(OCAMLCLIBS) -o $@ $^

actor2.opt: actor2.cmx
	ocamlfind ocamlopt $(OCAMLOPTPACKAGES) $(OCAMLOPTFLAGS) $(OCAMLOPTLIBS) -o $@ $^

behave: behave.cmo
	ocamlfind ocamlc $(OCAMLCPACKAGES) $(OCAMLCFLAGS) $(OCAMLCLIBS) -o $@ $^

behave.opt: behave.cmx
	ocamlfind ocamlopt $(OCAMLOPTPACKAGES) $(OCAMLOPTFLAGS) $(OCAMLOPTLIBS) -o $@ $^

cogl-actor: cogl-actor.cmo
	ocamlfind ocamlc $(OCAMLCPACKAGES) $(OCAMLCFLAGS) $(OCAMLCLIBS) -o $@ $^

cogl-actor.opt: cogl-actor.cmx
	ocamlfind ocamlopt $(OCAMLOPTPACKAGES) $(OCAMLOPTFLAGS) $(OCAMLOPTLIBS) -o $@ $^

effects: effects.cmo
	ocamlfind ocamlc $(OCAMLCPACKAGES) $(OCAMLCFLAGS) $(OCAMLCLIBS) -o $@ $^

effects.opt: effects.cmx
	ocamlfind ocamlopt $(OCAMLOPTPACKAGES) $(OCAMLOPTFLAGS) $(OCAMLOPTLIBS) -o $@ $^

flowers: flowers.cmo
	ocamlfind ocamlc $(OCAMLCPACKAGES) $(OCAMLCFLAGS) $(OCAMLCLIBS) -o $@ $^

flowers.opt: flowers.cmx
	ocamlfind ocamlopt $(OCAMLOPTPACKAGES) $(OCAMLOPTFLAGS) $(OCAMLOPTLIBS) -o $@ $^

# Manual page.
include ../Make.rules