diff --git a/Makefile b/Makefile index 4a04dbe2a12..9872d582dd1 100644 --- a/Makefile +++ b/Makefile @@ -155,14 +155,13 @@ ifndef NOBANNER echo $$(date): Compiling proto definitions endif -# TODO(sougou): find a better way around this temp hack. -VTTOP=$(VTROOT)/../../.. $(PROTO_GO_OUTS): install_protoc-gen-go proto/*.proto for name in $(PROTO_SRC_NAMES); do \ - cd $(VTTOP)/src && \ - $(VTROOT)/bin/protoc --go_out=plugins=grpc:. -Ivitess.io/vitess/proto vitess.io/vitess/proto/$${name}.proto && \ - goimports -w $(VTROOT)/go/vt/proto/$${name}/$${name}.pb.go; \ + $(VTROOT)/bin/protoc --go_out=plugins=grpc:. -Iproto proto/$${name}.proto && \ + goimports -w vitess.io/vitess/go/vt/proto/$${name}/$${name}.pb.go; \ done + cp -Rf vitess.io/vitess/go/vt/proto/* go/vt/proto + rm -rf vitess.io/vitess/go/vt/proto/ # Helper targets for building Docker images. # Please read docker/README.md to understand the different available images.