1
0
Fork 0
mirror of synced 2024-11-22 00:55:34 -05:00
openvpn-user/build_arm.sh
Ilya Sosnovsky 87f93db6a4 fixes
2021-10-21 12:36:04 +03:00

10 lines
410 B
Bash
Executable file

#!/usr/bin/env bash
if [[ "$GOOS" == "linux" ]]; then
if [[ "$GOARCH" == "arm" ]]; then
CC=arm-linux-gnueabi-gcc CGO_ENABLED=1 GOOS=linux GOARCH=arm go build -ldflags "-linkmode external -extldflags -static -s -w" $@
fi
if [[ "$GOARCH" == "arm64" ]]; then
CC=aarch64-linux-gnu-gcc CGO_ENABLED=1 GOOS=linux GOARCH=arm64 go build -ldflags "-linkmode external -extldflags -static -s -w" $@
fi
fi