diff --git a/README.md b/README.md index cacbd72..75b11ac 100644 --- a/README.md +++ b/README.md @@ -52,6 +52,31 @@ $ rustup update $ cargo build ``` +### Dependencies + +In order to build `tonic` >= 0.8.0, you need the `protoc` Protocol Buffers compiler, along with Protocol Buffers resource files. + +#### Ubuntu + +```bash +sudo apt update && sudo apt upgrade -y +sudo apt install -y protobuf-compiler libprotobuf-dev +``` + +#### Alpine Linux + +```sh +sudo apk add protoc protobuf-dev +``` + +#### macOS + +Assuming [Homebrew](https://brew.sh/) is already installed. (If not, see instructions for installing Homebrew on [the Homebrew website](https://brew.sh/).) + +```zsh +brew install protobuf +``` + ### Tutorials - The [`helloworld`][helloworld-tutorial] tutorial provides a basic example of using `tonic`, perfect for first time users! diff --git a/examples/README.md b/examples/README.md index e71c5bd..f11da34 100644 --- a/examples/README.md +++ b/examples/README.md @@ -2,6 +2,30 @@ Set of examples that show off the features provided by `tonic`. +In order to build these examples, you must have the `protoc` Protocol Buffers compiler +installed, along with the Protocol Buffers resource files. + +Ubuntu: + +```bash +sudo apt update && sudo apt upgrade -y +sudo apt install -y protobuf-compiler libprotobuf-dev +``` + +Alpine Linux: + +```sh +sudo apk add protoc protobuf-dev +``` + +macOS: + +Assuming [Homebrew](https://brew.sh/) is already installed. (If not, see instructions for installing Homebrew on [the Homebrew website](https://brew.sh/).) + +```zsh +brew install protobuf +``` + ## Helloworld ### Client