From 3bd4e81a8b4434cfbd320b85666c02782d5e62e6 Mon Sep 17 00:00:00 2001 From: Donato Capitella Date: Sun, 1 Feb 2026 11:13:07 +0000 Subject: [PATCH] Fix: Switch to add_compile_definitions for SMI_DISABLED and remove redundant target_ call --- projects/rccl/CMakeLists.txt | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/projects/rccl/CMakeLists.txt b/projects/rccl/CMakeLists.txt index d7a26b301d..b46b27ec83 100644 --- a/projects/rccl/CMakeLists.txt +++ b/projects/rccl/CMakeLists.txt @@ -48,7 +48,7 @@ option(ENABLE_AMDSMI "Enable AMD/ROCm SMI support" if(NOT ENABLE_AMDSMI) message(STATUS "SMI Support: DISABLED via ENABLE_AMDSMI=OFF") - add_definitions("-DSMI_DISABLED") + add_compile_definitions(SMI_DISABLED) unset(USE_AMDSMI CACHE) else() message(STATUS "SMI Support: ENABLED") @@ -1201,9 +1201,6 @@ if (BUILD_BFD) target_compile_definitions(rccl PRIVATE HAVE_TWO_ARG_BFD_SECTION_SIZE) endif() endif() -if (NOT ENABLE_AMDSMI) - target_compile_definitions(rccl PRIVATE SMI_DISABLED) -endif() if (IFC_ENABLED) target_compile_definitions(rccl PRIVATE USE_INDIRECT_FUNCTION_CALL) endif()