summaryrefslogtreecommitdiff
path: root/bsp
diff options
context:
space:
mode:
authorBunnaroath Sou <bsou@sifive.com>2019-03-05 18:31:05 -0800
committerBunnaroath Sou <bsou@sifive.com>2019-03-05 18:31:05 -0800
commit6da8dd4d586812659ed22fa56f966f28d5958f49 (patch)
tree39a2893ee5dd9291b284b712150a6a0ab5ea4e2b /bsp
parent04654e6c468e853ddef3423221bbda1c8e999dd6 (diff)
Make update script independent of bash
Diffstat (limited to 'bsp')
-rwxr-xr-xbsp/update-targets.sh10
1 files changed, 5 insertions, 5 deletions
diff --git a/bsp/update-targets.sh b/bsp/update-targets.sh
index 8f094e5..13cd32b 100755
--- a/bsp/update-targets.sh
+++ b/bsp/update-targets.sh
@@ -13,7 +13,7 @@ EOF
unset DTSFILE
unset CUSTOM_PATH
unset CUSTOM_NAME
-while [[ "$1" != "" ]]
+while [ "$1" != "" ]
do
case "$1" in
--help) help "$0"; exit 0;;
@@ -26,25 +26,25 @@ do
esac
done
-if [[ "$CUSTOM_PATH" == "" && "$CUSTOM_NAME" == "" && "$DTSFILE" == "" ]]
+if [ "$CUSTOM_PATH" == "" -a "$CUSTOM_NAME" == "" -a "$DTSFILE" == "" ]
then
TARGET_LIST="$(ls -d coreip*) "
TARGET_LIST+="sifive-hifive1 freedom-e310-arty "
else
- if [[ ! -f "$DTSFILE" && "$DTSFILE" != "*.dts" ]]
+ if [ ! -f "$DTSFILE" -a "$DTSFILE" != "*.dts" ]
then
echo "[ERROR] $0: $DTSFILE must be a dts file" >&2
help "$0"
exit 1
fi
- if [[ "$CUSTOM_NAME" == "" ]]
+ if [ "$CUSTOM_NAME" == "" ]
then
echo "[ERROR] $0: --target-name is mandatory" >&2
help "$0"
exit 1
fi
CUSTOM_TARGET="$CUSTOM_PATH/bsp/$CUSTOM_NAME"
- if [[ ! -d "$CUSTOM_TARGET" ]]
+ if [ ! -d "$CUSTOM_TARGET" ]
then
echo "[ERROR] $0: "$CUSTOM_TARGET" not found!" >&2
help "$0"