Skip to content

Commit

Permalink
Merge a729b6e into 488f826
Browse files Browse the repository at this point in the history
  • Loading branch information
tustvold authored May 25, 2021
2 parents 488f826 + a729b6e commit d5777ce
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions arrow-flight/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,16 @@ use std::{
};

fn main() -> Result<(), Box<dyn std::error::Error>> {
// avoid rerunning build if the file has not changed
println!("cargo:rerun-if-changed=../format/Flight.proto");

// override the build location, in order to check in the changes to proto files
env::set_var("OUT_DIR", "src");

// The current working directory can vary depending on how the project is being
// built or released so we build an absolute path to the proto file
let path = Path::new("../format/Flight.proto");
if path.exists() {
// avoid rerunning build if the file has not changed
println!("cargo:rerun-if-changed=../format/Flight.proto");

tonic_build::compile_protos("../format/Flight.proto")?;
// read file contents to string
let mut file = OpenOptions::new()
Expand Down

0 comments on commit d5777ce

Please sign in to comment.