From c98737278bde033fb1afdb7ef3d6f88650b7d45b Mon Sep 17 00:00:00 2001 From: AdamKorcz <44787359+AdamKorcz@users.noreply.github.com> Date: Mon, 5 Sep 2022 12:00:06 +0100 Subject: [PATCH] golang: clone in Dockerfile instead of build.sh (#8411) Signed-off-by: AdamKorcz Signed-off-by: AdamKorcz --- projects/golang/Dockerfile | 2 ++ projects/golang/build.sh | 6 ++---- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/projects/golang/Dockerfile b/projects/golang/Dockerfile index 0f0db2243..f013463b7 100644 --- a/projects/golang/Dockerfile +++ b/projects/golang/Dockerfile @@ -21,6 +21,8 @@ RUN git clone --depth 1 https://github.com/golang/go RUN git clone --depth 1 https://github.com/golang/net RUN git clone --depth 1 https://github.com/golang/image RUN git clone --depth 1 https://github.com/golang/crypto +RUN git clone --depth 1 https://github.com/golang/text +RUN git clone --depth 1 https://github.com/AdamKorcz/instrumentation COPY build.sh text_fuzzer.go \ math_big_fuzzer.go \ fuzz_tar_reader.go \ diff --git a/projects/golang/build.sh b/projects/golang/build.sh index 34c7d1260..3b16ba8e9 100755 --- a/projects/golang/build.sh +++ b/projects/golang/build.sh @@ -18,8 +18,7 @@ rm -r parser mkdir math && cp $SRC/math_big_fuzzer.go ./math/ -git clone https://github.com/golang/text $SRC/text -cd $SRC/text/ +cd $SRC/text cp $SRC/unicode_fuzzer.go ./encoding/unicode/ find . -name "*_test.go" ! -name 'fuzz_test.go' -type f -exec rm -f {} + compile_go_fuzzer golang.org/x/text/encoding/unicode FuzzUnicodeTransform fuzz_unicode_transform @@ -90,8 +89,7 @@ go get github.com/AdamKorcz/go-118-fuzz-build/testingtypes go get github.com/AdamKorcz/go-118-fuzz-build/utils compile_native_go_fuzzer tarPackage FuzzReader fuzz_std_lib_tar_reader -cd $SRC && git clone https://github.com/AdamKorcz/instrumentation -cd instrumentation +cd $SRC/instrumentation go run main.go $SRC/go/src/archive/tar cp $SRC/h2c_fuzzer.go $SRC/net/http2/h2c/