1[package] 2name = "tokio" 3# When releasing to crates.io: 4# - Remove path dependencies 5# - Update doc url 6# - README.md 7# - Update CHANGELOG.md. 8# - Create "v1.x.y" git tag. 9version = "1.25.0" 10edition = "2018" 11rust-version = "1.49" 12authors = ["Tokio Contributors <team@tokio.rs>"] 13license = "MIT" 14readme = "README.md" 15repository = "https://github.com/tokio-rs/tokio" 16homepage = "https://tokio.rs" 17description = """ 18An event-driven, non-blocking I/O platform for writing asynchronous I/O 19backed applications. 20""" 21categories = ["asynchronous", "network-programming"] 22keywords = ["io", "async", "non-blocking", "futures"] 23 24[features] 25# Include nothing by default 26default = [] 27 28# enable everything 29full = [ 30 "fs", 31 "io-util", 32 "io-std", 33 "macros", 34 "net", 35 "parking_lot", 36 "process", 37 "rt", 38 "rt-multi-thread", 39 "signal", 40 "sync", 41 "time", 42] 43 44fs = [] 45io-util = ["memchr", "bytes"] 46# stdin, stdout, stderr 47io-std = [] 48macros = ["tokio-macros"] 49net = [ 50 "libc", 51 "mio/os-poll", 52 "mio/os-ext", 53 "mio/net", 54 "socket2", 55 "windows-sys/Win32_Foundation", 56 "windows-sys/Win32_Security", 57 "windows-sys/Win32_Storage_FileSystem", 58 "windows-sys/Win32_System_Pipes", 59 "windows-sys/Win32_System_SystemServices", 60] 61process = [ 62 "bytes", 63 "libc", 64 "mio/os-poll", 65 "mio/os-ext", 66 "mio/net", 67 "signal-hook-registry", 68 "windows-sys/Win32_Foundation", 69 "windows-sys/Win32_System_Threading", 70 "windows-sys/Win32_System_WindowsProgramming", 71] 72# Includes basic task execution capabilities 73rt = [] 74rt-multi-thread = [ 75 "num_cpus", 76 "rt", 77] 78signal = [ 79 "libc", 80 "mio/os-poll", 81 "mio/net", 82 "mio/os-ext", 83 "signal-hook-registry", 84 "windows-sys/Win32_Foundation", 85 "windows-sys/Win32_System_Console", 86] 87sync = [] 88test-util = ["rt", "sync", "time"] 89time = [] 90 91# Technically, removing this is a breaking change even though it only ever did 92# anything with the unstable flag on. It is probably safe to get rid of it after 93# a few releases. 94stats = [] 95 96[build-dependencies] 97autocfg = "1.1" 98 99[dependencies] 100tokio-macros = { version = "1.7.0", path = "../tokio-macros", optional = true } 101 102pin-project-lite = "0.2.0" 103 104# Everything else is optional... 105bytes = { version = "1.0.0", optional = true } 106memchr = { version = "2.2", optional = true } 107mio = { version = "0.8.4", optional = true } 108num_cpus = { version = "1.8.0", optional = true } 109parking_lot = { version = "0.12.0", optional = true } 110 111[target.'cfg(not(any(target_arch = "wasm32", target_arch = "wasm64")))'.dependencies] 112socket2 = { version = "0.4.4", optional = true, features = [ "all" ] } 113 114# Currently unstable. The API exposed by these features may be broken at any time. 115# Requires `--cfg tokio_unstable` to enable. 116[target.'cfg(tokio_unstable)'.dependencies] 117tracing = { version = "0.1.25", default-features = false, features = ["std"], optional = true } # Not in full 118 119[target.'cfg(unix)'.dependencies] 120libc = { version = "0.2.42", optional = true } 121signal-hook-registry = { version = "1.1.1", optional = true } 122 123[target.'cfg(unix)'.dev-dependencies] 124libc = { version = "0.2.42" } 125nix = { version = "0.26", default-features = false, features = ["fs", "socket"] } 126 127[target.'cfg(windows)'.dependencies.windows-sys] 128version = "0.42.0" 129optional = true 130 131[target.'cfg(docsrs)'.dependencies.windows-sys] 132version = "0.42.0" 133features = [ 134 "Win32_Foundation", 135 "Win32_Security_Authorization", 136] 137 138[target.'cfg(windows)'.dev-dependencies.ntapi] 139version = "0.3.6" 140 141[dev-dependencies] 142tokio-test = { version = "0.4.0", path = "../tokio-test" } 143tokio-stream = { version = "0.1", path = "../tokio-stream" } 144futures = { version = "0.3.0", features = ["async-await"] } 145mockall = "0.11.1" 146tempfile = "3.1.0" 147async-stream = "0.3" 148 149[target.'cfg(not(any(target_arch = "wasm32", target_arch = "wasm64")))'.dev-dependencies] 150proptest = "1" 151socket2 = "0.4" 152 153[target.'cfg(not(all(any(target_arch = "wasm32", target_arch = "wasm64"), target_os = "unknown")))'.dev-dependencies] 154rand = "0.8.0" 155 156[target.'cfg(all(any(target_arch = "wasm32", target_arch = "wasm64"), not(target_os = "wasi")))'.dev-dependencies] 157wasm-bindgen-test = "0.3.0" 158 159[target.'cfg(target_os = "freebsd")'.dev-dependencies] 160mio-aio = { version = "0.7.0", features = ["tokio"] } 161 162[target.'cfg(loom)'.dev-dependencies] 163loom = { version = "0.5.2", features = ["futures", "checkpoint"] } 164 165[package.metadata.docs.rs] 166all-features = true 167# enable unstable features in the documentation 168rustdoc-args = ["--cfg", "docsrs", "--cfg", "tokio_unstable"] 169# it's necessary to _also_ pass `--cfg tokio_unstable` to rustc, or else 170# dependencies will not be enabled, and the docs build will fail. 171rustc-args = ["--cfg", "tokio_unstable"] 172 173[package.metadata.playground] 174features = ["full", "test-util"] 175