summaryrefslogtreecommitdiff
path: root/engine/SCons/Tool/MSCommon/vc.py
diff options
context:
space:
mode:
authorLuca Falavigna <dktrkranz@debian.org>2010-03-25 20:26:28 +0100
committerLuca Falavigna <dktrkranz@debian.org>2010-03-25 20:26:28 +0100
commit86baccee0a1dddf43f7eefe48e2d9e9037468b9c (patch)
treea7513ae8ffa6429e3f67edcff60c3048d5ce65cc /engine/SCons/Tool/MSCommon/vc.py
parent0de5191eaec0321118254673e8f8414228668818 (diff)
Imported Upstream version 1.3.0upstream/1.3.0
Diffstat (limited to 'engine/SCons/Tool/MSCommon/vc.py')
-rw-r--r--engine/SCons/Tool/MSCommon/vc.py17
1 files changed, 12 insertions, 5 deletions
diff --git a/engine/SCons/Tool/MSCommon/vc.py b/engine/SCons/Tool/MSCommon/vc.py
index f2f2a01..5ea5a53 100644
--- a/engine/SCons/Tool/MSCommon/vc.py
+++ b/engine/SCons/Tool/MSCommon/vc.py
@@ -30,12 +30,13 @@
# * test on 64 bits XP + VS 2005 (and VS 6 if possible)
# * SDK
# * Assembly
-__revision__ = "src/engine/SCons/Tool/MSCommon/vc.py 4691 2010/03/06 16:22:36 bdbaddog"
+__revision__ = "src/engine/SCons/Tool/MSCommon/vc.py 4720 2010/03/24 03:14:11 jars"
__doc__ = """Module for Visual C/C++ detection and configuration.
"""
import SCons.compat
+import string
import os
import platform
@@ -115,16 +116,18 @@ def get_host_target(env):
return (host, target)
-_VCVER = ["10.0", "9.0", "8.0", "7.1", "7.0", "6.0"]
+_VCVER = ["10.0", "9.0", "9.0Exp","8.0", "8.0Exp","7.1", "7.0", "6.0"]
_VCVER_TO_PRODUCT_DIR = {
'10.0': [
r'Microsoft\VisualStudio\10.0\Setup\VC\ProductDir'],
'9.0': [
- r'Microsoft\VisualStudio\9.0\Setup\VC\ProductDir',
+ r'Microsoft\VisualStudio\9.0\Setup\VC\ProductDir'],
+ '9.0Exp' : [
r'Microsoft\VCExpress\9.0\Setup\VC\ProductDir'],
'8.0': [
- r'Microsoft\VisualStudio\8.0\Setup\VC\ProductDir',
+ r'Microsoft\VisualStudio\8.0\Setup\VC\ProductDir'],
+ '8.0Exp': [
r'Microsoft\VCExpress\8.0\Setup\VC\ProductDir'],
'7.1': [
r'Microsoft\VisualStudio\7.1\Setup\VC\ProductDir'],
@@ -214,7 +217,9 @@ def find_batch_file(env,msvc_version):
debug('vc.py: find_batch_file() pdir:%s'%pdir)
- vernum = float(msvc_version)
+ # filter out e.g. "Exp" from the version name
+ msvc_ver_numeric = string.join(filter(lambda x: x in string.digits + ".", msvc_version), '')
+ vernum = float(msvc_ver_numeric)
if 7 <= vernum < 8:
pdir = os.path.join(pdir, os.pardir, "Common7", "Tools")
batfilename = os.path.join(pdir, "vsvars32.bat")
@@ -285,6 +290,8 @@ def get_default_version(env):
msvc_version = env.get('MSVC_VERSION')
msvs_version = env.get('MSVS_VERSION')
+
+ debug('get_default_version(): msvc_version:%s msvs_version:%s'%(msvc_version,msvs_version))
if msvs_version and not msvc_version:
SCons.Warnings.warn(