librespot/core/Cargo.toml
Benedikt 94d174c33d
Discovery: Refactor and add Avahi DBus backend (#1347)
* discovery: use opaque error type for DnsSdError

This helps to decouple discovery and core by not leaking implementation
details of the zeroconf backend into Error conversion impls in core.

* discovery: map all MDNS/DNS-SD errors to DiscoveryError::DnsSdError

previously, libmdns errors would use a generic conversion
from std::io::Error to core::Error

* discovery: use an opaque type for the handle to the DNS-SD service

* discovery: make features additive

i.e. add with-libmdns instead of using not(with-dns-sd).

The logic is such that enabling with-dns-sd in addition to the default
with-libmdns will still end up using dns-sd, as before.
If only with-libmdns is enabled, that will be the default.
If none of the features is enabled, attempting to build a `Discovery`
will yield an error.

* discovery: add --zeroconf-backend CLI flag

* discovery: Add minimal Avahi zeroconf backend

* bump MSRV to 1.75

required by zbus >= 4

* discovery: ensure that server and dns-sd backend shutdown gracefully

Previously, on drop the the shutdown_tx/close_tx, it wasn't guaranteed
the corresponding tasks would continue to be polled until they actually
completed their shutdown.

Since dns_sd::Service is not Send and non-async, and because libmdns is
non-async, put them on their own threads.

* discovery: use a shared channel for server and zeroconf status messages

* discovery: add Avahi reconnection logic

This deals gracefully with the case where the Avahi daemon is restarted
or not running initially.

* discovery: allow running when compiled without zeroconf backend...

...but exit with an error if there's no way to authenticate

* better error messages for invalid options with no short flag
2024-10-26 16:45:02 +02:00

72 lines
2.4 KiB
TOML

[package]
name = "librespot-core"
version = "0.5.0"
rust-version.workspace = true
authors = ["Paul Lietar <paul@lietar.net>"]
build = "build.rs"
description = "The core functionality provided by librespot"
license = "MIT"
repository = "https://github.com/librespot-org/librespot"
edition = "2021"
[dependencies.librespot-oauth]
path = "../oauth"
version = "0.5.0"
[dependencies.librespot-protocol]
path = "../protocol"
version = "0.5.0"
[dependencies]
aes = "0.8"
base64 = "0.22"
byteorder = "1.4"
bytes = "1"
form_urlencoded = "1.0"
futures-core = "0.3"
futures-util = { version = "0.3", features = ["alloc", "bilock", "sink", "unstable"] }
governor = { version = "0.6", default-features = false, features = ["std", "jitter"] }
hmac = "0.12"
httparse = "1.7"
http = "1.0"
hyper = { version = "1.3", features = ["http1", "http2"] }
hyper-util = { version = "0.1", features = ["client"] }
http-body-util = "0.1.1"
hyper-proxy2 = { version = "0.1", default-features = false, features = ["rustls"] }
hyper-rustls = { version = "0.27.2", features = ["http2"] }
log = "0.4"
nonzero_ext = "0.3"
num-bigint = { version = "0.4", features = ["rand"] }
num-derive = "0.4"
num-integer = "0.1"
num-traits = "0.2"
once_cell = "1"
parking_lot = { version = "0.12", features = ["deadlock_detection"] }
pbkdf2 = { version = "0.12", default-features = false, features = ["hmac"] }
pin-project-lite = "0.2"
priority-queue = "2.0"
protobuf = "3.5"
quick-xml = { version = "0.36.1", features = ["serialize"] }
rand = "0.8"
rsa = "0.9.2"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
sha1 = { version = "0.10", features = ["oid"] }
shannon = "0.2"
sysinfo = { version = "0.31.3", default-features = false, features = ["system"] }
thiserror = "1.0"
time = { version = "0.3", features = ["formatting", "parsing"] }
tokio = { version = "1", features = ["io-util", "macros", "net", "parking_lot", "rt", "sync", "time"] }
tokio-stream = "0.1"
tokio-tungstenite = { version = "0.24", default-features = false, features = ["rustls-tls-native-roots"] }
tokio-util = { version = "0.7", features = ["codec"] }
url = "2"
uuid = { version = "1", default-features = false, features = ["fast-rng", "v4"] }
data-encoding = "2.5"
[build-dependencies]
rand = "0.8"
vergen-gitcl = { version = "1.0.0", default-features = false, features = ["build"] }
[dev-dependencies]
tokio = { version = "1", features = ["macros", "parking_lot"] }