def exec_helper(self, cmd, builddir):
try:<EOL><INDENT>child = subprocess.Popen(cmd, cwd=builddir)<EOL>child.wait()<EOL><DEDENT>except OSError as e:<EOL><INDENT>if e.errno == errno.ENOENT:<EOL><INDENT>if cmd[<NUM_LIT:0>] == '<STR_LIT>':<EOL><INDENT>return '<STR_LIT>'<EOL><DEDENT>else:<EOL><INDENT>return '<STR_LIT>' % (cmd[<NUM_LIT:0>])<EOL><DEDENT><DEDENT>else:<EOL><INDENT>return '<STR_LIT>' % (cmd)<EOL><DEDENT><DEDENT>if child.returncode:<EOL><INDENT>return '<STR_LIT>' % (cmd)<EOL><DEDENT>
Execute the given command, returning an error message if an error occured
            or None if the command was succesful.