Use prebuilt nanopb_generator.py.
Use prebuilt nanopb_generator.py to avoid using the incompatible
version of libprotobuf-python on host.
Test: Local build tests.
Bug: 111798740
Change-Id: Iabca07eb13dbab183fbf85cb0dfe04ce33aa660c
(cherry picked from commit fa47daa47d06429a1ba05aada0f7bcec625bea83)
diff --git a/core/binary.mk b/core/binary.mk
index 4a65c6e..777279b 100644
--- a/core/binary.mk
+++ b/core/binary.mk
@@ -854,7 +854,7 @@
my_proto_source_suffix := .c
my_proto_c_includes := external/nanopb-c
my_protoc_flags := --nanopb_out=$(proto_gen_dir) \
- --plugin=external/nanopb-c/generator/protoc-gen-nanopb
+ --plugin=$(HOST_OUT_EXECUTABLES)/protoc-gen-nanopb
my_protoc_deps := $(NANOPB_SRCS) $(proto_sources_fullpath:%.proto=%.options)
else
my_proto_source_suffix := $(LOCAL_CPP_EXTENSION)