Earl Ou has uploaded this change for review. ( https://gem5-review.googlesource.com/c/public/gem5/+/35595 )

Change subject: SCons: avoid interactive access in non-tty
......................................................................

SCons: avoid interactive access in non-tty

We saw some strange behavior when building scons without an interactive
TTY. This seems be caused by the control signal set from
curses.initscr() and endwin(). To avoid issues, we should avoid those
operation when running in non interactive situation.

Change-Id: I9cf8e48a786d47d567ba193f0b069f638e8db647
---
M site_scons/gem5_scons/__init__.py
1 file changed, 4 insertions(+), 0 deletions(-)



diff --git a/site_scons/gem5_scons/__init__.py b/site_scons/gem5_scons/__init__.py
index 169e0fe..7fa8d3d 100644
--- a/site_scons/gem5_scons/__init__.py
+++ b/site_scons/gem5_scons/__init__.py
@@ -41,6 +41,7 @@
 from __future__ import print_function

 import os
+import sys
 import textwrap

 from gem5_scons.util import get_termcap
@@ -131,6 +132,9 @@
 # The width warning and error messages should be wrapped at.
 text_width = None

+if not sys.stdout.isatty():
+    text_width = 80
+
 # This should work in python 3.3 and above.
 if text_width is None:
     try:

--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/35595
To unsubscribe, or for help writing mail filters, visit https://gem5-review.googlesource.com/settings

Gerrit-Project: public/gem5
Gerrit-Branch: develop
Gerrit-Change-Id: I9cf8e48a786d47d567ba193f0b069f638e8db647
Gerrit-Change-Number: 35595
Gerrit-PatchSet: 1
Gerrit-Owner: Earl Ou <[email protected]>
Gerrit-MessageType: newchange
_______________________________________________
gem5-dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s

Reply via email to