diff --git a/lib/functions.sh b/lib/functions.sh index c9799d75cd..6363ab0d5d 100644 --- a/lib/functions.sh +++ b/lib/functions.sh @@ -647,14 +647,14 @@ make_isaexec_stub_arch() { for file in $1/*; do [[ -f $file ]] || continue # Deals with empty dirs & non-files # Check to make sure we don't have a script - read -n 5 < $file + read -n 4 REPLY < $file file=`echo $file | sed -e "s/$1\///;"` # Skip if we already made a stub for this file [[ -f $file ]] && continue # Only copy non-binaries if we set NOSCRIPTSTUB if [[ $REPLY != $'\177'ELF && -n "$NOSCRIPTSTUB" ]]; then - logmsg "------ Non-binary file: $file - copying instead" - cp $1/$file . + logmsg "------ Non-binary file: $file - moving instead" + mv $1/$file . chmod +x $file continue fi