Skip to content

Commit

Permalink
build-tc.sh: Correctly decide executable bins
Browse files Browse the repository at this point in the history
  • Loading branch information
wloot committed Jan 17, 2020
1 parent 8721188 commit c9e3c7f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions build-tc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ msg "Setting library load paths for portability and"
msg "Stripping remaining products..."
IFS=$'\n'
for f in $(find installTmp -type f -exec file {} \;); do
if [ -n "$(echo $f | grep 'ELF .* executable')" ]; then
if [ -n "$(echo $f | grep 'ELF .* interpreter')" ]; then
i=$(echo $f | awk '{print $1}'); i=${i: : -1}
# Set executable rpaths so setting LD_LIBRARY_PATH isn't necessary
if [ -d $(dirname $i)/../lib/ldscripts ]; then
Expand All @@ -46,7 +46,7 @@ for f in $(find installTmp -type f -exec file {} \;); do
if [ -n "$(echo $f | grep 'not stripped')" ]; then
strip --strip-unneeded "$i"
fi
elif [ -n "$(echo $f | grep 'ELF .* shared object')" ]; then
else
if [ -n "$(echo $f | grep 'not stripped')" ]; then
i=$(echo $f | awk '{print $1}');
strip --strip-all "${i: : -1}"
Expand Down

0 comments on commit c9e3c7f

Please sign in to comment.