[Python-checkins] python/dist/src/Lib/plat-mac pimp.py,1.13,1.14
jackjansen@users.sourceforge.net
jackjansen@users.sourceforge.net
Mon, 17 Mar 2003 02:54:44 -0800
Update of /cvsroot/python/python/dist/src/Lib/plat-mac
In directory sc8-pr-cvs1:/tmp/cvs-serv4420/Lib/plat-mac
Modified Files:
pimp.py
Log Message:
Capturing the exit status for the build process didn't work. Using
popen2.Popen4() makes it work. Fixes #702180.
Index: pimp.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/plat-mac/pimp.py,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -d -r1.13 -r1.14
*** pimp.py 11 Mar 2003 14:37:19 -0000 1.13
--- pimp.py 17 Mar 2003 10:54:41 -0000 1.14
***************
*** 15,18 ****
--- 15,19 ----
import sys
import os
+ import popen2
import urllib
import urllib2
***************
*** 396,409 ****
if NO_EXECUTE:
return 0
! dummy, fp = os.popen4(cmd, "r")
! dummy.close()
while 1:
! line = fp.readline()
if not line:
break
if output:
output.write(line)
! rv = fp.close()
! return rv
def downloadPackageOnly(self, output=None):
--- 397,409 ----
if NO_EXECUTE:
return 0
! child = popen2.Popen4(cmd)
! child.tochild.close()
while 1:
! line = child.fromchild.readline()
if not line:
break
if output:
output.write(line)
! return child.wait()
def downloadPackageOnly(self, output=None):
***************
*** 589,593 ****
installcmd = '"%s" setup.py install' % sys.executable
if self._cmd(output, self._buildDirname, installcmd):
! return "install %s: running \"%s\" failed" % self.fullname()
self.afterInstall()
--- 589,594 ----
installcmd = '"%s" setup.py install' % sys.executable
if self._cmd(output, self._buildDirname, installcmd):
! return "install %s: running \"%s\" failed" % \
! (self.fullname(), installcmd)
self.afterInstall()