From b94298e94d23b62bb77280e985aff54527a4f7a3 Mon Sep 17 00:00:00 2001 From: Sriraksha Nagaraj Date: Tue, 7 Mar 2023 14:37:08 +0000 Subject: [PATCH] SWDEV-379542: Adding to LD_PRELOAD instead of overriding it Change-Id: Ib6395454ab6d09124baf2f958f26384f8689f64e [ROCm/rocprofiler commit: f29b968185288f57c4697200b27e03725eb2c4f4] --- projects/rocprofiler/bin/rpl_run.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/projects/rocprofiler/bin/rpl_run.sh b/projects/rocprofiler/bin/rpl_run.sh index 49cf0702e9..f0290e0ac1 100755 --- a/projects/rocprofiler/bin/rpl_run.sh +++ b/projects/rocprofiler/bin/rpl_run.sh @@ -294,14 +294,14 @@ run() { log_file="$ROCP_OUTPUT_DIR/log.txt" exit_file="$ROCP_OUTPUT_DIR/exit.txt" { - HSA_TOOLS_LIB="$MY_HSA_TOOLS_LIB" LD_PRELOAD="$MY_LD_PRELOAD" eval "$APP_CMD" + HSA_TOOLS_LIB="$MY_HSA_TOOLS_LIB" LD_PRELOAD=$LD_PRELOAD:"$MY_LD_PRELOAD" eval "$APP_CMD" retval=$? echo "exit($retval)" > $exit_file } 2>&1 | tee "$log_file" exitval=`cat "$exit_file" | sed -n "s/^.*exit(\([0-9]*\)).*$/\1/p"` if [ -n "$exitval" ] ; then retval=$exitval; fi else - HSA_TOOLS_LIB="$MY_HSA_TOOLS_LIB" LD_PRELOAD="$MY_LD_PRELOAD" eval "$APP_CMD" + HSA_TOOLS_LIB="$MY_HSA_TOOLS_LIB" LD_PRELOAD=$LD_PRELOAD:"$MY_LD_PRELOAD" eval "$APP_CMD" retval=$? fi return $retval