summaryrefslogtreecommitdiff
path: root/dev-util/rocprofiler/files/rocprofiler-5.0.2-gentoo-location.patch
blob: 56cc79211ff0759b0ed110bf539e0296346ea195 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
Index: rocprofiler-rocm-5.0.2/bin/rpl_run.sh
===================================================================
--- rocprofiler-rocm-5.0.2.orig/bin/rpl_run.sh
+++ rocprofiler-rocm-5.0.2/bin/rpl_run.sh
@@ -25,16 +25,16 @@
 time_stamp=`date +%y%m%d_%H%M%S`
 BIN_DIR=$(dirname $(realpath ${BASH_SOURCE[0]}))
 PKG_DIR=$(dirname $BIN_DIR)
-ROOT_DIR=$(dirname $PKG_DIR)
-TT_DIR=$ROOT_DIR/roctracer
+ROOT_DIR=$PKG_DIR
+TT_DIR=$ROOT_DIR
 RUN_DIR=`pwd`
 TMP_DIR="/tmp"
 DATA_DIR="rpl_data_${time_stamp}_$$"
 
-RPL_PATH=$PKG_DIR/lib
-TLIB_PATH=$PKG_DIR/tool
-TTLIB_PATH=$TT_DIR/tool
-ROCM_LIB_PATH=$ROOT_DIR/lib
+RPL_PATH=$PKG_DIR/@LIB_DIR@
+TLIB_PATH=$PKG_DIR/@LIB_DIR@
+TTLIB_PATH=$TT_DIR/@LIB_DIR@
+ROCM_LIB_PATH=$ROOT_DIR/@LIB_DIR@
 
 if [ -z "$ROCP_PYTHON_VERSION" ] ; then
   ROCP_PYTHON_VERSION=python3
@@ -70,7 +70,7 @@ export ROCP_HSA_INTERCEPT=1
 # Disabling internal ROC Profiler proxy queue (simple version supported for testing purposes)
 unset ROCP_PROXY_QUEUE
 # ROC Profiler metrics definition
-export ROCP_METRICS=$PKG_DIR/lib/metrics.xml
+export ROCP_METRICS=$PKG_DIR/share/rocprofiler/metrics.xml
 # Disable AQL-profile read API
 export AQLPROFILE_READ_API=0
 # ROC Profiler package path
@@ -104,7 +104,7 @@ usage() {
   bin_name=`basename $0`
   echo "ROCm Profiling Library (RPL) run script, a part of ROCprofiler library package."
   echo "Full path: $BIN_DIR/$bin_name"
-  echo "Metrics definition: $PKG_DIR/lib/metrics.xml"
+  echo "Metrics definition: $PKG_DIR/share/rocprofiler/metrics.xml"
   echo ""
   echo "Usage:"
   echo "  $bin_name [-h] [--list-basic] [--list-derived] [-i <input .txt/.xml file>] [-o <output CSV file>] <app command line>"
@@ -374,11 +374,11 @@ while [ 1 ] ; do
     export ROCP_METRICS="$2"
   elif [ "$1" = "--list-basic" ] ; then
     export ROCP_INFO=b
-    HSA_TOOLS_LIB="$MY_HSA_TOOLS_LIB" eval "$PKG_DIR/tool/ctrl"
+    HSA_TOOLS_LIB="$MY_HSA_TOOLS_LIB" eval "$PKG_DIR/bin/ctrl"
     exit 1
   elif [ "$1" = "--list-derived" ] ; then
     export ROCP_INFO=d
-    HSA_TOOLS_LIB="$MY_HSA_TOOLS_LIB" eval "$PKG_DIR/tool/ctrl"
+    HSA_TOOLS_LIB="$MY_HSA_TOOLS_LIB" eval "$PKG_DIR/bin/ctrl"
     exit 1
   elif [ "$1" = "--basenames" ] ; then
     if [ "$2" = "on" ] ; then