diff options
author | Luca Falavigna <dktrkranz@debian.org> | 2010-03-25 20:51:52 +0100 |
---|---|---|
committer | Luca Falavigna <dktrkranz@debian.org> | 2010-03-25 20:51:52 +0100 |
commit | e7885e3af440eaef38a9301fd92a105afc8ddebb (patch) | |
tree | 184d5a614080dace236bafd02e671a3bab6e73b6 /src/engine/SCons/Tool/MSCommon/vc.py | |
parent | 68e4fe5ac49effe8959bc8532584edf04553c931 (diff) |
Imported Upstream version 1.3.0upstream/1.3.0
Diffstat (limited to 'src/engine/SCons/Tool/MSCommon/vc.py')
-rw-r--r-- | src/engine/SCons/Tool/MSCommon/vc.py | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/src/engine/SCons/Tool/MSCommon/vc.py b/src/engine/SCons/Tool/MSCommon/vc.py index f2f2a01..5ea5a53 100644 --- a/src/engine/SCons/Tool/MSCommon/vc.py +++ b/src/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( |