Report the exit code for failed build-time executions. (#894)
Bug: https://github.com/dart-lang/sdk/issues/56529
diff --git a/build/gn_run_binary.py b/build/gn_run_binary.py
index 156ea19..3d682eb 100644
--- a/build/gn_run_binary.py
+++ b/build/gn_run_binary.py
@@ -22,5 +22,7 @@
try:
subprocess.check_output(args, stderr=subprocess.STDOUT)
except subprocess.CalledProcessError as ex:
+ print("Command failed: " + ' '.join(args))
+ print("exitCode: " + str(ex.returncode))
print(ex.output.decode('utf-8', errors='replace'))
sys.exit(ex.returncode)