Skip to content

Commit

Permalink
[clang] Disable -fembed-bitcode
Browse files Browse the repository at this point in the history
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
  • Loading branch information
jberdine authored and facebook-github-bot committed Jul 28, 2017
1 parent fa1c89a commit b36eaa2
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions infer/src/clang/ClangWrapper.ml
Original file line number Diff line number Diff line change
Expand Up @@ -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 ;
Expand Down

0 comments on commit b36eaa2

Please sign in to comment.