change output to go to OUT_DIR

This commit is contained in:
Mark McCaskey 2019-03-19 11:23:04 -07:00
parent 8253862935
commit b1ef4ef0fa
3 changed files with 4 additions and 4 deletions

View File

@ -1,5 +1,5 @@
use blake2b_simd::blake2bp;
use std::{fs, io::Write, path::PathBuf};
use std::{env, fs, io::Write, path::PathBuf};
const WASMER_VERSION: &'static str = env!("CARGO_PKG_VERSION");
@ -10,7 +10,7 @@ fn main() {
let hasher = state.finalize();
let hash_string = hasher.to_hex().as_str().to_owned();
let crate_dir = env!("CARGO_MANIFEST_DIR");
let crate_dir = env::var("OUT_DIR").unwrap();
let wasmer_version_hash_file = {
let mut path = PathBuf::from(&crate_dir);
path.push("wasmer_version_hash.txt");

View File

@ -209,4 +209,5 @@ pub trait Cache {
}
/// A unique ID generated from the version of Wasmer for use with cache versioning
pub const WASMER_VERSION_HASH: &'static str = include_str!("../wasmer_version_hash.txt");
pub const WASMER_VERSION_HASH: &'static str =
include_str!(concat!(env!("OUT_DIR"), "/wasmer_version_hash.txt"));

View File

@ -1 +0,0 @@
beb6542931f7f7c823b8d1804b12639fd794711af1f90263c5ed7d338bf4429d1cbe69a531f18144f208c33c49ca01315ffa2b23c170e4c979b1114ffcfbba54