New submission from Joe Chan: cannot return correct gcc version if the path name contains "space". Suggest to change to:
$ diff -rupN cygwinccompiler.py.original cygwinccompiler.py --- cygwinccompiler.py.original 2014-05-12 23:54:01.296303800 +0800 +++ cygwinccompiler.py 2014-05-12 23:59:57.429673400 +0800 @@ -418,14 +418,14 @@ def get_versions(): gcc_exe = find_executable('gcc') if gcc_exe: - out = os.popen(gcc_exe + ' -dumpversion','r') + out = os.popen('"%s" -dumpversion'%gcc_exe,'r') out_string = out.read() out.close() result = re.search('(\d+\.\d+(\.\d+)*)',out_string) if result: gcc_version = LooseVersion(result.group(1)) else: - gcc_version = None + gcc_version = None else: gcc_version = None ld_exe = find_executable('ld') ---------- components: Windows messages: 218327 nosy: 3togo priority: normal severity: normal status: open title: get_versions() in cygwinccomiler.py cannot return correct gcc version type: compile error versions: Python 2.7 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue21482> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com