I added a new .proto file in the directory: moby/vendor/github.com/docker/swarmkit/api/ of
the locally cloned moby/moby repository in my PC. I successfully generated the corresponding .pb.go file for this .proto file using the command
protoc --go_out=. file.proto .
make binary command fails with the following error. (pasting the last few lines of the output of the make binary command below)
Removing bundles/ ---> Making bundle: binary (in bundles/binary) Building: bundles/binary-daemon/dockerd-dev GOOS="" GOARCH="" GOARM="" vendor/github.com/docker/swarmkit/agent/exec/controller.go:8:2: found packages api (ca.pb.go) and docker_swarmkit_v1 (firstfile.pb.go) in /go/src/github.com/docker/docker/vendor/github.com/docker/swarmkit/api Makefile:137: recipe for target 'binary' failed make: *** [binary] Error 1
It appears that the new files are not being recognized by the build process. How should I go about fixing this? Is there a specific Makefile where they need to be mentioned or any other dependency that needs to be taken care of? Please also let me know if it is even feasible to add new .proto files and generate binaries from moby/moby.
Update: The README file under the same directory (moby/vendor/github.com/docker/swarmkit/api/) mentions using make generate command to regenerate .pb.go files after modifications in .proto files. But, make generate command does not work either and returns the error:
make: *** No rule to make target 'generate'. Stop.