From ca36e4040d64422dd064f907f26deb1c5024f3c4 Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Mon, 16 Dec 2019 08:37:56 -0800 Subject: [PATCH 1/2] Move the `fuzz` directory into main workspace This'll help us track dependencies and head off issues like #721 --- Cargo.lock | 21 +++++++++++++++++++++ Cargo.toml | 1 + fuzz/Cargo.toml | 8 ++++---- 3 files changed, 26 insertions(+), 4 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 6d50b1e27a..6497401b08 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -922,6 +922,15 @@ version = "0.2.66" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d515b1f41455adea1313a4a2ac8a8a477634fbae63cc6100e3aebb207ce61558" +[[package]] +name = "libfuzzer-sys" +version = "0.1.0" +source = "git+https://github.com/rust-fuzz/libfuzzer-sys.git#0c4507533a79e85e1984f59765bdd35fbdaa7f1b" +dependencies = [ + "arbitrary", + "cc", +] + [[package]] name = "libloading" version = "0.5.2" @@ -2037,6 +2046,18 @@ dependencies = [ "zstd", ] +[[package]] +name = "wasmtime-fuzz" +version = "0.7.0" +dependencies = [ + "arbitrary", + "env_logger 0.7.1", + "libfuzzer-sys", + "log", + "wasmtime-fuzzing", + "wasmtime-jit", +] + [[package]] name = "wasmtime-fuzzing" version = "0.1.0" diff --git a/Cargo.toml b/Cargo.toml index f49eea6671..c7d6d111f2 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -53,6 +53,7 @@ members = [ "crates/fuzzing", "crates/misc/rust", "crates/misc/py", + "fuzz", ] [features] diff --git a/fuzz/Cargo.toml b/fuzz/Cargo.toml index 637c730c5f..7c0613627a 100644 --- a/fuzz/Cargo.toml +++ b/fuzz/Cargo.toml @@ -16,22 +16,22 @@ wasmtime-fuzzing = { path = "../crates/fuzzing", features = ["env_logger"] } wasmtime-jit = { path = "../crates/jit" } libfuzzer-sys = { git = "https://github.com/rust-fuzz/libfuzzer-sys.git" } -# Prevent this from interfering with workspaces -[workspace] -members = ["."] - [[bin]] name = "compile" path = "fuzz_targets/compile.rs" +test = false [[bin]] name = "instantiate" path = "fuzz_targets/instantiate.rs" +test = false [[bin]] name = "instantiate_translated" path = "fuzz_targets/instantiate_translated.rs" +test = false [[bin]] name = "api_calls" path = "fuzz_targets/api_calls.rs" +test = false From 89b1e913d57da9a53cf4e0bfaef9fcb01eaa0056 Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Mon, 16 Dec 2019 09:12:52 -0800 Subject: [PATCH 2/2] Check out submodules --- .github/workflows/main.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 7d07592d9d..e02bf790b7 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -69,6 +69,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v1 + with: + submodules: true - uses: actions/checkout@v1 with: repository: bytecodealliance/wasmtime-libfuzzer-corpus