summaryrefslogtreecommitdiffstats
path: root/llvm/utils/gn/build/write_vcsrevision.py
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/utils/gn/build/write_vcsrevision.py')
-rwxr-xr-xllvm/utils/gn/build/write_vcsrevision.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/utils/gn/build/write_vcsrevision.py b/llvm/utils/gn/build/write_vcsrevision.py
index ed7c05f1d0e..b9b3755526c 100755
--- a/llvm/utils/gn/build/write_vcsrevision.py
+++ b/llvm/utils/gn/build/write_vcsrevision.py
@@ -52,9 +52,9 @@ def main():
git = which('git.bat')
use_shell = True
rev = subprocess.check_output([git, 'rev-parse', '--short', 'HEAD'],
- cwd=git_dir, shell=use_shell)
+ cwd=git_dir, shell=use_shell).decode().strip()
# FIXME: add pizzas such as the svn revision read off a git note?
- vcsrevision_contents = '#define LLVM_REVISION "git-%s"\n' % rev.strip()
+ vcsrevision_contents = '#define LLVM_REVISION "git-%s"\n' % rev
# If the output already exists and is identical to what we'd write,
# return to not perturb the existing file's timestamp.
OpenPOWER on IntegriCloud