]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Issue #18071: Extension module builds on OS X could fail with TypeError
authorNed Deily <nad@acm.org>
Wed, 31 Jul 2013 07:14:20 +0000 (00:14 -0700)
committerNed Deily <nad@acm.org>
Wed, 31 Jul 2013 07:14:20 +0000 (00:14 -0700)
if Xcode command line tools were not installed.

Lib/_osx_support.py
Misc/NEWS

index 79dbdc9ea3d4a4637edf6122653a699cde3b5209..195561aff306699d14d2a04e32936d7acfe8ba97 100644 (file)
@@ -53,7 +53,7 @@ def _find_executable(executable, path=None):
 
 
 def _read_output(commandstring):
-    """Output from succesful command execution or None"""
+    """Output from successful command execution or None"""
     # Similar to os.popen(commandstring, "r").read(),
     # but without actually using os.popen because that
     # function is not usable during python bootstrap.
@@ -68,7 +68,7 @@ def _read_output(commandstring):
 
     with contextlib.closing(fp) as fp:
         cmd = "%s 2>/dev/null >'%s'" % (commandstring, fp.name)
-        return fp.read().decode('utf-8').strip() if not os.system(cmd) else None
+        return fp.read().strip() if not os.system(cmd) else None
 
 
 def _find_build_tool(toolname):
index 2519380288897936d64d4885b65940e789784818..ee5c8f044fd691f5fcaf533bf260d9868d05c1d3 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -74,6 +74,9 @@ Library
   the default for linking if LDSHARED is not also overriden.  This restores
   Distutils behavior introduced in 2.7.3 and inadvertently dropped in 2.7.4.
 
+- Issue #18071: C extension module builds on OS X could fail with TypeError
+  if the Xcode command line tools were not installed.
+
 - Issue #18113: Fixed a refcount leak in the curses.panel module's
   set_userptr() method.  Reported by Atsuo Ishimoto.