facebookarchive / facebook-clang-plugins

Plugins to clang-analyzer and clang-frontend
MIT License
482 stars 85 forks source link

clang-ocaml make: Error: Unbound value Clang_ast_j.read_decl #13

Closed elijah-z142 closed 5 years ago

elijah-z142 commented 5 years ago

When running make -C clang-ocaml:

ocamlfind ocamlopt -package unix,atdgen,atdgen-runtime,camlzip -I build -safe-string -o build/clang_ast_converter.cmx -c clang_ast_converter.ml File "clang_ast_converter.ml", line 11, characters 41-62: Error: Unbound value Clang_ast_j.read_decl make: *** [Makefile:42: build/clang_ast_converter.cmx] Error 2

I am using Fedora Linux 28 ocaml --version 4.06.0 opam --version 2.0.0~rc

On Mac OS X (mohave + macports) there is a slightly different error:

Elijahs-Mac-Pro:facebook-clang-plugins elijah$ make -C clang-ocaml/ ocamlfind ocamlopt -package unix,atdgen,atdgen-runtime,camlzip -I build -safe-string -o build/clang_ast_t.cmi -c build/clang_ast_t.mli File "build/clang_ast_t.mli", line 29, characters 0-4: Error: Syntax error make: *** [build/clang_ast_t.cmi] Error 2

I would try with HomeBrew, but versions 4.05.0/2.0.0 look to be the latest for OCAML and OPAM.

elijah-z142 commented 5 years ago

Cache issue. Fixed with "make -C clang-ocaml clean".