Skip to content

Commit defe007

Browse files
Alexander Batashevvladimirlaz
authored andcommitted
[SYCL] Fix CMake external project args
ExternalProject_Add's CMAKE_ARGS requires a list of arguments, while current behavior is to pass a string of arguments, which results in build errors for some configurations. This patch changes type of AUX_CMAKE_FLAGS from string to list. Signed-off-by: Alexander Batashev <[email protected]>
1 parent 8f354f7 commit defe007

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

sycl/CMakeLists.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -91,16 +91,16 @@ if( NOT OpenCL_LIBRARIES )
9191
if(MSVC)
9292
set(OpenCL_LIBRARIES
9393
"${LLVM_LIBRARY_OUTPUT_INTDIR}/${CMAKE_STATIC_LIBRARY_PREFIX}OpenCL${CMAKE_STATIC_LIBRARY_SUFFIX}")
94-
set(AUX_CMAKE_FLAGS "${AUX_CMAKE_FLAGS} -DOPENCL_ICD_LOADER_REQUIRE_WDK=OFF")
94+
list(APPEND AUX_CMAKE_FLAGS -DOPENCL_ICD_LOADER_REQUIRE_WDK=OFF)
9595
else()
9696
set(OpenCL_LIBRARIES
9797
"${LLVM_LIBRARY_OUTPUT_INTDIR}/${CMAKE_SHARED_LIBRARY_PREFIX}OpenCL${CMAKE_SHARED_LIBRARY_SUFFIX}")
9898
endif()
9999
if (CMAKE_C_COMPILER)
100-
set(AUX_CMAKE_FLAGS "${AUX_CMAKE_FLAGS} -DCMAKE_C_COMPILER=${CMAKE_C_COMPILER}")
100+
list(APPEND AUX_CMAKE_FLAGS -DCMAKE_C_COMPILER=${CMAKE_C_COMPILER})
101101
endif()
102102
if (CMAKE_CXX_COMPILER)
103-
set(AUX_CMAKE_FLAGS "${AUX_CMAKE_FLAGS} -DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER}")
103+
list(APPEND AUX_CMAKE_FLAGS -DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER})
104104
endif()
105105
file(MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/icd_build)
106106
ExternalProject_Add(ocl-icd

0 commit comments

Comments
 (0)