Skip to content

Commit d73e898

Browse files
rafbielsRbiessy
authored andcommitted
Set blas cmake options also with PARENT_SCOPE
This is required for the update value to be visible in a dependent project including generic blas using FetchContent.
1 parent feeea2b commit d73e898

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

onemath/sycl/blas/CMakeLists.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,10 +70,16 @@ if (SYCL_COMPILER MATCHES "adaptivecpp" OR ${CMAKE_CXX_COMPILER} MATCHES "acpp|s
7070
if(BLAS_ENABLE_COMPLEX)
7171
message(STATUS "SYCL Complex data is not supported on AdaptiveCpp/hipSYCL. Complex data type is disabled")
7272
set(BLAS_ENABLE_COMPLEX OFF)
73+
if (NOT ${CMAKE_CURRENT_SOURCE_DIR} STREQUAL ${CMAKE_SOURCE_DIR})
74+
set(BLAS_ENABLE_COMPLEX OFF PARENT_SCOPE)
75+
endif()
7376
endif()
7477
if (BLAS_ENABLE_USM)
7578
message(STATUS "USM API is not supported on AdaptiveCpp/hipSYCL. USM API is disabled")
7679
set(BLAS_ENABLE_USM OFF)
80+
if (NOT ${CMAKE_CURRENT_SOURCE_DIR} STREQUAL ${CMAKE_SOURCE_DIR})
81+
set(BLAS_ENABLE_USM OFF PARENT_SCOPE)
82+
endif()
7783
endif()
7884
endif()
7985

0 commit comments

Comments
 (0)