aboutsummaryrefslogtreecommitdiff
path: root/tools/shared.py
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2012-09-24 12:59:03 -0700
committerAlon Zakai <alonzakai@gmail.com>2012-09-24 12:59:03 -0700
commit0f67eac88b3606e1e69c1eb7b7144185e107ea87 (patch)
treec1ab042512ff70d66a1a24b14cbf1ea14a5a8e57 /tools/shared.py
parent8447be68d839d591b8155b5934e479ee316ecc37 (diff)
fix python conventions
Diffstat (limited to 'tools/shared.py')
-rw-r--r--tools/shared.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/tools/shared.py b/tools/shared.py
index c0c48b68..9f51f008 100644
--- a/tools/shared.py
+++ b/tools/shared.py
@@ -550,14 +550,14 @@ set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY)''' % { 'winfix': '' if not WINDOWS e
if configure: # Useful in debugging sometimes to comment this out (and the lines below up to and including the |link| call)
Building.configure(configure + configure_args, stdout=open(os.path.join(project_dir, 'configure_'), 'w'),
stderr=open(os.path.join(project_dir, 'configure_err'), 'w'), env=env)
- def openMakeOut(i, mode='r'):
+ def open_make_out(i, mode='r'):
return open(os.path.join(project_dir, 'make_' + str(i)), mode)
- def openMakeErr(i, mode='r'):
+ def open_make_err(i, mode='r'):
return open(os.path.join(project_dir, 'make_err' + str(i)), mode)
for i in range(2): # FIXME: Sad workaround for some build systems that need to be run twice to succeed (e.g. poppler)
- with openMakeOut(i, 'w') as make_out, openMakeErr(i, 'w') as make_err:
+ with open_make_out(i, 'w') as make_out, open_make_err(i, 'w') as make_err:
Building.make(make + make_args, stdout=make_out,
stderr=make_err, env=env)
try:
@@ -570,7 +570,7 @@ set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY)''' % { 'winfix': '' if not WINDOWS e
except:
if i > 0:
# Due to the ugly hack above our best guess is to output the first run
- with openMakeErr(0) as ferr:
+ with open_make_err(0) as ferr:
for line in ferr:
sys.stderr.write(line)
raise Exception('could not build library ' + name)