|
|
@ -157,17 +157,15 @@ let capture build_cmd = function
|
|
|
|
L.stdout "Capturing using Buck's compilation database...@\n";
|
|
|
|
L.stdout "Capturing using Buck's compilation database...@\n";
|
|
|
|
let json_cdb = CaptureCompilationDatabase.get_compilation_database_files_buck () in
|
|
|
|
let json_cdb = CaptureCompilationDatabase.get_compilation_database_files_buck () in
|
|
|
|
capture_with_compilation_database json_cdb
|
|
|
|
capture_with_compilation_database json_cdb
|
|
|
|
| ClangCompilationDatabase -> (
|
|
|
|
| ClangCompilationDatabase ->
|
|
|
|
L.stdout "Capturing using a compilation database file...@\n";
|
|
|
|
L.stdout "Capturing using a compilation database file...@\n";
|
|
|
|
match Config.rest with
|
|
|
|
let cmd_args = List.tl build_cmd |> Option.value ~default:[] in
|
|
|
|
| arg :: _ ->
|
|
|
|
if List.is_empty cmd_args then (
|
|
|
|
capture_with_compilation_database [arg]
|
|
|
|
failwith
|
|
|
|
| _ ->
|
|
|
|
"Error parsing arguments. Please, pass the compilation database json file as in \
|
|
|
|
failwith
|
|
|
|
infer -- clang-compilation-database file.json." ;
|
|
|
|
"Error parsing arguments. Please, pass the compilation database json file as in \
|
|
|
|
Config.print_usage_exit ());
|
|
|
|
infer -- clang-compilation-database file.json." ;
|
|
|
|
capture_with_compilation_database cmd_args
|
|
|
|
Config.print_usage_exit ()
|
|
|
|
|
|
|
|
)
|
|
|
|
|
|
|
|
| Genrule ->
|
|
|
|
| Genrule ->
|
|
|
|
L.stdout "Capturing for Buck genrule compatibility...@\n";
|
|
|
|
L.stdout "Capturing for Buck genrule compatibility...@\n";
|
|
|
|
let infer_java = Config.bin_dir ^/ "InferJava" in
|
|
|
|
let infer_java = Config.bin_dir ^/ "InferJava" in
|
|
|
|