Skip to content

Commit ccc0c27

Browse files
authored
[SYCL] Add opencl-aot to sycl-toolchain target (#1504)
If opencl-aot project is enabled, we build and deploy it as part of sycl-toolchain. Signed-off-by: Alexey Bader <[email protected]>
1 parent afa80bf commit ccc0c27

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

sycl/CMakeLists.txt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -221,6 +221,13 @@ add_custom_target( sycl-toolchain
221221
COMMENT "Building SYCL compiler toolchain..."
222222
)
223223

224+
# Check if opencl-aot tool is enabled.
225+
list(FIND LLVM_ENABLE_PROJECTS opencl-aot OPENCL_AOT_FOUND)
226+
if(NOT OPENCL_AOT_FOUND EQUAL -1)
227+
add_dependencies(sycl-toolchain opencl-aot)
228+
list(APPEND SYCL_TOOLCHAIN_DEPLOY_COMPONENTS opencl-aot)
229+
endif()
230+
224231
if (SYCL_ENABLE_XPTI_TRACING)
225232
add_dependencies( sycl-toolchain xpti)
226233
if (MSVC)

0 commit comments

Comments
 (0)