diff options
author | Tobias Bosch <tbosch@google.com> | 2019-07-19 06:53:07 -0700 |
---|---|---|
committer | Tobias Bosch <tbosch@google.com> | 2019-07-22 08:06:56 +0000 |
commit | b27c8f27362dca908c880adb45fb1ec537064b9c (patch) | |
tree | 536a9c91991badbaf9839284889800fbf9916557 /compiler_wrapper/testdata | |
parent | 31dec2c8cf3e272dc0bd1523e72565d9b2d3bcfb (diff) | |
download | toolchain-utils-b27c8f27362dca908c880adb45fb1ec537064b9c.tar.gz |
Support gcc host wrapper.
This change adds support for the gcc host wrapper.
The implementation is verified via comparing to the old
gcc host wrapper in the golden tests.
BUG=chromium:773875
TEST=unit test
Change-Id: I3af98b81dba6d9299183db01e967003be860972c
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/toolchain-utils/+/1710537
Tested-by: Tobias Bosch <tbosch@google.com>
Reviewed-by: George Burgess <gbiv@chromium.org>
Diffstat (limited to 'compiler_wrapper/testdata')
-rw-r--r-- | compiler_wrapper/testdata/cros_gcc_host_golden.json | 365 |
1 files changed, 365 insertions, 0 deletions
diff --git a/compiler_wrapper/testdata/cros_gcc_host_golden.json b/compiler_wrapper/testdata/cros_gcc_host_golden.json new file mode 100644 index 00000000..b7b79e04 --- /dev/null +++ b/compiler_wrapper/testdata/cros_gcc_host_golden.json @@ -0,0 +1,365 @@ +[ + { + "name": "gcc path", + "records": [ + { + "wd": "/tmp/stable", + "wrapper": { + "cmd": { + "path": "./x86_64-cros-linux-gnu-gcc", + "args": [ + "main.cc" + ] + } + }, + "cmds": [ + { + "cmd": { + "path": "./x86_64-cros-linux-gnu-gcc.real", + "args": [ + "-Wno-maybe-uninitialized", + "-Wno-unused-local-typedefs", + "-Wno-deprecated-declarations", + "main.cc" + ] + } + } + ] + }, + { + "wd": "/tmp/stable", + "wrapper": { + "cmd": { + "path": "./x86_64-cros-linux-gnu-gcc", + "args": [ + "main.cc" + ] + }, + "stdout": "somemessage", + "stderr": "someerror", + "exitcode": 1 + }, + "cmds": [ + { + "cmd": { + "path": "./x86_64-cros-linux-gnu-gcc.real", + "args": [ + "-Wno-maybe-uninitialized", + "-Wno-unused-local-typedefs", + "-Wno-deprecated-declarations", + "main.cc" + ] + }, + "stdout": "somemessage", + "stderr": "someerror", + "exitcode": 1 + } + ] + } + ] + }, + { + "name": "gcc [main.cc] target specific", + "records": [ + { + "wd": "/tmp/stable", + "wrapper": { + "cmd": { + "path": "./x86_64-cros-linux-gnu-gcc", + "args": [ + "main.cc" + ] + } + }, + "cmds": [ + { + "cmd": { + "path": "./x86_64-cros-linux-gnu-gcc.real", + "args": [ + "-Wno-maybe-uninitialized", + "-Wno-unused-local-typedefs", + "-Wno-deprecated-declarations", + "main.cc" + ] + } + } + ] + }, + { + "wd": "/tmp/stable", + "wrapper": { + "cmd": { + "path": "./x86_64-cros-linux-eabi-gcc", + "args": [ + "main.cc" + ] + } + }, + "cmds": [ + { + "cmd": { + "path": "./x86_64-cros-linux-eabi-gcc.real", + "args": [ + "-Wno-maybe-uninitialized", + "-Wno-unused-local-typedefs", + "-Wno-deprecated-declarations", + "main.cc" + ] + } + } + ] + }, + { + "wd": "/tmp/stable", + "wrapper": { + "cmd": { + "path": "./x86_64-cros-win-gnu-gcc", + "args": [ + "main.cc" + ] + } + }, + "cmds": [ + { + "cmd": { + "path": "./x86_64-cros-win-gnu-gcc.real", + "args": [ + "-Wno-maybe-uninitialized", + "-Wno-unused-local-typedefs", + "-Wno-deprecated-declarations", + "main.cc" + ] + } + } + ] + }, + { + "wd": "/tmp/stable", + "wrapper": { + "cmd": { + "path": "./armv7m-cros-linux-gnu-gcc", + "args": [ + "main.cc" + ] + } + }, + "cmds": [ + { + "cmd": { + "path": "./armv7m-cros-linux-gnu-gcc.real", + "args": [ + "-Wno-maybe-uninitialized", + "-Wno-unused-local-typedefs", + "-Wno-deprecated-declarations", + "main.cc" + ] + } + } + ] + }, + { + "wd": "/tmp/stable", + "wrapper": { + "cmd": { + "path": "./armv7m-cros-linux-eabi-gcc", + "args": [ + "main.cc" + ] + } + }, + "cmds": [ + { + "cmd": { + "path": "./armv7m-cros-linux-eabi-gcc.real", + "args": [ + "-Wno-maybe-uninitialized", + "-Wno-unused-local-typedefs", + "-Wno-deprecated-declarations", + "main.cc" + ] + } + } + ] + }, + { + "wd": "/tmp/stable", + "wrapper": { + "cmd": { + "path": "./armv7m-cros-win-gnu-gcc", + "args": [ + "main.cc" + ] + } + }, + "cmds": [ + { + "cmd": { + "path": "./armv7m-cros-win-gnu-gcc.real", + "args": [ + "-Wno-maybe-uninitialized", + "-Wno-unused-local-typedefs", + "-Wno-deprecated-declarations", + "main.cc" + ] + } + } + ] + }, + { + "wd": "/tmp/stable", + "wrapper": { + "cmd": { + "path": "./armv8m-cros-linux-gnu-gcc", + "args": [ + "main.cc" + ] + } + }, + "cmds": [ + { + "cmd": { + "path": "./armv8m-cros-linux-gnu-gcc.real", + "args": [ + "-Wno-maybe-uninitialized", + "-Wno-unused-local-typedefs", + "-Wno-deprecated-declarations", + "main.cc" + ] + } + } + ] + }, + { + "wd": "/tmp/stable", + "wrapper": { + "cmd": { + "path": "./armv8m-cros-linux-eabi-gcc", + "args": [ + "main.cc" + ] + } + }, + "cmds": [ + { + "cmd": { + "path": "./armv8m-cros-linux-eabi-gcc.real", + "args": [ + "-Wno-maybe-uninitialized", + "-Wno-unused-local-typedefs", + "-Wno-deprecated-declarations", + "main.cc" + ] + } + } + ] + }, + { + "wd": "/tmp/stable", + "wrapper": { + "cmd": { + "path": "./armv8m-cros-win-gnu-gcc", + "args": [ + "main.cc" + ] + } + }, + "cmds": [ + { + "cmd": { + "path": "./armv8m-cros-win-gnu-gcc.real", + "args": [ + "-Wno-maybe-uninitialized", + "-Wno-unused-local-typedefs", + "-Wno-deprecated-declarations", + "main.cc" + ] + } + } + ] + } + ] + }, + { + "name": "gcc specific args", + "records": [ + { + "wd": "/tmp/stable", + "wrapper": { + "cmd": { + "path": "./x86_64-cros-linux-gnu-gcc", + "args": [ + "-march=goldmont", + "main.cc" + ] + } + }, + "cmds": [ + { + "cmd": { + "path": "./x86_64-cros-linux-gnu-gcc.real", + "args": [ + "-Wno-maybe-uninitialized", + "-Wno-unused-local-typedefs", + "-Wno-deprecated-declarations", + "-march=goldmont", + "main.cc" + ] + } + } + ] + }, + { + "wd": "/tmp/stable", + "wrapper": { + "cmd": { + "path": "./x86_64-cros-linux-gnu-gcc", + "args": [ + "-march=goldmont-plus", + "main.cc" + ] + } + }, + "cmds": [ + { + "cmd": { + "path": "./x86_64-cros-linux-gnu-gcc.real", + "args": [ + "-Wno-maybe-uninitialized", + "-Wno-unused-local-typedefs", + "-Wno-deprecated-declarations", + "-march=goldmont-plus", + "main.cc" + ] + } + } + ] + }, + { + "wd": "/tmp/stable", + "wrapper": { + "cmd": { + "path": "./x86_64-cros-linux-gnu-gcc", + "args": [ + "-march=skylake", + "main.cc" + ] + } + }, + "cmds": [ + { + "cmd": { + "path": "./x86_64-cros-linux-gnu-gcc.real", + "args": [ + "-Wno-maybe-uninitialized", + "-Wno-unused-local-typedefs", + "-Wno-deprecated-declarations", + "-march=skylake", + "main.cc" + ] + } + } + ] + } + ] + } +] |