Skip to content

Commit

Permalink
add package build
Browse files Browse the repository at this point in the history
  • Loading branch information
milin2436 committed Jul 20, 2021
1 parent 6f9d6f2 commit c354e3f
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions main/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,14 @@ $(out) : $(objs)
.PHONY : static
clean :
rm -rf $(out)
rm -rf $(out).exe
install :
upx $(out)
win :
GOOS=windows GOARCH=386 go build -ldflags "-s -w -X 'github.com/milin2436/oneshow/cmd.VERSION=v0.1.1 build time:$(buildTime)' -X 'github.com/milin2436/oneshow/cmd.CmdName=oneshow' " -o $(out).exe
static :
CGO_ENABLED=0 go build -ldflags "-s -w" -o $(out)
.PHONY : pkg
pkg : $(out) win
zip -r -0 $(out)-amd64.zip $(out)
zip -r -0 $(out)-386.zip $(out).exe

0 comments on commit c354e3f

Please sign in to comment.