Files
firebase-ios-sdk/Firestore/Protos/README.md
T
rsgowman f98239755a Fix building of objc protos (#1858)
All proto targets (objc, cpp, nanopb) now depend on the proto sources,
so they'll be rebuilt if the proto sources change.

Also updated Firestore/Protos/README.md to reflect recent changes.

Also update travis config to build the protos. (Previously, cpp and
nanopb were rebuilt, since they're used in the cmake build. But objc was
not since it's not actually depended on by anything in cmake.)
2018-09-21 15:33:40 -04:00

791 B

Usage

First, make sure you have necessary prereqs for building:

brew install automake libtool protobuf golang

Take a nap while that completes. Then, build the protos:

cd firebase-ios-sdk
mkdir -p build
cd build
cmake ..
make -j generate_protos

Verify diffs, make sure tests still pass, and create a PR.

Script Details

Get the protoc and the gRPC plugin. See here. The easiest way I found was to add pod '!ProtoCompiler-gRPCPlugin' to a Podfile and do pod update.

After running the protoc, shell commands run to fix up the generated code:

  • Flatten import paths for CocoaPods library build.
  • Remove unneeded extensionRegistry functions.
  • Remove non-buildable code from Annotations.pbobjc.*.