Update mcc16 and the ancient Clang plugin for the 'cmd_line' -> 'command' change.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@96933 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Mikhail Glushenkov
2010-02-23 09:59:30 +00:00
parent 112257d290
commit 9e7d90bcfc
3 changed files with 32 additions and 38 deletions

View File

@@ -24,23 +24,17 @@ class clang_based<string language, string cmd, string ext_E> : Tool<
[(in_language language),
(out_language "llvm-bitcode"),
(output_suffix "bc"),
(cmd_line (case
(switch_on "E"),
(case
(not_empty "o"),
!strconcat(cmd, " -E $INFILE -o $OUTFILE"),
(default),
!strconcat(cmd, " -E $INFILE")),
(and (switch_on "S"), (switch_on "emit-llvm")),
!strconcat(cmd, " -emit-llvm $INFILE -o $OUTFILE"),
(default),
!strconcat(cmd, " -emit-llvm-bc $INFILE -o $OUTFILE"))),
(command cmd),
(actions (case (switch_on "E"),
[(stop_compilation), (output_suffix ext_E)],
[(forward "E"), (stop_compilation), (output_suffix ext_E)],
(and (switch_on "E"), (empty "o")), (no_out_file),
(switch_on "fsyntax-only"), (stop_compilation),
(and (switch_on "S"), (switch_on "emit-llvm")),
[(stop_compilation), (output_suffix "ll")],
(and (switch_on "c"), (switch_on "emit-llvm")),
(switch_on ["S", "emit-llvm"]),
[(append_cmd "-emit-llvm"),
(stop_compilation), (output_suffix "ll")],
(not (switch_on ["S", "emit-llvm"])),
(append_cmd "-emit-llvm-bc"),
(switch_on ["c", "emit-llvm"]),
(stop_compilation),
(not_empty "include"), (forward "include"),
(not_empty "I"), (forward "I"))),
@@ -58,7 +52,7 @@ def as : Tool<
[(in_language "assembler"),
(out_language "object-code"),
(output_suffix "o"),
(cmd_line "as $INFILE -o $OUTFILE"),
(command "as"),
(actions (case (not_empty "Wa,"), (forward_value "Wa,"),
(switch_on "c"), (stop_compilation)))
]>;
@@ -68,7 +62,7 @@ def llvm_ld : Tool<
[(in_language "object-code"),
(out_language "executable"),
(output_suffix "out"),
(cmd_line "llvm-ld -native -disable-internalize $INFILE -o $OUTFILE"),
(command "llvm-ld -native -disable-internalize"),
(actions (case
(switch_on "pthread"), (append_cmd "-lpthread"),
(not_empty "L"), (forward "L"),