wasmtime-cli: drop direct dep on cap_std by using re-export
This commit is contained in:
1
Cargo.lock
generated
1
Cargo.lock
generated
@@ -3269,7 +3269,6 @@ name = "wasmtime-cli"
|
|||||||
version = "0.25.0"
|
version = "0.25.0"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"anyhow",
|
"anyhow",
|
||||||
"cap-std",
|
|
||||||
"env_logger 0.8.3",
|
"env_logger 0.8.3",
|
||||||
"file-per-thread-logger",
|
"file-per-thread-logger",
|
||||||
"filecheck",
|
"filecheck",
|
||||||
|
|||||||
@@ -44,7 +44,6 @@ log = "0.4.8"
|
|||||||
rayon = "1.2.1"
|
rayon = "1.2.1"
|
||||||
humantime = "2.0.0"
|
humantime = "2.0.0"
|
||||||
wasmparser = "0.77.0"
|
wasmparser = "0.77.0"
|
||||||
cap-std = "0.13"
|
|
||||||
|
|
||||||
[dev-dependencies]
|
[dev-dependencies]
|
||||||
env_logger = "0.8.1"
|
env_logger = "0.8.1"
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
//! The WASI embedding API definitions for Wasmtime.
|
//! The WASI embedding API definitions for Wasmtime.
|
||||||
use crate::{wasm_extern_t, wasm_importtype_t, wasm_store_t, wasm_trap_t};
|
use crate::{wasm_extern_t, wasm_importtype_t, wasm_store_t, wasm_trap_t};
|
||||||
use anyhow::Result;
|
use anyhow::Result;
|
||||||
use cap_std::fs::Dir;
|
|
||||||
use std::cell::RefCell;
|
use std::cell::RefCell;
|
||||||
use std::collections::HashMap;
|
use std::collections::HashMap;
|
||||||
use std::ffi::CStr;
|
use std::ffi::CStr;
|
||||||
@@ -13,8 +12,10 @@ use std::slice;
|
|||||||
use std::str;
|
use std::str;
|
||||||
use wasmtime::{Extern, Linker, Trap};
|
use wasmtime::{Extern, Linker, Trap};
|
||||||
use wasmtime_wasi::{
|
use wasmtime_wasi::{
|
||||||
snapshots::preview_0::Wasi as WasiSnapshot0, snapshots::preview_1::Wasi as WasiPreview1,
|
snapshots::preview_0::Wasi as WasiSnapshot0,
|
||||||
sync::WasiCtxBuilder, WasiCtx,
|
snapshots::preview_1::Wasi as WasiPreview1,
|
||||||
|
sync::{Dir, WasiCtxBuilder},
|
||||||
|
WasiCtx,
|
||||||
};
|
};
|
||||||
|
|
||||||
unsafe fn cstr_to_path<'a>(path: *const c_char) -> Option<&'a Path> {
|
unsafe fn cstr_to_path<'a>(path: *const c_char) -> Option<&'a Path> {
|
||||||
|
|||||||
@@ -2,7 +2,6 @@
|
|||||||
|
|
||||||
use crate::{init_file_per_thread_logger, CommonOptions};
|
use crate::{init_file_per_thread_logger, CommonOptions};
|
||||||
use anyhow::{bail, Context as _, Result};
|
use anyhow::{bail, Context as _, Result};
|
||||||
use cap_std::fs::Dir;
|
|
||||||
use std::thread;
|
use std::thread;
|
||||||
use std::time::Duration;
|
use std::time::Duration;
|
||||||
use std::{
|
use std::{
|
||||||
@@ -12,7 +11,10 @@ use std::{
|
|||||||
};
|
};
|
||||||
use structopt::{clap::AppSettings, StructOpt};
|
use structopt::{clap::AppSettings, StructOpt};
|
||||||
use wasmtime::{Engine, Func, Linker, Module, Store, Trap, Val, ValType};
|
use wasmtime::{Engine, Func, Linker, Module, Store, Trap, Val, ValType};
|
||||||
use wasmtime_wasi::{sync::WasiCtxBuilder, Wasi};
|
use wasmtime_wasi::{
|
||||||
|
sync::{Dir, WasiCtxBuilder},
|
||||||
|
Wasi,
|
||||||
|
};
|
||||||
|
|
||||||
#[cfg(feature = "wasi-nn")]
|
#[cfg(feature = "wasi-nn")]
|
||||||
use wasmtime_wasi_nn::{WasiNn, WasiNnCtx};
|
use wasmtime_wasi_nn::{WasiNn, WasiNnCtx};
|
||||||
|
|||||||
Reference in New Issue
Block a user