Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: support win/arm64 target #782

Merged
merged 1 commit into from
Apr 19, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ LINUX_ARM64_BINARY=bin/linux-arm64/$(BINARY_NAME)
DARWIN_AMD64_BINARY=bin/darwin-amd64/$(BINARY_NAME)
DARWIN_ARM64_BINARY=bin/darwin-arm64/$(BINARY_NAME)
WINDOWS_AMD64_BINARY=bin/windows-amd64/$(BINARY_NAME).exe
WINDOWS_ARM64_BINARY=bin/windows-arm64/$(BINARY_NAME).exe

.PHONY: docker
docker: Dockerfile GITCOMMIT_SHA
Expand All @@ -49,7 +50,7 @@ test:
cd $(SOURCEDIR) && go test -v -timeout 30s -short -cover ./...

.PHONY: all-variants
all-variants: linux-amd64 linux-arm64 darwin-amd64 darwin-arm64 windows-amd64
all-variants: linux-amd64 linux-arm64 darwin-amd64 darwin-arm64 windows-amd64 windows-arm64

.PHONY: linux-amd64
linux-amd64: $(LINUX_AMD64_BINARY)
Expand Down Expand Up @@ -77,6 +78,12 @@ $(WINDOWS_AMD64_BINARY): $(SOURCES) GITCOMMIT_SHA
./scripts/build_variant.sh windows amd64 $(VERSION) $(shell cat GITCOMMIT_SHA)
@mv ./bin/windows-amd64/$(BINARY_NAME) ./$(WINDOWS_AMD64_BINARY)

.PHONY: windows-arm64
windows-arm64: $(WINDOWS_ARM64_BINARY)
$(WINDOWS_ARM64_BINARY): $(SOURCES) GITCOMMIT_SHA
./scripts/build_variant.sh windows arm64 $(VERSION) $(shell cat GITCOMMIT_SHA)
@mv ./bin/windows-arm64/$(BINARY_NAME) ./$(WINDOWS_ARM64_BINARY)

GITCOMMIT_SHA: $(GITFILES)
git rev-parse --short=7 HEAD > GITCOMMIT_SHA

Expand Down
Loading