working
This commit is contained in:
24
protos/build.rs
Normal file
24
protos/build.rs
Normal file
@@ -0,0 +1,24 @@
|
||||
// // build.rs
|
||||
// use micropb_gen::{Generator, Config};
|
||||
|
||||
// let mut generator = Generator::new();
|
||||
// generator.use_container_heapless().configure(".example.Example", Config::new().type_attributes("#[derive(Clone)]"));
|
||||
|
||||
// generator.compile_protos(&["transport.proto"], std::env::var("OUT_DIR").unwrap() + "/example.rs").unwrap();
|
||||
|
||||
// build.rs
|
||||
use micropb_gen::{Config, Generator};
|
||||
|
||||
fn main() {
|
||||
// <--- YOU MUST ADD THIS
|
||||
let mut generator = Generator::new();
|
||||
|
||||
generator.use_container_heapless();
|
||||
|
||||
generator
|
||||
.compile_protos(
|
||||
&["transport.proto"],
|
||||
std::env::var("OUT_DIR").unwrap() + "/nieco.rs",
|
||||
)
|
||||
.unwrap();
|
||||
} // <--- AND THIS
|
||||
Reference in New Issue
Block a user