From 2ed70bdebf884369d23a5d82bf06a935084ded88 Mon Sep 17 00:00:00 2001 From: Syrus Akbary Date: Thu, 2 Dec 2021 12:58:19 +0100 Subject: [PATCH] Make C-API and Wasi dependencies more lean --- lib/c-api/Cargo.toml | 6 +++--- lib/wasi/Cargo.toml | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/c-api/Cargo.toml b/lib/c-api/Cargo.toml index 0d01c56f77f..2fe5f10b750 100644 --- a/lib/c-api/Cargo.toml +++ b/lib/c-api/Cargo.toml @@ -22,7 +22,7 @@ crate-type = ["cdylib", "rlib", "staticlib"] [dependencies] # We rename `wasmer` to `wasmer-api` to avoid the conflict with this # library name (see `[lib]`). -wasmer-api = { version = "2.1.0", path = "../api", default-features = false, package = "wasmer" } +wasmer-api = { version = "2.1.0", path = "../api", default-features = false, features = ["sys"], package = "wasmer" } wasmer-compiler-cranelift = { version = "2.1.0", path = "../compiler-cranelift", optional = true } wasmer-compiler-singlepass = { version = "2.1.0", path = "../compiler-singlepass", optional = true } wasmer-compiler-llvm = { version = "2.1.0", path = "../compiler-llvm", optional = true } @@ -32,7 +32,7 @@ wasmer-engine-universal = { version = "2.1.0", path = "../engine-universal", opt wasmer-engine-dylib = { version = "2.1.0", path = "../engine-dylib", optional = true } wasmer-engine-staticlib = { version = "2.1.0", path = "../engine-staticlib", optional = true } wasmer-middlewares = { version = "2.1.0", path = "../middlewares", optional = true } -wasmer-wasi = { version = "2.1.0", path = "../wasi", optional = true } +wasmer-wasi = { version = "2.1.0", path = "../wasi", default-features = false, features = ["host-fs", "sys"], optional = true } wasmer-types = { version = "2.1.0", path = "../types" } enumset = "1.0" cfg-if = "1.0" @@ -56,7 +56,7 @@ default = [ "middlewares", ] wat = ["wasmer-api/wat"] -wasi = ["wasmer-wasi", "typetag", "serde"] +wasi = ["wasmer-wasi"] engine = [] middlewares = [ "compiler", diff --git a/lib/wasi/Cargo.toml b/lib/wasi/Cargo.toml index 33c4b360f61..b8cd30bd431 100644 --- a/lib/wasi/Cargo.toml +++ b/lib/wasi/Cargo.toml @@ -42,8 +42,8 @@ tracing-wasm = "0.2" [features] default = ["sys-default"] -sys = ["wasmer/sys-default"] -sys-default = ["sys", "logging", "host-fs"] +sys = ["wasmer/sys"] +sys-default = ["wasmer/sys-default", "sys", "logging", "host-fs"] js = ["wasmer/js", "mem-fs", "wasmer-vfs/no-time", "getrandom/js"] js-default = ["js", "wasmer/js-default"]