From b36eaa261818d5fddcc472941642753f4eb48ac1 Mon Sep 17 00:00:00 2001 From: Josh Berdine Date: Fri, 28 Jul 2017 14:44:40 -0700 Subject: [PATCH] [clang] Disable -fembed-bitcode Summary: If -fembed-bitcode is passed, it leads to multiple cc1 commands, which try to read .bc files that don't get generated, and fail. So pass -fembed-bitcode=off to disable. Reviewed By: martinoluca Differential Revision: D5516879 fbshipit-source-id: 478057a --- infer/src/clang/ClangWrapper.ml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/infer/src/clang/ClangWrapper.ml b/infer/src/clang/ClangWrapper.ml index af191f028..660c6941e 100644 --- a/infer/src/clang/ClangWrapper.ml +++ b/infer/src/clang/ClangWrapper.ml @@ -67,6 +67,9 @@ let normalize ~prog ~args : action_item list = passing -Wno-ignored-optimization-argument prevents that. *) ClangCommand.append_args ["-fno-cxx-modules"; "-Qunused-arguments"; "-Wno-ignored-optimization-argument"] + |> (* If -fembed-bitcode is passed, it leads to multiple cc1 commands, which try to read .bc + files that don't get generated, and fail. So pass -fembed-bitcode=off to disable. *) + ClangCommand.append_args ["-fembed-bitcode=off"] |> ClangCommand.command_to_run ) in L.(debug Capture Medium) "clang -### invocation: %s@\n" clang_hashhashhash ;