if __name__ == "__main__": configs = {} workspace = Path(sys.argv[1]) outbase = Path(sys.argv[2]) common_copied = False for platform, uwp in product(PLATFORMS, TRUE_FALSE): # ARM/ARM64 is only built for the UWP platform. if not uwp and (platform.lower() == 'arm' or platform.lower() == 'arm64'): continue platform_dirname = '{}{}'.format(platform, '_uwp' if uwp else '') name = make_win_artifact_name(platform, uwp) artifact = workspace / name if not common_copied: # Start by copying the full tree over. shutil.copytree(artifact, outbase, dirs_exist_ok=True) common_copied = True continue # lib files shutil.copytree(artifact / platform_dirname, outbase / platform_dirname, dirs_exist_ok=True)
#!/usr/bin/env python3 # Copyright (c) 2019 The Khronos Group Inc. from itertools import product from shared import PLATFORMS, TRUE_FALSE, VS_VERSION, make_win_artifact_name if __name__ == "__main__": for platform, uwp in product(PLATFORMS, TRUE_FALSE): print(make_win_artifact_name(platform, uwp))
print(str(src), '->', str(dest)) src.replace(dest) if __name__ == "__main__": configs = {} workspace = Path(sys.argv[1]) outbase = Path(sys.argv[2]) for vsver, dynamic in product(VS_VERSIONS.keys(), TRUE_FALSE): base = outbase / 'msvs{}_{}'.format(vsver, 'dynamic' if dynamic else 'static') base.mkdir(parents=True, exist_ok=True) name_64 = make_win_artifact_name(vsver, dynamic, 64) name_32 = make_win_artifact_name(vsver, dynamic, 32) artifact_64 = workspace / name_64 artifact_32 = workspace / name_32 # Move over one set of includes move(artifact_32 / 'include', base / 'include') # lib files move(artifact_32 / 'lib', base / 'lib32') move(artifact_64 / 'lib', base / 'lib') if dynamic: # dll files move(artifact_32 / 'bin', base / 'bin32') move(artifact_64 / 'bin', base / 'bin')
configs = {} for platform, debug, uwp in product(PLATFORMS, (False, ), TRUE_FALSE): # No need to support ARM/ARM64 except for UWP. if not uwp and (platform.lower() == 'arm' or platform.lower() == 'arm64'): continue label = [platform] config = [] generator = VS_VERSION config.append('-A ' + platform) config.append('-DDYNAMIC_LOADER=ON') if debug: label.append('debug') if uwp: label.append('UWP') config.append( '-DCMAKE_SYSTEM_NAME=WindowsStore -DCMAKE_SYSTEM_VERSION=10.0') name = '_'.join(label) configs[name] = { 'generator': generator, 'buildType': 'Debug' if debug else 'RelWithDebInfo', 'cmakeArgs': ' '.join(config) } if not debug: configs[name]['artifactName'] = make_win_artifact_name( platform, uwp) output_json(configs)
(False, ), TRUE_FALSE): label = [str(vsver)] config = [] generator = VS_VERSIONS[vsver] if bits == 64: config.append('-A x64') else: config.append('-A Win32') label.append(str(bits)) if dynamic: label.append('dynamic') config.append('-DDYNAMIC_LOADER=ON') else: label.append('static') config.append('-DDYNAMIC_LOADER=OFF') if debug: label.append('debug') name = '_'.join(label) configs[name] = { 'generator': generator, 'buildType': 'Debug' if debug else 'RelWithDebInfo', 'cmakeArgs': ' '.join(config), 'dynamic': dynamic, 'bits': bits } if not debug: configs[name]['artifactName'] = make_win_artifact_name( vsver, dynamic, bits) output_json(configs)
#!/usr/bin/env python3 # Copyright (c) 2019 The Khronos Group Inc. from itertools import product from shared import BITS, TRUE_FALSE, VS_VERSIONS, make_win_artifact_name if __name__ == "__main__": for vsver, bits, dynamic in product(VS_VERSIONS.keys(), BITS, TRUE_FALSE): print(make_win_artifact_name(vsver, dynamic, bits))