Skip to content

Commit

Permalink
update Makefiles to include windows amd/ar64 architectures
Browse files Browse the repository at this point in the history
  • Loading branch information
vkuznet committed Aug 30, 2024
1 parent bbaa117 commit ccd89af
Showing 1 changed file with 13 additions and 2 deletions.
15 changes: 13 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ ifdef TAG
sed -i -e "s,$(TAG),{{VERSION}},g" main.go
endif

build_all: golib build_darwin_amd64 build_darwin_arm64 build_amd64 build_arm64 build_power8 build_windows
build_all: golib build_darwin_amd64 build_darwin_arm64 build_amd64 build_arm64 build_power8 build_windows_amd64 build_windows_arm64

build_darwin_amd64:
ifdef TAG
Expand Down Expand Up @@ -73,14 +73,25 @@ ifdef TAG
endif
mv srv srv_arm64

build_windows:
build_windows_amd64:
ifdef TAG
sed -i -e "s,{{VERSION}},$(TAG),g" main.go
endif
go clean; rm -rf pkg srv.exe; GOARCH=amd64 GOOS=windows go build -o srv.exe ${flags}
ifdef TAG
sed -i -e "s,$(TAG),{{VERSION}},g" main.go
endif
mv srv.exe srv_amd64.exe

build_windows_arm64:
ifdef TAG
sed -i -e "s,{{VERSION}},$(TAG),g" main.go
endif
go clean; rm -rf pkg srv.exe; GOARCH=arm64 GOOS=windows go build -o srv.exe ${flags}
ifdef TAG
sed -i -e "s,$(TAG),{{VERSION}},g" main.go
endif
mv srv.exe srv_arm64.exe

install:
go install
Expand Down

0 comments on commit ccd89af

Please sign in to comment.