From 7094c2d28dcd7f7b02673f3daf7fc69e367181aa Mon Sep 17 00:00:00 2001 From: Maneesh Gupta Date: Wed, 13 Feb 2019 09:57:21 +0530 Subject: [PATCH] Initialize HIP_LIB_PATH on hcc path Change-Id: I8f392fffcd6a3714c20cb17e876dbaad999c33a0 [ROCm/hip commit: c8579ead673ad77527a2d2420eb6a7d92334c52d] --- projects/hip/bin/hipcc | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/projects/hip/bin/hipcc b/projects/hip/bin/hipcc index ac4cde2611..b649bb6e7f 100755 --- a/projects/hip/bin/hipcc +++ b/projects/hip/bin/hipcc @@ -204,6 +204,9 @@ if ($HIP_PLATFORM eq "clang") { } } elsif ($HIP_PLATFORM eq "hcc") { $HIP_INCLUDE_PATH = "$HIP_PATH/include"; + if (! defined $HIP_LIB_PATH) { + $HIP_LIB_PATH = "$HIP_PATH/lib"; + } $HSA_PATH=$ENV{'HSA_PATH'} // "/opt/rocm/hsa"; $HCC_HOME=$ENV{'HCC_HOME'} // $hipConfig{'HCC_HOME'} // "/opt/rocm/hcc"; @@ -778,7 +781,7 @@ if ($needHipHcc) { if ($linkType eq 0) { substr($HIPLDFLAGS,0,0) = " $HIP_LIB_PATH/libhip_hcc_static.a " ; } else { - substr($HIPLDFLAGS,0,0) = " -Wl,--rpath=$HIP_LIB_PATH $HIP_PATH/lib/libhip_hcc.so "; + substr($HIPLDFLAGS,0,0) = " -Wl,--rpath=$HIP_LIB_PATH $HIP_LIB_PATH/libhip_hcc.so "; } }