4 ocamlflags = -warn-error +a -w +a -g
5 libs = -lmupdf $mujs -lpthread -L$mupdf/build/$buildtype
7 cflags = -O $cflags -Wall -Werror -I$mupdf/include -I$freetype -g $
8 -std=c99 -pedantic-errors
13 command = $ocamlc -cc "$cc" -ccopt "$cflags -MMD -MF $out.d -o $out" -c $in
19 command = sh $srcdir/doocaml.sh $ocamlc $out $in -c $ocamlflags
20 description = ocamlc $out
23 command = sh $srcdir/mkhelp.sh $srcdir/keystoml.ml $srcdir/KEYS >$out
26 sedcmd = sed -f $srcdir/pp.sed
28 build $builddir/help.ml: genhelp $
29 $srcdir/mkhelp.sh $srcdir/keystoml.ml $srcdir/KEYS
30 build $builddir/link.o: cc $srcdir/link.c
31 cflags = $cflags -D_GNU_SOURCE -DOBSCURED_OPT -DFFP
32 build $builddir/help.cmo: ocamlc $builddir/help.ml
33 build $builddir/utils.cmo: ocamlc $srcdir/utils.ml
34 build $builddir/bo.cmo: ocamlc $srcdir/le/bo.ml
35 build $builddir/wsi.cmi: ocamlc $srcdir/wsi.mli
36 build $builddir/wsi.cmo: ocamlc $srcdir/wsi.ml $
37 | $builddir/bo.cmo $builddir/utils.cmo $builddir/wsi.cmi
38 build $builddir/parser.cmo: ocamlc $srcdir/parser.ml
39 build $builddir/config.cmo: ocamlc $srcdir/config.ml $
40 | $builddir/wsi.cmi $builddir/utils.cmo $builddir/parser.cmo
41 ocamlflags = $ocamlflags -I +lablGL
42 build $builddir/main.cmo: ocamlc $srcdir/main.ml $
43 | $builddir/wsi.cmi $builddir/utils.cmo $builddir/config.cmo $
45 ocamlflags = $ocamlflags -I +lablGL -pp "$sedcmd"
47 cmos = $builddir/help.cmo $
49 $builddir/parser.cmo $
52 $builddir/config.cmo $
56 command = $cc -o $out -shared $in $libs $lflags
57 description = linkso $out
59 build $builddir/link.so: linkso $builddir/link.o
62 command = $ocamlc -g -o $out -I +lablGL $
63 str.cma unix.cma lablgl.cma $cmos $
65 description = link $out
67 build $builddir/llpp: link $
70 $builddir/parser.cmo $
73 $builddir/config.cmo $
77 default $builddir/llpp