From 2893440374718d67bce4247afbba0d1535f679d7 Mon Sep 17 00:00:00 2001 From: Doug MacEachern Date: Wed, 18 Nov 2009 13:26:33 -0800 Subject: [PATCH] commands.getoutput does not work on win32, switch to popen --- bindings/python/setup.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) mode change 100644 => 100755 bindings/python/setup.py diff --git a/bindings/python/setup.py b/bindings/python/setup.py old mode 100644 new mode 100755 index 24e09a05..89f87268 --- a/bindings/python/setup.py +++ b/bindings/python/setup.py @@ -1,8 +1,8 @@ #!/usr/bin/env python from distutils.core import setup, Extension -from os import system, mkdir, path -import sys, commands +from os import system, mkdir, path, popen +import sys build = 'build' options = {'perl':'perl'} @@ -21,7 +21,7 @@ def parse_args(): options['perl'] = value def sbuild(cmd): - return commands.getoutput(options['perl'] + ' -Mlib=.. -MSigarBuild -e ' + cmd) + return popen(options['perl'] + ' -Mlib=.. -MSigarBuild -e ' + cmd).readline() def sargs(cmd): res = sbuild(cmd)