Merge pull request #129 from morph027/multiarch-easyjson

adjust easyjson for multiarch builds
This commit is contained in:
Joachim Bauch 2021-07-05 08:30:41 +02:00 committed by GitHub
commit ed8c2752cb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -37,6 +37,12 @@ ifneq ($(COUNT),)
TESTARGS := $(TESTARGS) -count $(COUNT)
endif
ifeq ($(GOARCH), amd64)
VENDORBIN := $(CURDIR)/vendor/bin
else
VENDORBIN := $(CURDIR)/vendor/bin/$(GOOS)_$(GOARCH)
endif
hook:
[ ! -d "$(CURDIR)/.git/hooks" ] || ln -sf "$(CURDIR)/scripts/pre-commit.hook" "$(CURDIR)/.git/hooks/pre-commit"
@ -79,7 +85,7 @@ coverhtml: vet common
GOPATH=$(GOPATH) $(GO) tool cover -html=cover.out -o coverage.html
%_easyjson.go: %.go ./vendor/bin/easyjson
PATH=$(shell dirname $(GO)):$(PATH) GOPATH=$(GOPATH) ./vendor/bin/easyjson -all $*.go
PATH=$(shell dirname $(GO)):$(PATH) GOPATH=$(GOPATH) "$(VENDORBIN)/easyjson" -all $*.go
common: \
api_signaling_easyjson.go \