diff --git a/wireguard/build-wireguard-go.sh b/wireguard/build-wireguard-go.sh index ab4ab03dd0..bb38634a12 100755 --- a/wireguard/build-wireguard-go.sh +++ b/wireguard/build-wireguard-go.sh @@ -2,7 +2,7 @@ # This script is used to build wireguard-go libraries for all the platforms. -stringContain() { +function stringContain() { case $2 in "$1" ) return 0;; @@ -17,7 +17,7 @@ stringContain() { which getopt echo "$(uname -s)" -if stringContain "$(uname -s)", "Darwin"; then +if stringContain "$(uname -s)" "Darwin"; then echo "using gnu-getopt - $(which gnu-getopt)" export PATH="/usr/local/opt/gnu-getopt/bin:$PATH" fi