upc 0.10.5

USB packet channel (UPC): provides a reliable, packet-based transport over USB.
Documentation
# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
#
# When uploading crates to the registry Cargo will automatically
# "normalize" Cargo.toml files for maximal compatibility
# with all versions of Cargo and also rewrite `path` dependencies
# to registry (e.g., crates.io) dependencies.
#
# If you are reading this file be aware that the original Cargo.toml
# will likely look very different (and much more reasonable).
# See Cargo.toml.orig for the original contents.

[package]
edition = "2021"
rust-version = "1.85"
name = "upc"
version = "0.10.5"
authors = ["Sebastian Urban <surban@surban.net>"]
build = false
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "USB packet channel (UPC): provides a reliable, packet-based transport over USB."
readme = "README.md"
keywords = [
    "usb",
    "gadget",
    "packet",
    "channel",
]
categories = [
    "hardware-support",
    "asynchronous",
]
license = "Apache-2.0"
repository = "https://github.com/surban/upc"

[package.metadata.docs.rs]
features = [
    "host",
    "device",
]
rustdoc-args = [
    "--cfg",
    "web_sys_unstable_apis",
]
cargo-args = [
    "-Zunstable-options",
    "-Zrustdoc-scrape-examples",
]
rustc-args = [
    "--cfg",
    "web_sys_unstable_apis",
]

[features]
cli = [
    "dep:clap",
    "dep:tracing-subscriber",
    "dep:tracing-log",
    "tokio/io-std",
    "tokio/io-util",
]
default = []
device = [
    "dep:usb-gadget",
    "tokio/rt",
]
host = [
    "dep:nusb",
    "tokio/rt",
]
trace-packets = []
web = [
    "dep:js-sys",
    "dep:webusb-web",
    "dep:wasm-bindgen",
    "dep:wasm-bindgen-futures",
    "dep:web-sys",
    "dep:getrandom",
]

[lib]
name = "upc"
path = "src/lib.rs"

[[bin]]
name = "upc"
path = "src/bin/upc.rs"
required-features = ["cli"]

[[example]]
name = "device"
path = "examples/device.rs"
doc-scrape-examples = true
required-features = ["device"]

[[example]]
name = "host"
path = "examples/host.rs"
doc-scrape-examples = true
required-features = ["host"]

[[example]]
name = "simple_device"
path = "examples/simple_device.rs"
required-features = ["device"]

[[example]]
name = "simple_host"
path = "examples/simple_host.rs"
required-features = ["host"]

[[test]]
name = "failure"
path = "tests/failure.rs"

[[test]]
name = "half_close"
path = "tests/half_close.rs"

[[test]]
name = "invalid_ctrl"
path = "tests/invalid_ctrl.rs"

[[test]]
name = "loopback"
path = "tests/loopback.rs"

[[test]]
name = "web"
path = "tests/web.rs"

[dependencies.bytes]
version = "1.4"

[dependencies.clap]
version = "4"
features = ["derive"]
optional = true

[dependencies.futures]
version = "0.3"

[dependencies.getrandom]
version = "0.4"
features = ["wasm_js"]
optional = true

[dependencies.js-sys]
version = "0.3"
optional = true

[dependencies.nusb]
version = "0.2"
features = ["tokio"]
optional = true

[dependencies.tokio]
version = "1.43"
features = [
    "macros",
    "sync",
    "time",
]

[dependencies.tracing]
version = "0.1"

[dependencies.tracing-log]
version = "0.2"
optional = true

[dependencies.tracing-subscriber]
version = "0.3"
features = [
    "env-filter",
    "fmt",
]
optional = true
default-features = false

[dependencies.usb-gadget]
version = "1.1.1"
features = ["tokio"]
optional = true

[dependencies.uuid]
version = "1.13"

[dependencies.wasm-bindgen]
version = "0.2"
optional = true

[dependencies.wasm-bindgen-futures]
version = "0.4"
optional = true

[dependencies.web-sys]
version = "0.3"
features = [
    "Window",
    "WorkerGlobalScope",
]
optional = true

[dependencies.webusb-web]
version = "0.5.1"
optional = true

[dev-dependencies.rand]
version = "0.10"
features = ["chacha"]

[dev-dependencies.serial_test]
version = "3"

[dev-dependencies.tokio]
version = "1"
features = ["time"]

[dev-dependencies.tracing-log]
version = "0.2"

[dev-dependencies.tracing-subscriber]
version = "0.3"
features = [
    "env-filter",
    "fmt",
]
default-features = false

[target.'cfg(not(target_arch = "wasm32"))'.dev-dependencies.tokio]
version = "1"
features = [
    "time",
    "rt-multi-thread",
    "signal",
]

[target.'cfg(target_arch = "wasm32")'.dev-dependencies.getrandom]
version = "0.4"
features = ["wasm_js"]

[target.'cfg(target_arch = "wasm32")'.dev-dependencies.wasm-bindgen-test]
version = "0.3"

[target.'cfg(target_arch = "wasm32")'.dev-dependencies.web-sys]
version = "0.3"
features = [
    "console",
    "Document",
    "HtmlElement",
]