icd_file_name = 'vulkan_radeon.dll'
endif
+icd_command = [
+ prog_python, '@INPUT0@',
+ '--api-version', '1.2', '--xml', '@INPUT1@',
+ '--lib-path', join_paths(icd_lib_path, icd_file_name),
+ '--out', '@OUTPUT@',
+]
+if with_platform_windows
+ icd_command += '--use-backslash'
+endif
+
radeon_icd = custom_target(
'radeon_icd',
input : [vk_icd_gen, vk_api_xml],
output : 'radeon_icd.@0@.json'.format(host_machine.cpu()),
- command : [
- prog_python, '@INPUT0@',
- '--api-version', '1.2', '--xml', '@INPUT1@',
- '--lib-path', join_paths(icd_lib_path, icd_file_name),
- '--out', '@OUTPUT@',
- ],
+ command : icd_command,
build_by_default : true,
install_dir : with_vulkan_icd_dir,
install : true,
help='Path to installed library')
parser.add_argument('--out', required=False,
help='Output json file.')
+ parser.add_argument('--use-backslash', action='store_true',
+ help='Use backslash (Windows).')
args = parser.parse_args()
version = args.api_version
else:
re.match(r'\d+\.\d+\.\d+', version)
+ lib_path = args.lib_path
+ if args.use_backslash:
+ lib_path = lib_path.replace('/', '\\')
+
json_data = {
'file_format_version': '1.0.0',
'ICD': {
- 'library_path': args.lib_path,
+ 'library_path': lib_path,
'api_version': version,
},
}