File tree Expand file tree Collapse file tree 1 file changed +13
-0
lines changed
source/adapters/level_zero Expand file tree Collapse file tree 1 file changed +13
-0
lines changed Original file line number Diff line number Diff line change 6
6
7
7
set (TARGET_NAME ur_adapter_level_zero )
8
8
9
+ # Copy L0 loader/headers locally to the build to avoid leaking their path.
10
+ set (LEVEL_ZERO_COPY_DIR ${CMAKE_CURRENT_BINARY_DIR} /level_zero_loader )
11
+ if (DEFINED L0_LIBRARY )
12
+ get_filename_component (LEVEL_ZERO_LIB_NAME "${L0_LIBRARY} " NAME )
13
+ set (LEVEL_ZERO_LIBRARY ${LEVEL_ZERO_COPY_DIR} /${LEVEL_ZERO_LIB_NAME} )
14
+ message (STATUS "Copying Level Zero loader and headers to local build tree" )
15
+ file (COPY ${L0_LIBRARY} DESTINATION ${LEVEL_ZERO_COPY_DIR} FOLLOW_SYMLINK_CHAIN )
16
+ endif ()
17
+ if (DEFINED L0_INCLUDE_DIR )
18
+ set (LEVEL_ZERO_INCLUDE_DIR ${LEVEL_ZERO_COPY_DIR} /level_zero )
19
+ file (COPY ${L0_INCLUDE_DIR} /level_zero DESTINATION ${LEVEL_ZERO_COPY_DIR} )
20
+ endif ()
21
+
9
22
if (NOT DEFINED LEVEL_ZERO_LIBRARY OR NOT DEFINED LEVEL_ZERO_INCLUDE_DIR )
10
23
message (STATUS "Download Level Zero loader and headers from github.com" )
11
24
You can’t perform that action at this time.
0 commit comments