Skip to content

Commit

Permalink
[move] Use workspace dependencies for third-party/move (#15461)
Browse files Browse the repository at this point in the history
  • Loading branch information
georgemitenkov authored and danielxiangzl committed Dec 12, 2024
1 parent b4ef3d6 commit 9f8ab9e
Show file tree
Hide file tree
Showing 63 changed files with 360 additions and 485 deletions.
22 changes: 11 additions & 11 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

22 changes: 12 additions & 10 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -623,6 +623,7 @@ http = "0.2.9"
httpmock = "0.6.8"
hyper = { version = "0.14.18", features = ["full"] }
hyper-tls = "0.5.0"
im = "15.0.0"
image = "0.24.5"
indexmap = "1.9.3"
include_dir = { version = "0.7.2", features = ["glob"] }
Expand Down Expand Up @@ -840,8 +841,12 @@ z3tracer = "0.8.0"
# MOVE DEPENDENCIES
move-abigen = { path = "third_party/move/move-prover/move-abigen" }
move-binary-format = { path = "third_party/move/move-binary-format" }
move-borrow-graph = { path = "third_party/move/move-borrow-graph" }
move-bytecode-source-map = { path = "third_party/move/move-ir-compiler/move-bytecode-source-map" }
move-bytecode-spec = { path = "third_party/move/move-bytecode-spec" }
move-bytecode-verifier = { path = "third_party/move/move-bytecode-verifier" }
move-bytecode-verifier-invalid-mutations = { path = "third_party/move/move-bytecode-verifier/invalid-mutations" }
move-bytecode-viewer = { path = "third_party/move/tools/move-bytecode-viewer" }
move-bytecode-utils = { path = "third_party/move/tools/move-bytecode-utils" }
move-cli = { path = "third_party/move/tools/move-cli" }
move-command-line-common = { path = "third_party/move/move-command-line-common" }
Expand All @@ -852,32 +857,29 @@ move-core-types = { path = "third_party/move/move-core/types" }
move-decompiler = { path = "third_party/move/tools/move-decompiler" }
move-docgen = { path = "third_party/move/move-prover/move-docgen" }
move-disassembler = { path = "third_party/move/tools/move-disassembler" }
move-errmapgen = { path = "third_party/move/move-prover/move-errmapgen" }
move-ir-types = { path = "third_party/move/move-ir/types" }
move-ir-compiler = { path = "third_party/move/move-ir-compiler" }
move-ir-to-bytecode = { path = "third_party/move/move-ir-compiler/move-ir-to-bytecode" }
move-linter = { path = "third_party/move/tools/move-linter" }
move-bytecode-source-map = { path = "third_party/move/move-ir-compiler/move-bytecode-source-map" }
move-model = { path = "third_party/move/move-model" }
move-package = { path = "third_party/move/tools/move-package" }
move-prover = { path = "third_party/move/move-prover" }
move-prover-boogie-backend = { path = "third_party/move/move-prover/boogie-backend" }
move-prover-bytecode-pipeline = { path = "third_party/move/move-prover/bytecode-pipeline" }
move-stackless-bytecode = { path = "third_party/move/move-model/bytecode" }
move-stackless-bytecode-test-utils = { path = "third_party/move/move-model/bytecode-test-utils" }
move-prover-test-utils = { path = "third_party/move/move-prover/test-utils" }
aptos-move-stdlib = { path = "aptos-move/framework/move-stdlib" }
aptos-table-natives = { path = "aptos-move/framework/table-natives" }
move-prover-test-utils = { path = "third_party/move/move-prover/test-utils" }
move-resource-viewer = { path = "third_party/move/tools/move-resource-viewer" }
move-stackless-bytecode = { path = "third_party/move/move-model/bytecode" }
move-stackless-bytecode-test-utils = { path = "third_party/move/move-model/bytecode-test-utils" }
move-symbol-pool = { path = "third_party/move/move-symbol-pool" }
move-table-extension = { path = "third_party/move/extensions/move-table-extension" }
move-transactional-test-runner = { path = "third_party/move/testing-infra/transactional-test-runner" }
move-unit-test = { path = "third_party/move/tools/move-unit-test", features = [
"table-extension",
] }
move-unit-test = { path = "third_party/move/tools/move-unit-test", features = ["table-extension"] }
move-vm-metrics = { path = "third_party/move/move-vm/metrics" }
move-vm-runtime = { path = "third_party/move/move-vm/runtime" }
move-vm-test-utils = { path = "third_party/move/move-vm/test-utils", features = [
"table-extension",
] }
move-vm-test-utils = { path = "third_party/move/move-vm/test-utils", features = ["table-extension"] }
move-vm-types = { path = "third_party/move/move-vm/types" }

[profile.release]
Expand Down
22 changes: 11 additions & 11 deletions aptos-move/framework/move-stdlib/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,20 @@ aptos-gas-schedule = { workspace = true }
aptos-native-interface = { workspace = true }
aptos-types = { workspace = true }
bcs = { workspace = true }
move-core-types = { path = "../../../third_party/move/move-core/types" }
move-vm-runtime = { path = "../../../third_party/move/move-vm/runtime" }
move-vm-types = { path = "../../../third_party/move/move-vm/types" }
sha2 = "0.9.3"
sha3 = "0.9.1"
smallvec = "1.6.1"
move-core-types = { workspace = true }
move-vm-runtime = { workspace = true }
move-vm-types = { workspace = true }
sha2 = { workspace = true }
sha3 = { workspace = true }
smallvec = { workspace = true }

[dev-dependencies]
dir-diff = "0.3.2"
file_diff = "1.0.0"
move-cli = { path = "../../../third_party/move/tools/move-cli" }
move-package = { path = "../../../third_party/move/tools/move-package" }
move-unit-test = { path = "../../../third_party/move/tools/move-unit-test" }
tempfile = "3.2.0"
move-cli = { workspace = true }
move-package = { workspace = true }
move-unit-test = { workspace = true }
tempfile = { workspace = true }

[features]
testing = []
testing = []
6 changes: 3 additions & 3 deletions testsuite/fuzzer/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ aptos-types = { workspace = true }
arbitrary = { workspace = true }
base64 = "0.21.7"
bcs = { workspace = true }
clap = "4.5.20"
csv = "1.3.0"
clap = { workspace = true }
csv = { workspace = true }
dearbitrary = { workspace = true }
hex = "0.4.3"
hex = { workspace = true }
move-binary-format = { workspace = true, features = ["fuzzing"] }
move-core-types = { workspace = true, features = ["fuzzing"] }
sha2 = { workspace = true }
5 changes: 1 addition & 4 deletions third_party/move/evm/exec-utils/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,7 @@ anyhow = { workspace = true }
evm = { workspace = true }
evm-runtime = { workspace = true }
hex = { workspace = true }
move-command-line-common = { workspace = true }
primitive-types = { workspace = true }
# external dependencies
sha3 = { workspace = true }
tempfile = { workspace = true }

# move dependencies
move-command-line-common = { path = "../../move-command-line-common" }
17 changes: 7 additions & 10 deletions third_party/move/evm/move-to-yul/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,6 @@ edition = "2021"
license = "Apache-2.0"

[dependencies]
move-command-line-common = { path = "../../move-command-line-common" }
move-compiler = { path = "../../move-compiler" }
move-core-types = { path = "../../move-core/types" }
move-ethereum-abi = { path = "../move-ethereum-abi" }
move-model = { path = "../../move-model" }
# move dependencies
move-stackless-bytecode = { path = "../../move-model/bytecode" }

# external dependencies
anyhow = { workspace = true }
atty = { workspace = true }
clap = { workspace = true }
Expand All @@ -26,6 +17,12 @@ ethnum = { workspace = true }
evm = { workspace = true }
itertools = { workspace = true }
maplit = { workspace = true }
move-command-line-common = { workspace = true }
move-compiler = { workspace = true }
move-core-types = { workspace = true }
move-ethereum-abi = { path = "../move-ethereum-abi" }
move-model = { workspace = true }
move-stackless-bytecode = { workspace = true }
once_cell = { workspace = true }
primitive-types = { workspace = true }
regex = { workspace = true }
Expand All @@ -36,7 +33,7 @@ sha3 = { workspace = true }
datatest-stable = { workspace = true }
evm = { workspace = true }
evm-exec-utils = { path = "../exec-utils" }
move-prover-test-utils = { path = "../../move-prover/test-utils" }
move-prover-test-utils = { workspace = true }
move-stdlib = { path = "../../move-stdlib" }
tempfile = { workspace = true }
walkdir = { workspace = true }
Expand Down
14 changes: 7 additions & 7 deletions third_party/move/extensions/move-table-extension/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,16 @@ publish = false
[dependencies]
better_any = { workspace = true }
bytes = { workspace = true }
move-binary-format = { path = "../../move-binary-format" }
move-core-types = { path = "../../move-core/types" }
move-vm-runtime = { path = "../../move-vm/runtime" }
move-vm-types = { path = "../../move-vm/types" }
move-binary-format = { workspace = true }
move-core-types = { workspace = true }
move-vm-runtime = { workspace = true }
move-vm-types = { workspace = true }
sha3 = { workspace = true }
smallvec = { workspace = true }

[dev-dependencies]
move-cli = { path = "../../tools/move-cli" }
move-package = { path = "../../tools/move-package" }
move-cli = { workspace = true }
move-package = { workspace = true }
move-stdlib = { path = "../../move-stdlib", features = ["testing"] }
move-unit-test = { path = "../../tools/move-unit-test", features = ["table-extension"] }
move-unit-test = { workspace = true, features = ["table-extension"] }
tempfile = { workspace = true }
4 changes: 2 additions & 2 deletions third_party/move/move-binary-format/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,15 @@ backtrace = { workspace = true }
dearbitrary = { workspace = true, optional = true, features = ["derive"] }
indexmap = { workspace = true }
move-bytecode-spec = { workspace = true }
move-core-types = { path = "../move-core/types" }
move-core-types = { workspace = true }
proptest = { workspace = true, optional = true }
proptest-derive = { workspace = true, optional = true }
ref-cast = { workspace = true }
serde = { workspace = true }
variant_count = { workspace = true }

[dev-dependencies]
move-core-types = { path = "../move-core/types", features = ["fuzzing"] }
move-core-types = { workspace = true, features = ["fuzzing"] }
proptest = { workspace = true }
proptest-derive = { workspace = true }
serde_json = { workspace = true }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ publish = false
edition = "2021"

[dev-dependencies]
move-binary-format = { path = "../", features = ["fuzzing"] }
move-core-types = { path = "../../move-core/types" }
move-binary-format = { workspace = true, features = ["fuzzing"] }
move-core-types = { workspace = true }
proptest = { workspace = true }
proptest-derive = { workspace = true }

Expand Down
12 changes: 4 additions & 8 deletions third_party/move/move-bytecode-verifier/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,13 @@ edition = "2021"

[dependencies]
fail = { workspace = true }
move-binary-format = { path = "../move-binary-format" }
move-binary-format = { workspace = true }
move-borrow-graph = { workspace = true }
move-core-types = { workspace = true }
petgraph = { workspace = true }
serde = { workspace = true }
typed-arena = { workspace = true }

move-borrow-graph = { path = "../move-borrow-graph" }
move-core-types = { path = "../move-core/types" }

[dev-dependencies]
hex-literal = { workspace = true }
invalid-mutations = { path = "invalid-mutations" }

[features]
default = []
move-bytecode-verifier-invalid-mutations = { workspace = true }
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ edition = "2021"
[dev-dependencies]
fail = { workspace = true, features = ['failpoints'] }
hex = { workspace = true }
invalid-mutations = { path = "../invalid-mutations" }
move-binary-format = { path = "../../move-binary-format", features = ["fuzzing"] }
move-bytecode-verifier = { path = "../" }
move-core-types = { path = "../../move-core/types" }
move-binary-format = { workspace = true, features = ["fuzzing"] }
move-bytecode-verifier = { workspace = true }
move-bytecode-verifier-invalid-mutations = { workspace = true }
move-core-types = { workspace = true }
petgraph = { workspace = true }
proptest = { workspace = true }

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@
// Copyright (c) The Move Contributors
// SPDX-License-Identifier: Apache-2.0

use invalid_mutations::bounds::{
ApplyCodeUnitBoundsContext, ApplyOutOfBoundsContext, CodeUnitBoundsMutation,
OutOfBoundsMutation,
};
use move_binary_format::{
check_bounds::BoundsChecker, file_format::*, file_format_common,
proptest_types::CompiledModuleStrategyGen,
};
use move_bytecode_verifier_invalid_mutations::bounds::{
ApplyCodeUnitBoundsContext, ApplyOutOfBoundsContext, CodeUnitBoundsMutation,
OutOfBoundsMutation,
};
use move_core_types::{
account_address::AccountAddress, identifier::Identifier, vm_status::StatusCode,
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
// Copyright (c) The Move Contributors
// SPDX-License-Identifier: Apache-2.0

use invalid_mutations::signature::{FieldRefMutation, SignatureRefMutation};
use move_binary_format::file_format::{
Bytecode::*, CompiledModule, SignatureToken::*, Visibility::Public, *,
};
use move_bytecode_verifier::{
verify_module, verify_module_with_config_for_test, SignatureChecker, VerifierConfig,
};
use move_bytecode_verifier_invalid_mutations::signature::{FieldRefMutation, SignatureRefMutation};
use move_core_types::{
account_address::AccountAddress, identifier::Identifier, vm_status::StatusCode,
};
Expand Down
9 changes: 3 additions & 6 deletions third_party/move/move-bytecode-verifier/fuzz/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,9 @@ cargo-fuzz = true
[dependencies]
arbitrary = { workspace = true }
libfuzzer-sys = { workspace = true }
move-binary-format = { path = "../../move-binary-format", features = ["fuzzing"] }
move-bytecode-verifier = { path = "../" }
move-core-types = { path = "../../move-core/types", features = ["fuzzing"] }
# Prevent this from interfering with workspaces
#[workspace]
#members = ["."]
move-binary-format = { workspace = true, features = ["fuzzing"] }
move-bytecode-verifier = { workspace = true }
move-core-types = { workspace = true, features = ["fuzzing"] }

[[bin]]
name = "code_unit"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[package]
name = "invalid-mutations"
name = "move-bytecode-verifier-invalid-mutations"
version = "0.1.0"
edition = "2021"
authors = ["Diem Association <[email protected]>"]
Expand All @@ -10,9 +10,6 @@ license = "Apache-2.0"
publish = false

[dependencies]
move-binary-format = { path = "../../move-binary-format" }
move-core-types = { path = "../../move-core/types" }
move-binary-format = { workspace = true }
move-core-types = { workspace = true }
proptest = { workspace = true }

[features]
default = []
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ license = "Apache-2.0"

[dev-dependencies]
datatest-stable = { workspace = true }
move-transactional-test-runner = { path = "../../testing-infra/transactional-test-runner" }
move-transactional-test-runner = { workspace = true }

[[test]]
name = "tests"
Expand Down
3 changes: 1 addition & 2 deletions third_party/move/move-command-line-common/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,9 @@ anyhow = { workspace = true }
difference = { workspace = true }
dirs-next = { workspace = true }
hex = { workspace = true }
move-core-types = { workspace = true }
num-bigint = { workspace = true }
once_cell = { workspace = true }
serde = { workspace = true, features = ["derive"] }
sha2 = { workspace = true }
walkdir = { workspace = true }

move-core-types = { path = "../move-core/types" }
Loading

0 comments on commit 9f8ab9e

Please sign in to comment.