diff options
author | 2022-06-05 20:31:04 -0500 | |
---|---|---|
committer | 2022-06-06 11:31:04 +1000 | |
commit | ae83c88a5430859378c420afacd1d43a768831af (patch) | |
tree | b8e5f3ab3d1e3278186a028f80651115ef8a6dc8 /infra/base-images | |
parent | f99ec824ca3bdd6117471f5a1cb3acc2c71f68aa (diff) |
Upgrade infra and projects to go1.18 (#7791)
* Replace go get with go install in the scritp
* Remove go get from projects
* Replace gotip with go
* Fix CI
* Add missing dependency for cryptofuzz
Diffstat (limited to 'infra/base-images')
-rwxr-xr-x | infra/base-images/base-builder/compile_native_go_fuzzer | 2 | ||||
-rwxr-xr-x | infra/base-images/base-builder/install_go.sh | 11 |
2 files changed, 5 insertions, 8 deletions
diff --git a/infra/base-images/base-builder/compile_native_go_fuzzer b/infra/base-images/base-builder/compile_native_go_fuzzer index 41721f34..eee208f4 100755 --- a/infra/base-images/base-builder/compile_native_go_fuzzer +++ b/infra/base-images/base-builder/compile_native_go_fuzzer @@ -58,7 +58,7 @@ function build_native_go_fuzzer() { abspath_repo=`go list -m $tags -f {{.Dir}} $fuzzed_repo || go list $tags -f {{.Dir}} $fuzzed_repo` # give equivalence to absolute paths in another file, as go test -cover uses golangish pkg.Dir echo "s=$fuzzed_repo"="$abspath_repo"= > $OUT/$fuzzer.gocovpath - gotip test -run Test${function}Corpus -v $tags -coverpkg $fuzzed_repo/... -c -o $OUT/$fuzzer $path + go test -run Test${function}Corpus -v $tags -coverpkg $fuzzed_repo/... -c -o $OUT/$fuzzer $path rm ./"${function,,}"_test.go else diff --git a/infra/base-images/base-builder/install_go.sh b/infra/base-images/base-builder/install_go.sh index 101f785b..2b58598d 100755 --- a/infra/base-images/base-builder/install_go.sh +++ b/infra/base-images/base-builder/install_go.sh @@ -18,24 +18,21 @@ cd /tmp curl -O https://storage.googleapis.com/golang/getgo/installer_linux chmod +x ./installer_linux -SHELL="bash" ./installer_linux -version=1.17 +SHELL="bash" ./installer_linux -version=1.18 rm -rf ./installer_linux echo 'Set "GOPATH=/root/go"' echo 'Set "PATH=$PATH:/root/.go/bin:$GOPATH/bin"' -go get -u github.com/mdempsky/go114-fuzz-build +go install github.com/mdempsky/go114-fuzz-build@latest ln -s $GOPATH/bin/go114-fuzz-build $GOPATH/bin/go-fuzz -go install golang.org/dl/gotip@latest \ - && gotip download - cd /tmp git clone https://github.com/AdamKorcz/go-118-fuzz-build cd go-118-fuzz-build -gotip build +go build mv go-118-fuzz-build $GOPATH/bin/ cd addimport -gotip build +go build mv addimport $GOPATH/bin/ |