diff options
author | Ethan Sommer <e5ten.arch@gmail.com> | 2020-04-15 15:36:23 -0400 |
---|---|---|
committer | Cem Keylan <cem@ckyln.com> | 2021-07-04 16:06:08 +0300 |
commit | 5bc00f0da395aa4ec779bb802bd78bf893565143 (patch) | |
tree | 5ddf229e4bcb3cb50a0bd70f8d113f2364f0ce54 /scripts | |
parent | ec83a5a57065fdde20eb8cdb5074b7b52e8256fb (diff) | |
download | toybox-5bc00f0da395aa4ec779bb802bd78bf893565143.tar.gz |
single.sh: remove bashisms, change shebang to sh
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/single.sh | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/scripts/single.sh b/scripts/single.sh index c40c6bcf..473bbdd4 100755 --- a/scripts/single.sh +++ b/scripts/single.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/bin/sh # Build a standalone toybox command @@ -9,7 +9,7 @@ then fi # Add trailing / to PREFIX when it's set but hasn't got one -[ "$PREFIX" == "${PREFIX%/}" ] && PREFIX="${PREFIX:+$PREFIX/}" +[ "$PREFIX" = "${PREFIX%/}" ] && PREFIX="${PREFIX:+$PREFIX/}" # Harvest TOYBOX_* symbols from .config if [ ! -e .config ] @@ -24,7 +24,7 @@ touch -c .config export KCONFIG_CONFIG=.singleconfig for i in "$@" do - echo -n "$i:" + printf '%s:' "$i" TOYFILE="$(egrep -l "TOY[(]($i)[ ,]" toys/*/*.c)" if [ -z "$TOYFILE" ] @@ -37,7 +37,7 @@ do DEPENDS= MPDEL= - if [ "$i" == sh ] + if [ "$i" = sh ] then DEPENDS="$(sed -n 's/USE_\([^(]*\)(NEWTOY([^,]*,.*TOYFLAG_MAYFORK.*/\1/p' toys/*/*.c)" else |