diff --git a/runtime/hsa-runtime/hsa-runtime64-config.cmake.in b/runtime/hsa-runtime/hsa-runtime64-config.cmake.in index 629216ce55..3b57b0995f 100644 --- a/runtime/hsa-runtime/hsa-runtime64-config.cmake.in +++ b/runtime/hsa-runtime/hsa-runtime64-config.cmake.in @@ -45,7 +45,8 @@ include( CMakeFindDependencyMacro ) # Client apps only need our private dependencies if rocr is a static lib. -if( NOT @BUILD_SHARED_LIBS@ ) +set( _is_hsa_runtime_dynamic @BUILD_SHARED_LIBS@ ) +if( NOT _is_hsa_runtime_dynamic ) set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_CURRENT_LIST_DIR}")