Check that update.py's VERSION matches toolchain.gni's clang_version.

We can't just let update.py compute the contents of clang_revision because
that's used in several .gn files and we'd have to shell out to slow python
several times.  This would slow down gn while only being beneficial every
6 months when the LLVM version increases.

However, we can hand down clang_revision to the script in the one place
where we call it with --print-revision, and make the script check that
the handed-in version matches the internal VERSION.  This way, gn at
least checks that the two values are in sync so that we won't again
forget to update clang_revision.  (update.py already checks that
VERSION matches what `clang --version` prints.)

Bug: none
Change-Id: I6f130a848ad881f18915c30e84061ffa59128a53
Reviewed-on: https://chromium-review.googlesource.com/928829
Commit-Queue: Nico Weber <thakis@chromium.org>
Reviewed-by: Hans Wennborg <hans@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#538403}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 80edee6cf6cb6c16abbd07343d42bf5276a07e2e
1 file changed