Skip to content

Commit

Permalink
build: remove go-fuzz dependency and references
Browse files Browse the repository at this point in the history
We don't need go-fuzz now that we use native fuzzing.
  • Loading branch information
morehouse committed Nov 11, 2022
1 parent 25a7bb8 commit beb4d8c
Show file tree
Hide file tree
Showing 8 changed files with 3 additions and 31 deletions.
6 changes: 0 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,6 @@ cmd/lncli/lncli
mobile/build
mobile/*_generated.go

# Files created for fuzzing.
fuzz/**/*-fuzz.zip
fuzz/**/corpus
fuzz/**/crashers
fuzz/**/suppressions

# vim
*.swp

Expand Down
16 changes: 2 additions & 14 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -82,18 +82,6 @@ $(GOIMPORTS_BIN):
@$(call print, "Installing goimports.")
cd $(TOOLS_DIR); go install -trimpath $(GOIMPORTS_PKG)

$(GOFUZZ_BIN):
@$(call print, "Installing go-fuzz.")
cd $(TOOLS_DIR); go install -trimpath $(GOFUZZ_PKG)

$(GOFUZZ_BUILD_BIN):
@$(call print, "Installing go-fuzz-build.")
cd $(TOOLS_DIR); go install -trimpath $(GOFUZZ_BUILD_PKG)

$(GOFUZZ_DEP_BIN):
@$(call print, "Installing go-fuzz-dep.")
cd $(TOOLS_DIR); go install -trimpath $(GOFUZZ_DEP_PKG)

# ============
# INSTALLATION
# ============
Expand Down Expand Up @@ -228,9 +216,9 @@ flakehunter-parallel:
# FUZZING
# =============

fuzz: $(GOFUZZ_BIN)
fuzz:
@$(call print, "Fuzzing packages '$(FUZZPKG)'.")
scripts/fuzz.sh run "$(FUZZPKG)" "$(FUZZ_TEST_RUN_TIME)" "$(FUZZ_NUM_PROCESSES)"
scripts/fuzz.sh run "$(FUZZPKG)" "$(FUZZ_TEST_RUN_TIME)" "$(FUZZ_NUM_PROCESSES)"

# =========
# UTILITIES
Expand Down
3 changes: 1 addition & 2 deletions build/dependencies.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,12 @@

package build

// This file is a workaround to make sure go mod keeps around the btcd and fuzz
// This file is a workaround to make sure go mod keeps around the btcd
// dependencies in the go.sum file that we only use during certain tasks (such
// as integration tests or fuzzing) or only for certain operating systems. For
// example, the specific btcd import makes sure the indirect dependency
// github.com/btcsuite/winsvc is kept in the go.sum file. Because of the build
// tag, this dependency never ends up in the final lnd binary.
import (
_ "github.com/btcsuite/btcd"
_ "github.com/dvyukov/go-fuzz/go-fuzz-dep"
)
1 change: 0 additions & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ require (
github.com/btcsuite/btcwallet/wtxmgr v1.5.0
github.com/coreos/go-systemd v0.0.0-20190719114852-fd7a80b32e1f
github.com/davecgh/go-spew v1.1.1
github.com/dvyukov/go-fuzz v0.0.0-20210602112143-b1f3d6f4ef4e
github.com/go-errors/errors v1.0.1
github.com/golang/protobuf v1.5.2
github.com/gorilla/websocket v1.4.2
Expand Down
2 changes: 0 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,6 @@ github.com/dsnet/compress v0.0.1/go.mod h1:Aw8dCMJ7RioblQeTqt88akK31OvO8Dhf5Jflh
github.com/dsnet/golib v0.0.0-20171103203638-1ea166775780/go.mod h1:Lj+Z9rebOhdfkVLjJ8T6VcRQv3SXugXy999NBtR9aFY=
github.com/dustin/go-humanize v1.0.0 h1:VSnTsYCnlFHaM2/igO1h6X3HA71jcobQuxemgkq4zYo=
github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk=
github.com/dvyukov/go-fuzz v0.0.0-20210602112143-b1f3d6f4ef4e h1:qTP1telKJHlToHlwPQNmVg4yfMDMHe4Z3SYmzkrvA2M=
github.com/dvyukov/go-fuzz v0.0.0-20210602112143-b1f3d6f4ef4e/go.mod h1:11Gm+ccJnvAhCNLlf5+cS9KjtbaD5I5zaZpFMsTHWTw=
github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4=
github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4=
github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98=
Expand Down
1 change: 0 additions & 1 deletion tools/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ go 1.16

require (
github.com/btcsuite/btcd v0.23.1
github.com/dvyukov/go-fuzz v0.0.0-20210602112143-b1f3d6f4ef4e
github.com/elazarl/go-bindata-assetfs v1.0.1 // indirect
github.com/golangci/golangci-lint v1.46.2
github.com/ory/go-acc v0.2.6
Expand Down
2 changes: 0 additions & 2 deletions tools/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -224,8 +224,6 @@ github.com/dgryski/go-farm v0.0.0-20190423205320-6a90982ecee2/go.mod h1:SqUrOPUn
github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no=
github.com/dustin/go-humanize v0.0.0-20171111073723-bb3d318650d4/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk=
github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk=
github.com/dvyukov/go-fuzz v0.0.0-20210602112143-b1f3d6f4ef4e h1:qTP1telKJHlToHlwPQNmVg4yfMDMHe4Z3SYmzkrvA2M=
github.com/dvyukov/go-fuzz v0.0.0-20210602112143-b1f3d6f4ef4e/go.mod h1:11Gm+ccJnvAhCNLlf5+cS9KjtbaD5I5zaZpFMsTHWTw=
github.com/elazarl/go-bindata-assetfs v1.0.1 h1:m0kkaHRKEu7tUIUFVwhGGGYClXvyl4RE03qmvRTNfbw=
github.com/elazarl/go-bindata-assetfs v1.0.1/go.mod h1:v+YaWX3bdea5J/mo8dSETolEo7R71Vk1u8bnjau5yw4=
github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4=
Expand Down
3 changes: 0 additions & 3 deletions tools/tools.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,6 @@ package lnd
// dependencies here and pin the version in go.mod.
import (
_ "github.com/btcsuite/btcd"
_ "github.com/dvyukov/go-fuzz/go-fuzz"
_ "github.com/dvyukov/go-fuzz/go-fuzz-build"
_ "github.com/dvyukov/go-fuzz/go-fuzz-dep"
_ "github.com/golangci/golangci-lint/cmd/golangci-lint"
_ "github.com/ory/go-acc"
_ "github.com/rinchsan/gosimports/cmd/gosimports"
Expand Down

0 comments on commit beb4d8c

Please sign in to comment.