Add a check for the VC++ 2012-style 64-bit path.
authorBen Vanik <ben.vanik@gmail.com>
Wed, 20 Feb 2013 06:28:26 +0000 (22:28 -0800)
committerBen Vanik <ben.vanik@gmail.com>
Wed, 20 Feb 2013 06:28:26 +0000 (22:28 -0800)
In VS2012 the path to the 64-bit tools has changed to
VCINSTALLDIR\bin\x86_amd64\cl.exe. This change will make the bootstrap
check there to see if it exists before falling back to the old amd64 path.

bootstrap.py

index 331ea0f..fcf1a20 100755 (executable)
@@ -85,7 +85,9 @@ if options.windows:
 vcdir = os.environ.get('VCINSTALLDIR')
 if vcdir:
     if options.x64:
-        cl = [os.path.join(vcdir, 'bin', 'amd64', 'cl.exe')]
+        cl = [os.path.join(vcdir, 'bin', 'x86_amd64', 'cl.exe')]
+        if not os.path.exists(cl[0]):
+            cl = [os.path.join(vcdir, 'bin', 'amd64', 'cl.exe')]
     else:
         cl = [os.path.join(vcdir, 'bin', 'cl.exe')]
     args = cl + ['/nologo', '/EHsc', '/DNOMINMAX']