diff options
author | Manish Goregaokar <manishsmail@gmail.com> | 2020-04-15 22:55:05 -0700 |
---|---|---|
committer | Manish Goregaokar <manishsmail@gmail.com> | 2020-04-16 10:01:17 -0700 |
commit | 371ba67d55408237ca79c8b9a8d1a5072a2d028f (patch) | |
tree | 930162aedec978546012df7de99f0330e87912b7 /python/servo/build_commands.py | |
parent | 16230ee27917ce22497ebc21f91d5a856be9f217 (diff) | |
download | servo-371ba67d55408237ca79c8b9a8d1a5072a2d028f.tar.gz servo-371ba67d55408237ca79c8b9a8d1a5072a2d028f.zip |
Report error when vcvarsall fails
Diffstat (limited to 'python/servo/build_commands.py')
-rw-r--r-- | python/servo/build_commands.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/python/servo/build_commands.py b/python/servo/build_commands.py index cb54497377a..88b3e976f34 100644 --- a/python/servo/build_commands.py +++ b/python/servo/build_commands.py @@ -315,11 +315,15 @@ class MachCommands(CommandBase): process = subprocess.Popen('("%s" %s > nul) && "python" -c "import os; print(repr(os.environ))"' % (os.path.join(vs_dirs['vcdir'], "Auxiliary", "Build", "vcvarsall.bat"), "x64"), stdout=subprocess.PIPE, shell=True) - stdout, _ = process.communicate() + stdout, stderr = process.communicate() exitcode = process.wait() encoding = locale.getpreferredencoding() # See https://stackoverflow.com/a/9228117 if exitcode == 0: os.environ.update(eval(stdout.decode(encoding))) + else: + print("Failed to run vcvarsall. stderr:") + print(stderr.decode(encoding)) + exit(1) # Ensure that GStreamer libraries are accessible when linking. if 'windows' in target_triple: |