Cargo Features
[dependencies]
wasmtime-cli = { version = "20.0.1", default-features = false, features = ["all-arch", "winch", "wmemcheck", "disable-logging", "wasi-nn", "wasi-threads", "wasi-http", "pooling-allocator", "component-model", "wat", "cache", "parallel-compilation", "logging", "demangle", "cranelift", "profiling", "coredump", "addr2line", "debug-builtins", "threads", "gc", "old-cli", "serve", "explore", "wast", "config", "compile", "run"] }
=============================================================================
Features for the Wasmtime CLI executable
Note that many of these features are inherited from Wasmtime itself or otherwise configure the
wasmtime
crate's execution. Features are provided as compile-time switches to disable functionality primarily if one is interested in configuring binary size and or exploring the binary size implications of various features. Most features are enabled by default but most embeddings likely won't need all features.
- default = addr2line, cache, compile, component-model, config, coredump, cranelift, debug-builtins, demangle, explore, gc, logging, old-cli, parallel-compilation, pooling-allocator, profiling, run, serve, threads, wasi-http, wasi-nn, wasi-threads, wast, wat
-
These default features are set whenever
wasmtime-cli
is added without
somewhere in the dependency tree.default-features = false Enables clap
- all-arch
-
========================================
Off-by-default features
These features are off-by-default but may optionally be enabled.depend again on wasmtime to activate its default features for tests
- winch
- wmemcheck
- disable-logging
-
This feature, when enabled, will statically compile out all logging statements throughout Wasmtime and its dependencies.
Enables max_level_off of log and tracing
- wasi-nn default
-
======================================== On-by-default features
These features are all included in the
default
set above and this is the internal mapping for what they enable in Wasmtime itself.Enables wasmtime-wasi-nn
- wasi-threads default = threads
-
Enables wasmtime-wasi-threads
- wasi-http default serve = component-model
-
Enables hyper, tokio, and wasmtime-wasi-http
- pooling-allocator default
-
Enables pooling-allocator of wasmtime and wasmtime-cli-flags
Affects
old_cli::CommonOptions.pooling_allocator
… - component-model default serve wasi-http
-
Enables component-model of wasmtime, wasmtime-cli-flags, and optional wasmtime-wast
- wat default
- cache default config
-
Enables wasmtime-cache, cache of wasmtime-cli-flags
- parallel-compilation default
-
Enables parallel-compilation of wasmtime-cli-flags
- logging default
-
Enables logging of wasmtime-cli-flags
- demangle default
- cranelift default compile
-
Enables wasmtime-cranelift, cranelift of wasmtime-cli-flags
- profiling default
- coredump default
-
Enables coredump of wasmtime-cli-flags
- addr2line default
- debug-builtins default
-
Enables debug-builtins of wasmtime
- threads default wasi-threads
-
Enables threads of wasmtime-cli-flags
- gc default
-
Enables gc of wasmtime-cli-flags
- old-cli default
-
Enables compatibility shims with Wasmtime 13 and prior's CLI.
Affects
wasmtime-cli::old_cli
… - serve default = component-model, wasi-http
-
CLI subcommands for the
wasmtime
executable. Seewasmtime $cmd --help
for more information on each subcommand.Enables http and http-body-util
- explore default
-
Enables wasmtime-explorer
- wast default
-
Enables wasmtime-wast
- config default = cache
- compile default = cranelift
- run default = wasmtime-runtime
-
Enables wasmtime-wasi, listenfd and wasi-common, runtime of wasmtime
Features from optional dependencies
In crates that don't use the dep:
syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.