8 releases (stable)

1.1.0+21.5 Sep 2, 2022
1.0.5+3.19.3 Jan 28, 2022
1.0.1+3.19.1 Dec 23, 2021
0.1.0+3.19.1 Dec 22, 2021

#190 in Network programming

Download history 12362/week @ 2022-12-09 13446/week @ 2022-12-16 5497/week @ 2022-12-23 7691/week @ 2022-12-30 12084/week @ 2023-01-06 12347/week @ 2023-01-13 14003/week @ 2023-01-20 17436/week @ 2023-01-27 16046/week @ 2023-02-03 16655/week @ 2023-02-10 15104/week @ 2023-02-17 18419/week @ 2023-02-24 16630/week @ 2023-03-03 22276/week @ 2023-03-10 22175/week @ 2023-03-17 19247/week @ 2023-03-24

83,578 downloads per month
Used in 56 crates (14 directly)

Apache-2.0

12MB
245K SLoC

C++ 206K SLoC // 0.1% comments Shell 25K SLoC // 0.2% comments Python 4K SLoC // 0.4% comments Automake 3.5K SLoC // 0.1% comments C 2.5K SLoC // 0.2% comments Visual Studio Project 2K SLoC Java 742 SLoC // 0.1% comments Prolog 477 SLoC // 0.1% comments Go 308 SLoC // 0.1% comments Ruby 268 SLoC // 0.1% comments Visual Studio Solution 188 SLoC Objective-C 178 SLoC // 0.3% comments PHP 104 SLoC Dart 90 SLoC // 0.1% comments Emacs Lisp 87 SLoC // 0.5% comments Vim script 72 SLoC // 0.2% comments Rust 27 SLoC // 0.5% comments Xcode Config 14 SLoC // 0.6% comments

protobuf-src

crates.io CI Rust Documentation

Rust build system integration with libprotobuf, the C++ implementation of Protocol Buffers, Google's data interchange format.

View documentation.

Installation

# Cargo.toml
[dependencies]
protobuf-src = "1.1.0"

lib.rs:

Build system integration with libprotobuf, the C++ implementation of Protocol Buffers, Google's data interchange format.

Maintainership

This crate is maintained by Materialize. Contributions are encouraged:

Details

This crate builds a vendored copy of libprotobuf and protoc using Cargo's support for custom build scripts. It is not intended for direct consumption, but as a dependency for other crates that need libprotobuf or protoc available, like prost-build.

protobuf-src is currently bundling protobuf v3.19.1.

To use this crate, declare a dependency or dev-dependency on protobuf-src. Then, in the build script for your crate, the environment variable DEP_PROTOBUF_SRC_ROOT will point to the directory in which the bundled copy of protobuf has been installed. You can build and link another C/C++ library against this copy of libprotobuf or generate Rust bindings and link Rust code against this copy of libprotobuf.

If you simply need to invoke the vendored protoc binary, [protoc] returns the path to pass to [std::process::Command].

Dependencies