Index: win_toolchain/get_toolchain_if_necessary.py |
diff --git a/win_toolchain/get_toolchain_if_necessary.py b/win_toolchain/get_toolchain_if_necessary.py |
index cb4b5da2c64e02936fae53d237b4ed9ea130bb1d..5bda1eecc2c25f4e27073ed85da6d4ff66022686 100755 |
--- a/win_toolchain/get_toolchain_if_necessary.py |
+++ b/win_toolchain/get_toolchain_if_necessary.py |
@@ -290,26 +290,27 @@ def main(): |
got_new_toolchain = True |
- win_sdk = os.path.join(abs_target_dir, 'win_sdk') |
- try: |
- with open(os.path.join(target_dir, 'VS_VERSION'), 'rb') as f: |
- vs_version = f.read().strip() |
- except IOError: |
- # Older toolchains didn't have the VS_VERSION file, and used 'win8sdk' |
- # instead of just 'win_sdk'. |
- vs_version = '2013' |
- win_sdk = os.path.join(abs_target_dir, 'win8sdk') |
- |
data = { |
'path': abs_target_dir, |
- 'version': vs_version, |
- 'win_sdk': win_sdk, |
+ 'win_sdk': os.path.join(abs_target_dir, 'win_sdk'), |
'wdk': os.path.join(abs_target_dir, 'wdk'), |
'runtime_dirs': [ |
os.path.join(abs_target_dir, 'sys64'), |
os.path.join(abs_target_dir, 'sys32'), |
], |
} |
+ |
+ try: |
+ with open(os.path.join(target_dir, 'VS_VERSION'), 'rb') as f: |
+ vs_version = f.read().strip() |
+ except IOError: |
+ # Older toolchains didn't have the VS_VERSION file, and used 'win8sdk' |
+ # instead of just 'win_sdk'. |
+ vs_version = '2013' |
+ data['win8sdk'] = os.path.join(abs_target_dir, 'win8sdk') |
+ |
+ data['version'] = vs_version |
+ |
with open(os.path.join(target_dir, '..', 'data.json'), 'w') as f: |
json.dump(data, f) |