|
15 | 15 | # |
16 | 16 | ################################################################################ |
17 | 17 |
|
18 | | -# making sure we got these compiled with our go version |
19 | | -go install github.com/mdempsky/go114-fuzz-build@latest |
20 | | -rm -f $GOPATH/bin/go-fuzz |
21 | | -ln -s $GOPATH/bin/go114-fuzz-build $GOPATH/bin/go-fuzz |
22 | | -go install github.com/AdamKorcz/go-118-fuzz-build@main |
23 | | - |
24 | | -make |
25 | | - |
26 | | -# Not all fuzzers can be compiled with --sanitizer=coverage. |
27 | | -# The specific issue is that gofuzz.NewFromGofuzz is not supported when compiling with coverage. |
28 | | -# The current status of the coverage build is that we do not break it for the fuzzers that cannot be compiled. |
29 | | -#The reason that we don't break the build script is to create coverage reports for the fuzzers that compile. |
30 | | -if [[ $SANITIZER = *coverage* ]]; then |
31 | | - compile_go_fuzzer github.com/filecoin-project/lotus/chain/types FuzzMessage fuzz_message gofuzz |
32 | | - mkdir fuzzing |
33 | | - cp ../fuzzing-lotus/fuzz/fuzz.go fuzzing/ |
34 | | - compile_go_fuzzer github.com/filecoin-project/lotus/fuzzing FuzzBlockMsg fuzz_block_msg || true |
35 | | - compile_go_fuzzer github.com/filecoin-project/lotus/fuzzing FuzzBlockMsgStructural fuzz_block_msg_structural || true |
36 | | - compile_go_fuzzer github.com/filecoin-project/lotus/fuzzing FuzzBlockHeader fuzz_block_header || true |
37 | | - compile_go_fuzzer github.com/filecoin-project/lotus/fuzzing FuzzNodesForHeight fuzz_nodes_for_height || true |
38 | | - exit 0 |
39 | | -fi |
40 | | - |
41 | | -compile_go_fuzzer ./chain/types FuzzMessage fuzz_message gofuzz |
42 | | - |
| 18 | +git submodule init |
| 19 | +git submodule update |
| 20 | +compile_go_fuzzer github.com/filecoin-project/lotus/chain/types FuzzMessage fuzz_message gofuzz |
43 | 21 |
|
44 | 22 | # Fuzzers from fuzzing-lotus |
45 | 23 | cd ../fuzzing-lotus/fuzz |
46 | 24 | rm -Rf libfuzzer |
47 | 25 | go mod init github.com/filecoin-project/fuzzing-lotus/fuzz |
| 26 | +go mod tidy |
48 | 27 |
|
49 | 28 | compile_go_fuzzer github.com/filecoin-project/fuzzing-lotus/fuzz FuzzBlockMsg fuzz_block_msg |
50 | 29 | compile_go_fuzzer github.com/filecoin-project/fuzzing-lotus/fuzz FuzzBlockMsgStructural fuzz_block_msg_structural |
51 | 30 | compile_go_fuzzer github.com/filecoin-project/fuzzing-lotus/fuzz FuzzBlockHeader fuzz_block_header |
52 | 31 | compile_go_fuzzer github.com/filecoin-project/fuzzing-lotus/fuzz FuzzNodesForHeight fuzz_nodes_for_height |
53 | | -exit 0 |
0 commit comments