build.rs 460 B

1234567891011121314151617
  1. extern crate vergen;
  2. extern crate protobuf_macros;
  3. use std::env;
  4. use std::path::PathBuf;
  5. fn main() {
  6. vergen::vergen(vergen::OutputFns::all()).unwrap();
  7. let out = PathBuf::from(env::var("OUT_DIR").unwrap());
  8. protobuf_macros::expand("src/lib.in.rs", &out.join("lib.rs")).unwrap();
  9. println!("cargo:rerun-if-changed=src/lib.in.rs");
  10. println!("cargo:rerun-if-changed=src/spirc.rs");
  11. println!("cargo:rerun-if-changed=src/connection");
  12. }