Skip to content

Commit bdefe35

Browse files
dannfsravnborg
authored andcommitted
Remove bashisms from scripts
The '-e' option to echo and brace expansion are not guaranteed to be supported by a POSIX-compliant /bin/sh (e.g. dash) Signed-off-by: dann frazier <dannf@debian.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
1 parent a9eb522 commit bdefe35

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

‎scripts/gcc-version.sh‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ compiler="$*"
1818

1919
if [ ${#compiler} -eq 0 ]; then
2020
echo "Error: No compiler specified."
21-
echo -e "Usage:\n\t$0 <gcc-command>"
21+
printf "Usage:\n\t$0 <gcc-command>\n"
2222
exit 1
2323
fi
2424

‎scripts/ver_linux‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ sed -n -e '/^.*\/libc-\([^/]*\)\.so$/{s//\1/;p;q}' < /proc/self/maps
6565
ldd -v > /dev/null 2>&1 && ldd -v || ldd --version |head -n 1 | awk \
6666
'NR==1{print "Dynamic linker (ldd) ", $NF}'
6767

68-
ls -l /usr/lib/lib{g,stdc}++.so 2>/dev/null | awk -F. \
68+
ls -l /usr/lib/libg++.so /usr/lib/libstdc++.so 2>/dev/null | awk -F. \
6969
'{print "Linux C++ Library " $4"."$5"."$6}'
7070

7171
ps --version 2>&1 | grep version | awk \

0 commit comments

Comments
 (0)