From 15cbb2e47f0b9ec758d89227f20ef3b4b23aa723 Mon Sep 17 00:00:00 2001 From: Lauren Wrubleski Date: Tue, 11 Jul 2023 11:40:23 -0600 Subject: [PATCH] Add rocm-core-asan dependency for ASAN builds (#136) --- share/rocm/cmake/ROCMCreatePackage.cmake | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/share/rocm/cmake/ROCMCreatePackage.cmake b/share/rocm/cmake/ROCMCreatePackage.cmake index 2afa816e..19b8b140 100755 --- a/share/rocm/cmake/ROCMCreatePackage.cmake +++ b/share/rocm/cmake/ROCMCreatePackage.cmake @@ -131,8 +131,15 @@ macro(rocm_package_add_rocm_core_dependency) # This mainly empty package exists to allow all of rocm # to be removed in one step by removing rocm-core if(ROCM_DEP_ROCMCORE) - rocm_join_if_set(", " CPACK_DEBIAN_PACKAGE_DEPENDS "rocm-core") - rocm_join_if_set(", " CPACK_RPM_PACKAGE_REQUIRES "rocm-core") + if(ENABLE_ASAN_PACKAGING) + # For ASAN packages, add dependency to rocm-core-asan + set(_rocm_core_pkg "rocm-core-asan") + else() + set(_rocm_core_pkg "rocm-core") + endif() + rocm_join_if_set(", " CPACK_DEBIAN_PACKAGE_DEPENDS ${_rocm_core_pkg}) + rocm_join_if_set(", " CPACK_RPM_PACKAGE_REQUIRES ${_rocm_core_pkg}) + unset(_rocm_core_pkg) endif() endmacro()