summaryrefslogtreecommitdiffstats
path: root/llvm/utils/release
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/utils/release')
-rwxr-xr-xllvm/utils/release/test-release.sh10
1 files changed, 6 insertions, 4 deletions
diff --git a/llvm/utils/release/test-release.sh b/llvm/utils/release/test-release.sh
index 82264bc0999..2b4c51ce23d 100755
--- a/llvm/utils/release/test-release.sh
+++ b/llvm/utils/release/test-release.sh
@@ -359,10 +359,12 @@ function clean_RPATH() {
local InstallPath="$1"
for Candidate in `find $InstallPath/{bin,lib} -type f`; do
if file $Candidate | grep ELF | egrep 'executable|shared object' > /dev/null 2>&1 ; then
- rpath=`objdump -x $Candidate | grep 'RPATH' | sed -e's/^ *RPATH *//'`
- if [ -n "$rpath" ]; then
- newrpath=`echo $rpath | sed -e's/.*\(\$ORIGIN[^:]*\).*/\1/'`
- chrpath -r $newrpath $Candidate 2>&1 > /dev/null 2>&1
+ if rpath=`objdump -x $Candidate | grep 'RPATH'` ; then
+ rpath=`echo $rpath | sed -e's/^ *RPATH *//'`
+ if [ -n "$rpath" ]; then
+ newrpath=`echo $rpath | sed -e's/.*\(\$ORIGIN[^:]*\).*/\1/'`
+ chrpath -r $newrpath $Candidate 2>&1 > /dev/null 2>&1
+ fi
fi
fi
done
OpenPOWER on IntegriCloud