forked from len0rd/rockbox
Add simple progress indicator when building.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23317 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
5b4938a8ca
commit
07e8647d88
1 changed files with 11 additions and 4 deletions
|
|
@ -192,10 +192,17 @@ def build(wd="."):
|
||||||
# make
|
# make
|
||||||
print "Building ..."
|
print "Building ..."
|
||||||
output = subprocess.Popen(["make"], stdout=subprocess.PIPE, cwd=wd)
|
output = subprocess.Popen(["make"], stdout=subprocess.PIPE, cwd=wd)
|
||||||
output.communicate()
|
while True:
|
||||||
if not output.returncode == 0:
|
c = output.stdout.readline()
|
||||||
print "Build failed!"
|
sys.stdout.write(".")
|
||||||
return -1
|
sys.stdout.flush()
|
||||||
|
if not output.poll() == None:
|
||||||
|
sys.stdout.write("\n")
|
||||||
|
sys.stdout.flush()
|
||||||
|
if not output.returncode == 0:
|
||||||
|
print "Build failed!"
|
||||||
|
return -1
|
||||||
|
break
|
||||||
# strip
|
# strip
|
||||||
print "Stripping binary."
|
print "Stripping binary."
|
||||||
output = subprocess.Popen(["strip", progexe], stdout=subprocess.PIPE, cwd=wd)
|
output = subprocess.Popen(["strip", progexe], stdout=subprocess.PIPE, cwd=wd)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue