nim-gdb: remove unnecessary quotes and fix uname (#20739)

This commit is contained in:
Xiao-Yong 2022-11-02 23:51:21 -05:00 • committed by GitHub
commit 6b1e353aa1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -7,7 +7,7 @@ which nim > /dev/null || (echo "nim not in PATH"; exit 1)
which gdb > /dev/null || (echo "gdb not in PATH"; exit 1) which gdb > /dev/null || (echo "gdb not in PATH"; exit 1)
which readlink > /dev/null || (echo "readlink not in PATH."; exit 1) which readlink > /dev/null || (echo "readlink not in PATH."; exit 1)
if [[ "$(uname -s)" == "Darwin" || "(uname -s)" == *"BSD" ]]; then if [[ $(uname -s) == Darwin || $(uname -s) == *BSD ]]; then
NIM_SYSROOT=$(dirname $(dirname $(readlink -f $(which nim)))) NIM_SYSROOT=$(dirname $(dirname $(readlink -f $(which nim))))
else else
NIM_SYSROOT=$(dirname $(dirname $(readlink -e $(which nim)))) NIM_SYSROOT=$(dirname $(dirname $(readlink -e $(which nim))))