+ @for d in $(SUBDIRS); do $(MAKE) -C $$d $@; done
+
+tests/test.bmpp: create_test_pattern
+ ./$< $@.new
+ mv $@.new $@
+
+create_test_pattern: create_test_pattern.cmo
+ $(OCAMLFIND) ocamlc $(OCAMLCFLAGS) -pp camlp4of \
+ unix.cma -I +camlp4 camlp4lib.cma \
+ -I . bitstring.cma bitstring_persistent.cma $< -o $@
+
+create_test_pattern.cmo: create_test_pattern.ml
+ $(OCAMLFIND) ocamlc $(OCAMLCFLAGS) -pp camlp4of \
+ unix.cma -I +camlp4 \
+ -I . -c $< -o $@
+
+examples: pa_bitstring.cmo bitstring.cma bitstring_persistent.cma
+ @for f in $(EXAMPLES); do \
+ echo Building $$f; \
+ $(OCAMLFIND) ocamlc $(OCAMLCFLAGS) $(PP) \
+ -package unix -linkpkg -I . bitstring.cma $$f.ml -o $$f; \
+ if [ $$? -ne 0 ]; then exit 1; fi; \
+ done
+ @for d in $(SUBDIRS); do $(MAKE) -C $$d $@; done