From 0da1c6b8c3f06e5074b2ce1412142105741a552f Mon Sep 17 00:00:00 2001 From: Sean Pryor Date: Mon, 4 May 2026 12:05:59 -0400 Subject: [PATCH] Fix rpath issue in CMake config This patch fixes the nvshmem RPATH, which defaults to "/usr/lib64/nvshmem/12/cmake/nvshmem/../..". This causes a problem because the cmake/nvshmem path is only present when the devel package is installed, and attempting to load nvshmem without that path present will cause the linking program to crash. Signed-off-by: Sean Pryor --- cmake_config/NVSHMEMConfig.cmake.in | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cmake_config/NVSHMEMConfig.cmake.in b/cmake_config/NVSHMEMConfig.cmake.in index 7a0c1f26..b4fab34a 100644 --- a/cmake_config/NVSHMEMConfig.cmake.in +++ b/cmake_config/NVSHMEMConfig.cmake.in @@ -47,9 +47,10 @@ set(BIN_DIRS ${NVSHMEM_RHEL_BACKUP_INCL_BIN_BASE}/${NVSHMEM_BIN_FINAL} ) +get_filename_component(NVSHMEM_LIB_DIRS "${CMAKE_CURRENT_LIST_DIR}/../.." ABSOLUTE) set(LIB_DIRS ${PACKAGE_PREFIX_DIR}/lib -${CMAKE_CURRENT_LIST_DIR}/../.. +${NVSHMEM_LIB_DIRS} )