setup: decode xcode version number on python3
authorAugie Fackler <augie@google.com>
Sun, 12 Apr 2015 16:13:38 -0400
changeset 25043 facaceeb85ac
parent 25042 201823c50610
child 25044 9de94acfde8a
setup: decode xcode version number on python3
setup.py
--- a/setup.py	Sun Apr 12 15:35:57 2015 -0400
+++ b/setup.py	Sun Apr 12 16:13:38 2015 -0400
@@ -573,6 +573,8 @@
     version = runcmd(['/usr/bin/xcodebuild', '-version'], {})[0].splitlines()
     if version:
         version = version[0]
+        if sys.version_info[0] == 3:
+            version = version.decode('utf-8')
         xcode4 = (version.startswith('Xcode') and
                   StrictVersion(version.split()[1]) >= StrictVersion('4.0'))
         xcode51 = re.match(r'^Xcode\s+5\.1', version) is not None