diff --git a/build.sh b/build.sh index 1f7a6af..1097da7 100755 --- a/build.sh +++ b/build.sh @@ -1,6 +1,6 @@ #!/bin/bash -TARGET=mqttListener +APP=mqttListener # expand PATH for go tools export PATH=$PATH:~/go/bin @@ -35,13 +35,13 @@ usage() { build_linux_amd64() { echo -e "\nBuilding for Linux amd64:" - env GOOS=linux GOARCH=amd64 go build ${GO_BUILD_OPTIONS} -ldflags "$(govvv -flags)" -o ${TARGET}-linux-amd64 + env GOOS=linux GOARCH=amd64 go build ${GO_BUILD_OPTIONS} -ldflags "$(govvv -flags)" -o ${APP}-linux-amd64 echo -e "\t\t${GREEN}... done${NC}" } build_linux_arm() { echo -e "\nBuilding for arm:" - env GOOS=linux GOARCH=arm go build ${GO_BUILD_OPTIONS} -ldflags "$(govvv -flags)" -o ${TARGET}-linux-arm + env GOOS=linux GOARCH=arm go build ${GO_BUILD_OPTIONS} -ldflags "$(govvv -flags)" -o ${APP}-linux-arm echo -e "\t\t${GREEN}... done${NC}" echo -e "\nstipping arm binary:"