setup.py: In debug mode, display 2to3 logs.

This commit is contained in:
Valentin Lorentz 2013-02-22 21:17:16 +01:00
parent 3e26a2d7cf
commit 38d039ada2
1 changed files with 7 additions and 3 deletions

View File

@ -81,6 +81,10 @@ elif sys.version_info[0] >= 3:
'few minutes.')
# For some reason, using open(os.devnull) makes the subprocess exit before
# it finishes...
if debug:
subprocess.Popen([sys.executable,
os.path.join('2to3', 'run.py')]).wait()
else:
subprocess.Popen([sys.executable, os.path.join('2to3', 'run.py')],
stdout=tempfile.TemporaryFile(),
stderr=tempfile.TemporaryFile()).wait()