mirror of
https://github.com/librespot-org/librespot.git
synced 2024-11-08 16:45:43 +00:00
Remove and update dependencies (#1140)
This commit is contained in:
parent
a7fb7ee673
commit
e14dac3ff3
10 changed files with 707 additions and 703 deletions
6
.github/workflows/test.yml
vendored
6
.github/workflows/test.yml
vendored
|
@ -55,7 +55,7 @@ jobs:
|
|||
matrix:
|
||||
os: [ubuntu-latest]
|
||||
toolchain:
|
||||
- "1.61" # MSRV (Minimum supported rust version)
|
||||
- "1.64" # MSRV (Minimum supported rust version)
|
||||
- stable
|
||||
experimental: [false]
|
||||
# Ignore failures in beta
|
||||
|
@ -113,7 +113,7 @@ jobs:
|
|||
matrix:
|
||||
os: [windows-latest]
|
||||
toolchain:
|
||||
- "1.61" # MSRV (Minimum supported rust version)
|
||||
- "1.64" # MSRV (Minimum supported rust version)
|
||||
- stable
|
||||
steps:
|
||||
- name: Checkout code
|
||||
|
@ -160,7 +160,7 @@ jobs:
|
|||
os: [ubuntu-latest]
|
||||
target: [armv7-unknown-linux-gnueabihf]
|
||||
toolchain:
|
||||
- "1.61" # MSRV (Minimum supported rust version)
|
||||
- "1.64" # MSRV (Minimum supported rust version)
|
||||
- stable
|
||||
steps:
|
||||
- name: Checkout code
|
||||
|
|
1348
Cargo.lock
generated
1348
Cargo.lock
generated
File diff suppressed because it is too large
Load diff
|
@ -50,7 +50,7 @@ path = "protocol"
|
|||
version = "0.5.0-dev"
|
||||
|
||||
[dependencies]
|
||||
env_logger = { version = "0.9", default-features = false, features = ["termcolor", "humantime", "atty"] }
|
||||
env_logger = { version = "0.10", default-features = false, features = ["color", "humantime", "auto-color"] }
|
||||
futures-util = { version = "0.3", default_features = false }
|
||||
getopts = "0.2"
|
||||
hex = "0.4"
|
||||
|
|
|
@ -22,7 +22,7 @@ dns-sd = { version = "0.1", optional = true }
|
|||
form_urlencoded = "1.0"
|
||||
futures-core = "0.3"
|
||||
futures-util = { version = "0.3", features = ["alloc", "bilock", "sink", "unstable"] }
|
||||
governor = { version = "0.4", default-features = false, features = ["std", "jitter"] }
|
||||
governor = { version = "0.5", default-features = false, features = ["std", "jitter"] }
|
||||
hex = "0.4"
|
||||
hmac = "0.12"
|
||||
httparse = "1.7"
|
||||
|
@ -32,14 +32,13 @@ hyper-proxy = { version = "0.9", default-features = false, features = ["rustls"]
|
|||
hyper-rustls = { version = "0.23", features = ["http2"] }
|
||||
log = "0.4"
|
||||
nonzero_ext = "0.3"
|
||||
num = "0.4"
|
||||
num-bigint = { version = "0.4", features = ["rand"] }
|
||||
num-derive = "0.3"
|
||||
num-integer = "0.1"
|
||||
num-traits = "0.2"
|
||||
once_cell = "1"
|
||||
parking_lot = { version = "0.12", features = ["deadlock_detection"] }
|
||||
pbkdf2 = { version = "0.11", default-features = false, features = ["hmac"] }
|
||||
pbkdf2 = { version = "0.12", default-features = false, features = ["hmac"] }
|
||||
priority-queue = "1.2"
|
||||
protobuf = "3"
|
||||
quick-xml = { version = "0.23", features = ["serialize"] }
|
||||
|
@ -49,7 +48,7 @@ serde = { version = "1.0", features = ["derive"] }
|
|||
serde_json = "1.0"
|
||||
sha1 = "0.10"
|
||||
shannon = "0.2"
|
||||
sysinfo = { version = "0.27", default-features = false }
|
||||
sysinfo = { version = "0.28", default-features = false }
|
||||
thiserror = "1.0"
|
||||
time = { version = "0.3", features = ["formatting", "parsing"] }
|
||||
tokio = { version = "1", features = ["io-util", "macros", "net", "parking_lot", "rt", "sync", "time"] }
|
||||
|
@ -64,7 +63,7 @@ rand = "0.8"
|
|||
vergen = { version = "7", default-features = false, features = ["build", "git"] }
|
||||
|
||||
[dev-dependencies]
|
||||
env_logger = "0.9"
|
||||
env_logger = "0.10"
|
||||
tokio = { version = "1", features = ["macros", "parking_lot"] }
|
||||
|
||||
[features]
|
||||
|
|
|
@ -2,8 +2,7 @@ use std::io::{self, Read};
|
|||
|
||||
use aes::Aes192;
|
||||
use byteorder::{BigEndian, ByteOrder};
|
||||
use hmac::Hmac;
|
||||
use pbkdf2::pbkdf2;
|
||||
use pbkdf2::pbkdf2_hmac;
|
||||
use protobuf::Enum;
|
||||
use serde::{Deserialize, Serialize};
|
||||
use sha1::{Digest, Sha1};
|
||||
|
@ -96,7 +95,7 @@ impl Credentials {
|
|||
return Err(AuthenticationError::Key.into());
|
||||
}
|
||||
|
||||
pbkdf2::<Hmac<Sha1>>(&secret, username.as_bytes(), 0x100, &mut key[0..20]);
|
||||
pbkdf2_hmac::<Sha1>(&secret, username.as_bytes(), 0x100, &mut key[0..20]);
|
||||
|
||||
let hash = &Sha1::digest(&key[..20]);
|
||||
key[..20].copy_from_slice(hash);
|
||||
|
|
|
@ -31,16 +31,16 @@ tokio = { version = "1", features = ["parking_lot", "rt", "rt-multi-thread", "sy
|
|||
zerocopy = "0.6"
|
||||
|
||||
# Backends
|
||||
alsa = { version = "0.6", optional = true }
|
||||
alsa = { version = "0.7", optional = true }
|
||||
portaudio-rs = { version = "0.3", optional = true }
|
||||
libpulse-binding = { version = "2", optional = true, default-features = false }
|
||||
libpulse-simple-binding = { version = "2", optional = true, default-features = false }
|
||||
jack = { version = "0.11", optional = true }
|
||||
sdl2 = { version = "0.35", optional = true }
|
||||
gstreamer = { version = "0.18", optional = true }
|
||||
gstreamer-app = { version = "0.18", optional = true }
|
||||
gstreamer-audio = { version = "0.18", optional = true }
|
||||
glib = { version = "0.15", optional = true }
|
||||
gstreamer = { version = "0.20", optional = true }
|
||||
gstreamer-app = { version = "0.20", optional = true }
|
||||
gstreamer-audio = { version = "0.20", optional = true }
|
||||
glib = { version = "0.17", optional = true }
|
||||
|
||||
# Rodio dependencies
|
||||
rodio = { version = "0.17.1", optional = true, default-features = false }
|
||||
|
@ -50,7 +50,7 @@ cpal = { version = "0.15.1", optional = true }
|
|||
symphonia = { version = "0.5", default-features = false, features = ["mp3", "ogg", "vorbis"] }
|
||||
|
||||
# Legacy Ogg container decoder for the passthrough decoder
|
||||
ogg = { version = "0.8", optional = true }
|
||||
ogg = { version = "0.9", optional = true }
|
||||
|
||||
# Dithering
|
||||
rand = { version = "0.8", features = ["small_rng"] }
|
||||
|
|
|
@ -48,7 +48,8 @@ impl Open for GstreamerSink {
|
|||
let gst_bytes = NUM_CHANNELS as usize * 2048 * sample_size;
|
||||
|
||||
let pipeline = gst::Pipeline::new(None);
|
||||
let appsrc = gst::ElementFactory::make("appsrc", None)
|
||||
let appsrc = gst::ElementFactory::make("appsrc")
|
||||
.build()
|
||||
.expect("Failed to create GStreamer appsrc element")
|
||||
.downcast::<gst_app::AppSrc>()
|
||||
.expect("couldn't cast AppSrc element at runtime!");
|
||||
|
|
|
@ -14,7 +14,7 @@ use crate::{
|
|||
MS_PER_PAGE, PAGES_PER_MS,
|
||||
};
|
||||
|
||||
fn get_header<T>(code: u8, rdr: &mut PacketReader<T>) -> DecoderResult<Box<[u8]>>
|
||||
fn get_header<T>(code: u8, rdr: &mut PacketReader<T>) -> DecoderResult<Vec<u8>>
|
||||
where
|
||||
T: Read + Seek,
|
||||
{
|
||||
|
@ -29,19 +29,19 @@ where
|
|||
return Err(DecoderError::PassthroughDecoder("Invalid Data".into()));
|
||||
}
|
||||
|
||||
Ok(pck.data.into_boxed_slice())
|
||||
Ok(pck.data)
|
||||
}
|
||||
|
||||
pub struct PassthroughDecoder<R: Read + Seek> {
|
||||
rdr: PacketReader<R>,
|
||||
wtr: PacketWriter<Vec<u8>>,
|
||||
wtr: PacketWriter<'static, Vec<u8>>,
|
||||
eos: bool,
|
||||
bos: bool,
|
||||
ofsgp_page: u64,
|
||||
stream_serial: u32,
|
||||
ident: Box<[u8]>,
|
||||
comment: Box<[u8]>,
|
||||
setup: Box<[u8]>,
|
||||
ident: Vec<u8>,
|
||||
comment: Vec<u8>,
|
||||
setup: Vec<u8>,
|
||||
}
|
||||
|
||||
impl<R: Read + Seek> PassthroughDecoder<R> {
|
||||
|
@ -98,7 +98,7 @@ impl<R: Read + Seek> AudioDecoder for PassthroughDecoder<R> {
|
|||
let absgp_page = pck.absgp_page() - self.ofsgp_page;
|
||||
self.wtr
|
||||
.write_packet(
|
||||
pck.data.into_boxed_slice(),
|
||||
pck.data,
|
||||
self.stream_serial,
|
||||
PacketWriteEndInfo::EndStream,
|
||||
absgp_page,
|
||||
|
@ -196,7 +196,7 @@ impl<R: Read + Seek> AudioDecoder for PassthroughDecoder<R> {
|
|||
|
||||
self.wtr
|
||||
.write_packet(
|
||||
pck.data.into_boxed_slice(),
|
||||
pck.data,
|
||||
self.stream_serial,
|
||||
inf,
|
||||
pckgp_page - self.ofsgp_page,
|
||||
|
|
|
@ -11,8 +11,8 @@ use symphonia::{
|
|||
units::Time,
|
||||
},
|
||||
default::{
|
||||
codecs::{Mp3Decoder, VorbisDecoder},
|
||||
formats::{Mp3Reader, OggReader},
|
||||
codecs::{MpaDecoder, VorbisDecoder},
|
||||
formats::{MpaReader, OggReader},
|
||||
},
|
||||
};
|
||||
|
||||
|
@ -48,7 +48,7 @@ impl SymphoniaDecoder {
|
|||
let format: Box<dyn FormatReader> = if AudioFiles::is_ogg_vorbis(file_format) {
|
||||
Box::new(OggReader::try_new(mss, &format_opts)?)
|
||||
} else if AudioFiles::is_mp3(file_format) {
|
||||
Box::new(Mp3Reader::try_new(mss, &format_opts)?)
|
||||
Box::new(MpaReader::try_new(mss, &format_opts)?)
|
||||
} else {
|
||||
return Err(DecoderError::SymphoniaDecoder(format!(
|
||||
"Unsupported format: {file_format:?}"
|
||||
|
@ -63,7 +63,7 @@ impl SymphoniaDecoder {
|
|||
let decoder: Box<dyn Decoder> = if AudioFiles::is_ogg_vorbis(file_format) {
|
||||
Box::new(VorbisDecoder::try_new(&track.codec_params, &decoder_opts)?)
|
||||
} else if AudioFiles::is_mp3(file_format) {
|
||||
Box::new(Mp3Decoder::try_new(&track.codec_params, &decoder_opts)?)
|
||||
Box::new(MpaDecoder::try_new(&track.codec_params, &decoder_opts)?)
|
||||
} else {
|
||||
return Err(DecoderError::SymphoniaDecoder(format!(
|
||||
"Unsupported decoder: {file_format:?}"
|
||||
|
|
|
@ -13,5 +13,4 @@ edition = "2021"
|
|||
protobuf = "3"
|
||||
|
||||
[build-dependencies]
|
||||
glob = "0.3"
|
||||
protobuf-codegen = "3"
|
||||
|
|
Loading…
Reference in a new issue