SWDEV-420140 - Prefer forward slashes for path seperators in compiler RT path with windows

Certain build systems such as NMake seem to interpret backslashes as escapes.

Change-Id: Ifc04d9427148e83084efb1af94a1ce85cb2a6c4e
Esse commit está contido em:
Vikram
2024-01-11 11:48:51 -05:00
commit de Maneesh Gupta
commit cec5f0b704
+6
Ver Arquivo
@@ -178,6 +178,12 @@ if( CLANGRT_Error )
else()
# Add support for __fp16 and _Float16, explicitly link with compiler-rt
if( "${CLANGRT_BUILTINS_FETCH_EXIT_CODE}" STREQUAL "0" )
# The HIP_CXX_COMPILER by default prefers backward slashes for path seperators on windows.
# Prefer forward slashes here to avoid escaping issues on certain build systems.
if(WIN32)
string(REPLACE "\\" "/" CLANGRT_BUILTINS ${CLANGRT_BUILTINS})
endif()
# CLANG_RT Builtins found Successfully Set interface link libraries property
set_property(TARGET hip::host APPEND PROPERTY INTERFACE_LINK_LIBRARIES "${CLANGRT_BUILTINS}")
set_property(TARGET hip::device APPEND PROPERTY INTERFACE_LINK_LIBRARIES "${CLANGRT_BUILTINS}")