From c135b01e301577f5a135ea96cf75fc8e8946f23f Mon Sep 17 00:00:00 2001 From: koushiro Date: Sun, 26 Nov 2023 21:28:46 +0800 Subject: [PATCH] chore: remove useless deps and update edition to 2021 --- Cargo.toml | 28 +--------------------------- interpreter/Cargo.toml | 11 ++++------- jsontests/Cargo.toml | 12 ++++++------ precompile/Cargo.toml | 18 +++++++++--------- tracer/Cargo.toml | 2 +- 5 files changed, 21 insertions(+), 50 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 1b08ca45a..2a2134771 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -7,60 +7,34 @@ keywords = ["no_std", "ethereum", "evm"] [package] name = "evm" version = "1.0.0-dev" +edition = "2021" license = { workspace = true } authors = { workspace = true } repository = { workspace = true } keywords = { workspace = true } description = "Ethereum Virtual Machine" -edition = "2018" [dependencies] -auto_impl = "1.0" -ethereum = { version = "0.14", default-features = false } -log = { version = "0.4", default-features = false } primitive-types = { version = "0.12", default-features = false, features = ["rlp"] } -rlp = { version = "0.5", default-features = false } sha3 = { version = "0.10", default-features = false } -# Optional dependencies -environmental = { version = "1.1.2", default-features = false, optional = true } -scale-codec = { package = "parity-scale-codec", version = "3.2", default-features = false, features = ["derive"], optional = true } -scale-info = { version = "2.3", default-features = false, features = ["derive"], optional = true } -serde = { version = "1.0", default-features = false, features = ["derive"], optional = true } - evm-interpreter = { version = "1.0.0-dev", path = "interpreter", default-features = false } -[dev-dependencies] -criterion = "0.4" -hex = "0.4" - [features] default = ["std"] std = [ - "ethereum/std", - "log/std", "primitive-types/std", - "rlp/std", "sha3/std", - "environmental/std", - "scale-codec/std", - "scale-info/std", - "serde/std", "evm-interpreter/std", ] with-codec = [ - "scale-codec", - "scale-info", "primitive-types/codec", "primitive-types/scale-info", - "ethereum/with-codec", "evm-interpreter/with-codec", ] with-serde = [ - "serde", "primitive-types/impl-serde", "evm-interpreter/with-serde", - "ethereum/with-serde", ] [workspace] diff --git a/interpreter/Cargo.toml b/interpreter/Cargo.toml index 3416d5f22..54375c80d 100644 --- a/interpreter/Cargo.toml +++ b/interpreter/Cargo.toml @@ -1,23 +1,20 @@ [package] name = "evm-interpreter" version = "1.0.0-dev" +edition = "2021" license = { workspace = true } authors = { workspace = true } repository = { workspace = true } keywords = { workspace = true } description = "The interpreter part of Ethereum Virtual Machine" -edition = "2018" [dependencies] -log = { version = "0.4", optional = true } primitive-types = { version = "0.12", default-features = false, features = ["rlp"] } +rlp = { version = "0.5", default-features = false } scale-codec = { package = "parity-scale-codec", version = "3.2", default-features = false, features = ["derive", "full"], optional = true } scale-info = { version = "2.3", default-features = false, features = ["derive"], optional = true } serde = { version = "1.0", default-features = false, features = ["derive"], optional = true } -bytes = { version = "1.5", default-features = false } -auto_impl = "1.0" sha3 = { version = "0.10", default-features = false } -rlp = { version = "0.5", default-features = false } [dev-dependencies] hex = "0.4" @@ -26,11 +23,11 @@ hex = "0.4" default = ["std"] std = [ "primitive-types/std", + "rlp/std", "serde/std", "scale-codec/std", "scale-info/std", - "bytes/std", - "rlp/std", + "sha3/std", ] with-codec = [ "scale-codec", diff --git a/jsontests/Cargo.toml b/jsontests/Cargo.toml index aa2eba871..95c902f90 100644 --- a/jsontests/Cargo.toml +++ b/jsontests/Cargo.toml @@ -8,14 +8,14 @@ repository = { workspace = true } keywords = { workspace = true } [dependencies] +clap = { version = "4", features = ["derive"] } +ethereum = "0.15.0" evm = { path = ".." } evm-precompile = { path = "../precompile" } -serde = { version = "1", features = ["derive"] } -serde_json = "1" -primitive-types = { version = "0.12", features = ["rlp", "serde"] } -clap = { version = "4", features = ["derive"] } -thiserror = "1" hex = { version = "0.4", features = ["serde"] } -ethereum = "0.15.0" +primitive-types = { version = "0.12", features = ["rlp", "serde"] } rlp = "0.5" +serde = { version = "1", features = ["derive"] } +serde_json = "1" sha3 = "0.10" +thiserror = "1" diff --git a/precompile/Cargo.toml b/precompile/Cargo.toml index 8bffc1256..f412a35b1 100644 --- a/precompile/Cargo.toml +++ b/precompile/Cargo.toml @@ -9,23 +9,23 @@ keywords = { workspace = true } description = "Standard EVM precompiles." [dependencies] +bn = { package = "substrate-bn", version = "0.6", default-features = false } evm = { path = "..", default-features = false } -primitive-types = { version = "0.12", default-features = false, features = ["rlp"] } k256 = { version = "0.13", features = ["ecdsa"], default-features = false } -sha3 = { version = "0.10", default-features = false } -sha2 = { version = "0.10", default-features = false } -ripemd = { version = "0.1", default-features = false } num = { version = "0.4", default-features = false, features = ["alloc"] } -bn = { package = "substrate-bn", version = "0.6", default-features = false } +primitive-types = { version = "0.12", default-features = false, features = ["rlp"] } +ripemd = { version = "0.1", default-features = false } +sha2 = { version = "0.10", default-features = false } +sha3 = { version = "0.10", default-features = false } [features] default = ["std"] std = [ "evm/std", - "primitive-types/std", - "sha3/std", "k256/std", - "sha2/std", - "ripemd/std", "num/std", + "primitive-types/std", + "ripemd/std", + "sha2/std", + "sha3/std", ] diff --git a/tracer/Cargo.toml b/tracer/Cargo.toml index 90575e1b6..a5c1ddb87 100644 --- a/tracer/Cargo.toml +++ b/tracer/Cargo.toml @@ -1,11 +1,11 @@ [package] name = "evm-tracer" version = "0.0.0-dev" +edition = "2021" license = { workspace = true } authors = { workspace = true } repository = { workspace = true } keywords = { workspace = true } -edition = "2021" [dependencies] evm = { path = ".." }