From 607e6b787a4aaab37b2d5e7cd3550f71e90109aa Mon Sep 17 00:00:00 2001 From: leondaz Date: Sun, 3 Mar 2024 20:18:04 +0200 Subject: [PATCH] add build script for different platforms --- .gitignore | 2 +- build.sh | 12 ++++++++++++ 2 files changed, 13 insertions(+), 1 deletion(-) create mode 100755 build.sh diff --git a/.gitignore b/.gitignore index 747ac77..a9b1eee 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,3 @@ -qurandw +bin .DS_Store .idea \ No newline at end of file diff --git a/build.sh b/build.sh new file mode 100755 index 0000000..c168f05 --- /dev/null +++ b/build.sh @@ -0,0 +1,12 @@ + +# for mac +GOOS=darwin GOARCH=amd64 go build -o bin/qurandw-darwin-amd64 +GOOS=darwin GOARCH=arm64 go build -o bin/qurandw-darwin-arm64 + +# for linux +GOOS=linux GOARCH=amd64 go build -o bin/qurandw-linux-amd64 +GOOS=linux GOARCH=386 go build -o bin/qurandw-linux-x86 + +# for windows +GOOS=windows GOARCH=amd64 go build -o bin/qurandw-win32-amd64.exe +GOOS=windows GOARCH=386 go build -o bin/qurandw-win32-x86.exe