Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minimize dependencies #523

Merged
merged 3 commits into from
Jun 30, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 7 additions & 14 deletions decoder/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,29 +12,22 @@ version = "0.2.2"
[dependencies]
defmt-parser = { path = "../parser", features = ["unstable"], version = "=0.2.2" }
byteorder = "1"
colored = "2.0.0"
leb128 = "0.2.4"
colored = "2.0"
leb128 = "0.2"
ryu = "1"


# logger
ansi_term = "0.12.1"
difference = "2.0.0"
log = { version = "0.4.14", features = ["std"] }
ansi_term = "0.12"
difference = "2.0"
log = { version = "0.4", features = ["std"] }

# elf2table
anyhow = "1.0"
gimli = "0.23"
gimli = { version = "0.24", default-features = false, features = ["read", "std"] }
object = { version = "0.25", default-features = false, features = ["read_core", "elf", "std"] }
serde = { version = "1", features = ["derive"] }
serde_json = "1"

# elf2table
[dependencies.object]
version = "0.23"
default-features = false
features = ["read_core", "elf", "std"]


[build-dependencies]
semver = "1.0"

Expand Down
4 changes: 2 additions & 2 deletions decoder/src/elf2table/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -212,8 +212,8 @@ pub fn get_locations(elf: &[u8], table: &Table) -> Result<Locations, anyhow::Err
};
let load_section_sup = |_| Ok(Cow::Borrowed(&[][..]));

let dwarf_cow =
gimli::Dwarf::<Cow<[u8]>>::load::<_, _, anyhow::Error>(&load_section, &load_section_sup)?;
let mut dwarf_cow = gimli::Dwarf::<Cow<[u8]>>::load::<_, anyhow::Error>(&load_section)?;
dwarf_cow.load_sup::<_, anyhow::Error>(&load_section_sup)?;

let borrow_section: &dyn for<'a> Fn(
&'a Cow<[u8]>,
Expand Down