Skip to content

Commit

Permalink
Merge branch 'tokio-rs:main' into host_unreachable
Browse files Browse the repository at this point in the history
  • Loading branch information
brandonpike authored Nov 30, 2024
2 parents 454be72 + c4c5414 commit 49a7038
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 16 deletions.
2 changes: 1 addition & 1 deletion examples/grpc/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@ tracing-subscriber = "0.3"
turmoil = { path = "../.." }

[build-dependencies]
tonic-build = "0.12"
tonic-build = "0.12.3"
protox = "0.7"
prost = "0.13"
17 changes: 2 additions & 15 deletions examples/grpc/build.rs
Original file line number Diff line number Diff line change
@@ -1,17 +1,4 @@
use prost::Message;
use std::path::PathBuf;

fn main() -> std::io::Result<()> {
let file_descriptors = protox::compile(["helloworld.proto"], ["."]).unwrap();
let file_descriptor_path = PathBuf::from(std::env::var_os("OUT_DIR").expect("OUT_DIR not set"))
.join("file_descriptor_set.bin");
std::fs::write(&file_descriptor_path, file_descriptors.encode_to_vec()).unwrap();

tonic_build::configure()
.file_descriptor_set_path(&file_descriptor_path)
.skip_protoc_run()
.compile_protos(&["helloworld.proto"], &["."])
.unwrap();

Ok(())
let fds = protox::compile(["helloworld.proto"], ["."]).unwrap();
tonic_build::compile_fds(fds)
}

0 comments on commit 49a7038

Please sign in to comment.