From 364300f6cff1ecf779a4f240946fe29237c76ca0 Mon Sep 17 00:00:00 2001 From: Artur Jamro Date: Wed, 4 Sep 2019 13:12:27 -0700 Subject: [PATCH] Use target triple in cache directory hierarchy (#300) --- wasmtime-environ/src/cache.rs | 2 +- wasmtime-runtime/src/mmap.rs | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/wasmtime-environ/src/cache.rs b/wasmtime-environ/src/cache.rs index 71de817f3a..905ac26f9a 100644 --- a/wasmtime-environ/src/cache.rs +++ b/wasmtime-environ/src/cache.rs @@ -231,7 +231,7 @@ impl ModuleCacheEntry { ); Some( conf::cache_directory() - .join(isa.name()) + .join(isa.triple().to_string()) .join(compiler_dir) .join(mod_filename), ) diff --git a/wasmtime-runtime/src/mmap.rs b/wasmtime-runtime/src/mmap.rs index f54d861387..7cd024e905 100644 --- a/wasmtime-runtime/src/mmap.rs +++ b/wasmtime-runtime/src/mmap.rs @@ -4,6 +4,7 @@ use core::ptr; use core::slice; use errno; +#[cfg(not(target_os = "windows"))] use libc; use region; use std::string::{String, ToString};