added logging to build

This commit is contained in:
Jazz Turner-Baggs 2025-06-25 15:58:49 -07:00
parent ba3b90407f
commit 533bd31357
No known key found for this signature in database

View File

@ -4,21 +4,27 @@ use std::env;
use std::path::PathBuf; use std::path::PathBuf;
fn get_proto_dir() -> PathBuf { fn get_proto_dir() -> PathBuf {
println!(
"Manifest dir: {:?}",
env::var("CARGO_MANIFEST_DIR").unwrap()
);
// protos are stored in ../../proto/ // protos are stored in ../../proto/
let mut proto_root_dir = PathBuf::from(env::var("CARGO_MANIFEST_DIR").unwrap()); let mut proto_root_dir = PathBuf::from(env::var("CARGO_MANIFEST_DIR").unwrap());
proto_root_dir.pop(); proto_root_dir.pop();
proto_root_dir.pop(); proto_root_dir.pop();
println!("proto_dir: {:?}", proto_root_dir);
proto_root_dir proto_root_dir
} }
fn main() { fn main() {
let mut config = prost_build::Config::new(); let mut config = prost_build::Config::new();
// Create mod file to maintain import hierarchy // Create mod file to maintain import hierarchy
config.include_file("mod.rs"); config.include_file("mod.rs");
config
config.compile_protos( .compile_protos(
&[ &[
"proto/umbra/base.proto", "proto/umbra/base.proto",
"proto/umbra/common_frames.proto", "proto/umbra/common_frames.proto",