Release coccinelle-0.2.3rc2
[bpt/coccinelle.git] / parsing_c / Makefile
index 3be6d2e..3d720ba 100644 (file)
@@ -6,17 +6,33 @@
 ##############################################################################
 TARGET=parsing_c
 
+-include ../Makefile.config
+
+ifeq ($(FEATURE_TARZAN), 1)
+TARZANSRC=sexp_ast_c.ml
+ifeq ("$(SEXPDIR)","ocamlsexp")
+TARZANINCLUDE=-I ../$(SEXPDIR)
+else
+TARZANINCLUDE=-I $(SEXPDIR)
+endif # Use local ocamlsexp
+endif # FEATURE_TARZAN
+
+
 
 # - type_cocci.ml ast_cocci.ml  # + unparse_hrule
 SRC= flag_parsing_c.ml parsing_stat.ml \
  token_c.ml ast_c.ml control_flow_c.ml \
+ $(TARZANSRC) \
  visitor_c.ml lib_parsing_c.ml \
  control_flow_c_build.ml \
  pretty_print_c.ml \
  semantic_c.ml lexer_parser.ml parser_c.ml lexer_c.ml \
  token_helpers.ml token_views_c.ml \
- cpp_token_c.ml parsing_hacks.ml \
+ cpp_token_c.ml  \
+ parsing_hacks.ml \
+ cpp_analysis_c.ml \
  unparse_cocci.ml unparse_c.ml unparse_hrule.ml  \
+ parsing_recovery_c.ml parsing_consistency_c.ml \
  parse_c.ml type_c.ml \
  cpp_ast_c.ml \
  type_annoter_c.ml comment_annotater_c.ml \
@@ -34,9 +50,11 @@ SRC= flag_parsing_c.ml parsing_stat.ml \
 LIBS=../commons/commons.cma ../globals/globals.cma \
      ../parsing_cocci/cocci_parser.cma
 
-INCLUDES= -I ../commons -I ../commons/ocamlextra -I ../commons/ocollection \
+INCLUDESDEP= -I ../commons -I ../commons/ocamlextra -I ../commons/ocollection \
   -I ../globals -I  ../parsing_cocci
 
+INCLUDES=$(INCLUDESDEP) $(TARZANINCLUDE)
+
 #LIBS=../commons/commons.cma
 #INCLUDES= -I ../commons
 SYSLIBS= str.cma unix.cma num.cma
@@ -53,7 +71,7 @@ OCAMLC=ocamlc$(OPTBIN) $(OCAMLCFLAGS) $(INCLUDES)
 OCAMLOPT=ocamlopt$(OPTBIN) $(OPTFLAGS) $(INCLUDES)
 OCAMLLEX=ocamllex$(OPTBIN) #-ml
 OCAMLYACC=ocamlyacc -v
-OCAMLDEP=ocamldep$(OPTBIN) $(INCLUDES)
+OCAMLDEP=ocamldep$(OPTBIN) $(INCLUDESDEP)
 OCAMLMKTOP=ocamlmktop -g -custom $(INCLUDES)
 
 
@@ -119,6 +137,10 @@ locindiv:
        wc -l ast_c.ml
        wc -l parse_c.ml
 
+##############################################################################
+# Literate Programming rules
+##############################################################################
+
 
 ##############################################################################
 # Generic rules