Merge pull request #5702 from orbea/zsh

qb: Fix --enable-* options for zsh.
This commit is contained in:
Twinaphex 2017-11-18 10:53:17 +01:00 committed by GitHub
commit 29b5e09b24
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -50,9 +50,11 @@ EOF
}
opt_exists() # $opt is returned if exists in OPTS
{ opt=$(echo "$1" | tr '[:lower:]' '[:upper:]')
for OPT in $OPTS; do [ "$opt" = "$OPT" ] && return; done
echo "Unknown option $2"; exit 1
{ opt="$(echo "$1" | tr '[:lower:]' '[:upper:]')"
err="$2"
eval "set -- $OPTS"
for OPT do [ "$opt" = "$OPT" ] && return; done
echo "Unknown option $err"; exit 1
}
parse_input() # Parse stuff :V