diff --git a/.gitignore b/.gitignore index 51e04bd0b..9b08d76d9 100644 --- a/.gitignore +++ b/.gitignore @@ -24,9 +24,6 @@ duplicates.txt *.capture.bdump *.capture.biniou -# Directories generated by Ocamlbuild -_build - # generated by oUnit /oUnit-all.cache diff --git a/Makefile.config.in b/Makefile.config.in index 5cc4d1ec5..4657b6474 100644 --- a/Makefile.config.in +++ b/Makefile.config.in @@ -78,14 +78,13 @@ FCP_CLANG_OCAML_DIR = $(FCP_DIR)/clang-ocaml ANNOTATIONS_DIR = $(INFER_DIR)/annotations BIN_DIR = $(INFER_DIR)/bin -BUILD_DIR = $(INFER_DIR)/_build ETC_DIR = $(INFER_DIR)/etc LIB_DIR = $(INFER_DIR)/lib MODELS_DIR = $(INFER_DIR)/models JAVA_BUILTINS_DIR = $(MODELS_DIR)/java/builtins SRC_DIR = $(INFER_DIR)/src -ANNOT_DIR = $(SRC_DIR)/_build +BUILD_DIR = $(INFER_DIR)/_build INFER_BUILD_DIR = $(BUILD_DIR)/infer TEST_BUILD_DIR = $(BUILD_DIR)/test diff --git a/configure.ac b/configure.ac index e3d37c1cc..0392f1e24 100644 --- a/configure.ac +++ b/configure.ac @@ -231,13 +231,6 @@ fi AC_CHECK_TOOL([ATDGEN], [atdgen], [no]) AC_ASSERT_PROG([atdgen], [$ATDGEN]) -AC_ARG_ENABLE(ocaml-annot, - AS_HELP_STRING([--disable-ocaml-annot], [do not build ocaml .annot files]), - , - enable_ocaml_annot=yes) -ENABLE_OCAML_ANNOT=$enable_ocaml_annot -AC_SUBST([ENABLE_OCAML_ANNOT]) - AC_ARG_ENABLE(ocaml-bin-annot, AS_HELP_STRING([--disable-ocaml-bin-annot], [do not build ocaml .cmt files]), , diff --git a/infer/.project b/infer/.project deleted file mode 100644 index 513728ddf..000000000 --- a/infer/.project +++ /dev/null @@ -1,17 +0,0 @@ - - - EdgNative - - - - - - Ocaml.ocamlMakefileBuilder - - - - - - ocaml.ocamlnatureMakefile - - diff --git a/infer/src/.settings/ocp-indent.launch b/infer/src/.settings/ocp-indent.launch deleted file mode 100644 index 8bdf14d65..000000000 --- a/infer/src/.settings/ocp-indent.launch +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - - - - - - - diff --git a/infer/src/Makefile b/infer/src/Makefile index c3f292eb9..cb43202f0 100644 --- a/infer/src/Makefile +++ b/infer/src/Makefile @@ -10,8 +10,6 @@ include $(ROOT_DIR)/Makefile.config #### Global declarations #### -INFER_BUILD_DIR = $(BUILD_DIR)/infer -ANNOT_DIR = $(SRC_DIR)/_build ETC_DIR = $(INFER_DIR)/etc ATDGEN_SUFFIXES = _t.ml _t.mli _j.ml _j.mli @@ -39,10 +37,6 @@ OCAMLBUILD_OPTIONS = \ -tag thread \ -pkgs atdgen,core,ctypes.foreign,oUnit,str,unix,yojson,zip -ifeq ($(ENABLE_OCAML_ANNOT),yes) -OCAMLBUILD_OPTIONS += -cflags -annot -endif - ifeq ($(ENABLE_OCAML_BINANNOT),yes) OCAMLBUILD_OPTIONS += -cflags -bin-annot endif @@ -130,7 +124,7 @@ CHECKCOPYRIGHT_MAIN = $(SCRIPT_SOURCES)/checkCopyright #### End of declarations #### ifeq ($(IS_FACEBOOK_TREE),yes) -EXTRA_DEPS = facebook facebook/checkers facebook/checkers/graphql facebook/scripts +EXTRA_DEPS = facebook facebook/scripts else EXTRA_DEPS = opensource endif @@ -193,9 +187,6 @@ ifeq ($(BUILD_C_ANALYZERS),yes) $(INSTALL_PROGRAM) $(INFER_BUILD_DIR)/$(INFERCLANG_MAIN).native $(INFERCLANG_BIN) cd $(INFER_BUILD_DIR) && $(LN_S) -f InferClang InferClang++ && cd - endif -ifeq ($(ENABLE_OCAML_ANNOT),yes) - rsync -a --include '*/' --include '*.annot' --exclude '*' $(INFER_BUILD_DIR)/ $(ANNOT_DIR)/ -endif ifeq ($(BUILD_C_ANALYZERS),yes) infer: $(CLANG_ATDGEN_STUBS) $(INFER_CLANG_FCP_MIRRORED_FILES) $(CLANG_BINIOU_DICT) @@ -228,10 +219,10 @@ test_build: init $(STACKTREE_ATDGEN_STUBS) $(INFERPRINT_ATDGEN_STUBS) $(CLANG_AT # to generate interface file.mli from implementation file.ml execute: # make M=file mli mli: - ocamlfind ocamlc -package atdgen,oUnit,str,unix,yojson,zip $(addprefix -I ../_build/infer/,$(DEPENDENCIES)) -i $(M).ml > $(M).mli + ocamlfind ocamlc -package atdgen,oUnit,str,unix,yojson,zip $(addprefix -I $(INFER_BUILD_DIR),$(DEPENDENCIES)) -i $(M).ml > $(M).mli rei: - ocamlfind ocamlc -package atdgen,oUnit,str,unix,yojson,zip $(addprefix -I ../_build/infer/,$(DEPENDENCIES)) -i -pp refmt -impl $(M).re > $(M).rei + ocamlfind ocamlc -package atdgen,oUnit,str,unix,yojson,zip $(addprefix -I $(INFER_BUILD_DIR),$(DEPENDENCIES)) -i -pp refmt -impl $(M).re > $(M).rei # convert to reason %.re : %.ml @@ -243,10 +234,9 @@ rei: roots:=Infer InferAnalyzeExe InferClang JMain InferPrintExe StatsAggregator clusters:=base clang java IR -src_dirs:=$(shell find * -type d) -ml_src_files:=$(shell find $(src_dirs) -regex '.*\.ml\(i\)*' -not -path facebook/scripts/eradicate_stats.ml -not -path 'stubs/c/*') -re_src_files:=$(shell find $(src_dirs) -regex '.*\.re\(i\)*') -inc_flags:=$(foreach dir,$(src_dirs),-I $(dir)) +ml_src_files:=$(shell find $(DEPENDENCIES) -regex '.*\.ml\(i\)*' -not -path facebook/scripts/eradicate_stats.ml -not -path 'stubs/c/*') +re_src_files:=$(shell find $(DEPENDENCIES) -regex '.*\.re\(i\)*') +inc_flags:=$(foreach dir,$(DEPENDENCIES),-I $(dir)) root_flags:=$(foreach root,$(roots),-r $(root)) cluster_flags:=$(foreach cluster,$(clusters),-c $(cluster)) @@ -376,9 +366,6 @@ test_clean: clean: $(REMOVE_DIR) $(BUILD_DIR) $(REMOVE) $(ETC_DIR)/clang_ast.dict -ifeq ($(ENABLE_OCAML_ANNOT),yes) - $(REMOVE_DIR) $(ANNOT_DIR) -endif $(REMOVE) base/Version.ml $(REMOVE) base/Version.ml.tmp.* $(REMOVE) backend/jsonbug_{j,t}.ml{,i}