compiler_wrapper: add --rewrapper-path support

This CL adds --rewrapper-path support to the compiler, as requested in
the linked bug. The use of this is mutually exclusive with that of
--gomacc-path.

We currently look for either a `--gomacc-path` flag or a `GOMACC_PATH`
env var to enable goma. If any rewrapper flag is specified, this
disables our checking of `GOMACC_PATH` for the purposes of mutual
exclusivity checking.

BUG=b:190741226
TEST=go test, a few manual invocations

Change-Id: I03dd2835a313806a9700c49c47c82fecf19a4b7f
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/toolchain-utils/+/2956696
Reviewed-by: Ryan Beltran <ryanbeltran@chromium.org>
Tested-by: George Burgess <gbiv@chromium.org>
4 files changed