Skip to content
This repository has been archived by the owner on Apr 3, 2024. It is now read-only.

Commit

Permalink
init Makefile
Browse files Browse the repository at this point in the history
  • Loading branch information
sky96111 committed Dec 4, 2022
1 parent f726c93 commit 66d860b
Showing 1 changed file with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
BINARY=zwu

build:
go build -o ${BINARY}

install:
go install

release:
go clean
# build for linux_amd64
GOOS=linux GOARCH=amd64 go build -o ${BINARY}_linux_amd64
# build for linux_x86
GOOS=linux GOARCH=386 go build -o ${BINARY}_linux_x86
# build for linux_arm64
GOOS=linux GOARCH=arm64 go build -o ${BINARY}_linux_arm64
# build for windows_amd64
GOOS=windows GOARCH=amd64 go build -o ${BINARY}_windows_amd64.exe
# build for windows_x86
GOOS=windows GOARCH=386 go build -o ${BINARY}_windows_x86.exe
# build for windows_arm64
GOOS=windows GOARCH=arm64 go build -o ${BINARY}_windows_arm64.exe
# build for darwin_amd64
GOOS=darwin GOARCH=amd64 go build -o ${BINARY}_darwin_amd64
# build for darwin_arm64
GOOS=darwin GOARCH=arm64 go build -o ${BINARY}_darwin_arm64

clean:
go clean

.PHONY: clean build

0 comments on commit 66d860b

Please sign in to comment.