Fix for building under python3.5 via bootstrap
authorgrbd <garlicbready@googlemail.com>
Tue, 15 Aug 2017 12:07:54 +0000 (13:07 +0100)
committergrbd <garlicbready@googlemail.com>
Tue, 15 Aug 2017 12:07:54 +0000 (13:07 +0100)
src/engine/SCons/Tool/MSCommon/vc.py

index 7c9eab55f91f297e0072aa1cbd0559fb21f7e7bc..53bd397787ee6abccd053cfa460eea0beaf60de9 100644 (file)
@@ -245,7 +245,9 @@ def find_vc_pdir_vswhere(msvc_version):
     if os.path.exists(vswhere_path):
         sp = subprocess.Popen(vswhere_cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
         vsdir, err = sp.communicate()
-        vc_pdir = os.path.join(vsdir.rstrip(), 'VC')
+        vsdir = vsdir.decode("mbcs")
+        vsdir = vsdir.rstrip()
+        vc_pdir = os.path.join(vsdir, 'VC')
         return vc_pdir
     else:
         # No vswhere on system, no install info available