X-Git-Url: http://git.nguyen.vg/gitweb/?p=tatoo.git;a=blobdiff_plain;f=src%2Fbindings%2Fc%2B%2B%2FMakefile;fp=src%2Fbindings%2Fc%2B%2B%2FMakefile;h=b5f2368e081be19a80341208cc2e5b711e93533f;hp=0000000000000000000000000000000000000000;hb=85ba2cc3211b4c6ea7da4cbaf9db3bd51765e6f7;hpb=33cc91c072d0c3ee3f17911f6484a24f55a3408b diff --git a/src/bindings/c++/Makefile b/src/bindings/c++/Makefile new file mode 100644 index 0000000..b5f2368 --- /dev/null +++ b/src/bindings/c++/Makefile @@ -0,0 +1,23 @@ +CXX = g++ + +all: tatoo-c++ + +tatoo-engine.o: tatoo-engine.cc tatoo.h + $(CXX) -I `ocamlc -where` `pkg-config libxml-2.0 --cflags` -DNDEBUG -fPIC \ + -DPIC -std=c++0x -c -O3 -o $@ $< -Wall -Wextra -Wno-unused-parameter + +tatoo-c++: tatoo-engine.o tatoo-driver.o + $(CXX) -o $@ -O3 tatoo-driver.o tatoo-engine.o -ldl -lrt `pkg-config libxml-2.0 --libs` \ + -L`ocamlc -where` -lasmrun -lunix -lbigarray + +tatoo_driver.depx tatoo_driver.cmx: tatoo_driver.ml + ../../../remake $@ + +tatoo-driver.o: tatoo_driver.cmx tatoo_driver.depx + ocamlfind ocamlopt -output-obj -o $@ -I ../.. -cc $(CXX) -linkall -linkpkg -package bigarray,ulex,unix $(shell cat tatoo_driver.depx | sed -e 's:src:../..:g' | sed -e 's:depx:cmx:g' ) $< + +test: TatooTest.class libtatoo-java.so + java -cp . -Xss80m -Djava.library.path=. TatooTest ../../../tests/xmark_0.50.xml '/descendant::keyword[ancestor::listitem]/*' + +clean: + rm -f *.cm* *.depx *.o TatooTest.class tatoo-c++