Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to build after 0.33.0 Makefile changes #3821

Closed
4 tasks
joe-bowman opened this issue Mar 7, 2019 · 1 comment
Closed
4 tasks

Unable to build after 0.33.0 Makefile changes #3821

joe-bowman opened this issue Mar 7, 2019 · 1 comment

Comments

@joe-bowman
Copy link
Contributor

joe-bowman commented Mar 7, 2019

Summary of Bug

Post the 0.33.0 Makefile changes, ref: #3620 I am no longer unable to build the binaries on a clean checkout (building where dependencies have been previously fetched works, but not after a clean checkout or in a Docker container).

Steps to Reproduce

git clone --branch=v0.33.0 https://github.com/cosmos/cosmos-sdk.git .  && make tools   && make build  && make install

Cloning into '.'...
Note: checking out '06f741609bbce747643e9f1f2abf67040ad78e16'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:

  git checkout -b <new-branch-name>

cat: can't open 'vendor-deps': No such file or directory
mkdir -p /go/src/github.com/golang && (test ! -d /go/src/github.com/golang/dep && cd /go/src/github.com/golang && git clone https://github.com/golang/dep) || true &&  cd /go/src/github.com/golang/dep && git fetch origin && git checkout -q 22125cfaa6ddc71e145b1535d4b7ee9744fefff2
Cloning into 'dep'...
cd /go/src/github.com/golang/dep/cmd/dep && /usr/local/go/bin/go install
mkdir -p /go/src/github.com/alecthomas && (test ! -d /go/src/github.com/alecthomas/gometalinter && cd /go/src/github.com/alecthomas && git clone https://github.com/alecthomas/gometalinter) || true &&  cd /go/src/github.com/alecthomas/gometalinter && git fetch origin && git checkout -q v3.0.0 && cd /go/src/github.com/alecthomas/gometalinter && /usr/local/go/bin/go install
Cloning into 'gometalinter'...
mkdir -p /go/src/github.com/rakyll && (test ! -d /go/src/github.com/rakyll/statik && cd /go/src/github.com/rakyll && git clone https://github.com/rakyll/statik) || true &&  cd /go/src/github.com/rakyll/statik && git fetch origin && git checkout -q v0.1.5 && cd /go/src/github.com/rakyll/statik && /usr/local/go/bin/go install
Cloning into 'statik'...
go get golang.org/x/tools/cmd/goimports
cat: can't open 'vendor-deps': No such file or directory
make: Nothing to be done for 'get_vendor_deps'.
cat: can't open 'vendor-deps': No such file or directory
go build -tags "netgo ledger" -ldflags '-X github.com/cosmos/cosmos-sdk/version.Version=0.33.0 -X github.com/cosmos/cosmos-sdk/version.Commit=06f741609bbce747643e9f1f2abf67040ad78e16 -X github.com/cosmos/cosmos-sdk/version.VendorDirHash= -X "github.com/cosmos/cosmos-sdk/version.BuildTags=netgo ledger"' -o build/gaiad ./cmd/gaia/cmd/gaiad
client/keys/mnemonic.go:7:2: cannot find package "github.com/bartekn/go-bip39" in any of:
	/usr/local/go/src/github.com/bartekn/go-bip39 (from $GOROOT)
	/go/src/github.com/bartekn/go-bip39 (from $GOPATH)
client/input.go:11:2: cannot find package "github.com/bgentry/speakeasy" in any of:
	/usr/local/go/src/github.com/bgentry/speakeasy (from $GOROOT)
	/go/src/github.com/bgentry/speakeasy (from $GOPATH)
crypto/ledger_secp256k1.go:7:2: cannot find package "github.com/btcsuite/btcd/btcec" in any of:
	/usr/local/go/src/github.com/btcsuite/btcd/btcec (from $GOROOT)
	/go/src/github.com/btcsuite/btcd/btcec (from $GOPATH)
crypto/keys/keybase.go:18:2: cannot find package "github.com/cosmos/go-bip39" in any of:
	/usr/local/go/src/github.com/cosmos/go-bip39 (from $GOROOT)
	/go/src/github.com/cosmos/go-bip39 (from $GOPATH)
crypto/ledger_real.go:5:8: cannot find package "github.com/cosmos/ledger-cosmos-go" in any of:
	/usr/local/go/src/github.com/cosmos/ledger-cosmos-go (from $GOROOT)
	/go/src/github.com/cosmos/ledger-cosmos-go (from $GOPATH)
baseapp/baseapp.go:12:2: cannot find package "github.com/gogo/protobuf/proto" in any of:
	/usr/local/go/src/github.com/gogo/protobuf/proto (from $GOROOT)
	/go/src/github.com/gogo/protobuf/proto (from $GOPATH)
types/context.go:9:2: cannot find package "github.com/golang/protobuf/proto" in any of:
	/usr/local/go/src/github.com/golang/protobuf/proto (from $GOROOT)
	/go/src/github.com/golang/protobuf/proto (from $GOPATH)
client/input.go:12:2: cannot find package "github.com/mattn/go-isatty" in any of:
	/usr/local/go/src/github.com/mattn/go-isatty (from $GOROOT)
	/go/src/github.com/mattn/go-isatty (from $GOPATH)
client/config.go:12:2: cannot find package "github.com/pelletier/go-toml" in any of:
	/usr/local/go/src/github.com/pelletier/go-toml (from $GOROOT)
	/go/src/github.com/pelletier/go-toml (from $GOPATH)
types/dec_coin.go:9:2: cannot find package "github.com/pkg/errors" in any of:
	/usr/local/go/src/github.com/pkg/errors (from $GOROOT)
	/go/src/github.com/pkg/errors (from $GOPATH)
types/module_clients.go:4:2: cannot find package "github.com/spf13/cobra" in any of:
	/usr/local/go/src/github.com/spf13/cobra (from $GOROOT)
	/go/src/github.com/spf13/cobra (from $GOPATH)
x/staking/client/cli/flags.go:4:2: cannot find package "github.com/spf13/pflag" in any of:
	/usr/local/go/src/github.com/spf13/pflag (from $GOROOT)
	/go/src/github.com/spf13/pflag (from $GOPATH)
version/command.go:8:2: cannot find package "github.com/spf13/viper" in any of:
	/usr/local/go/src/github.com/spf13/viper (from $GOROOT)
	/go/src/github.com/spf13/viper (from $GOPATH)
x/params/subspace/test_common.go:7:2: cannot find package "github.com/stretchr/testify/require" in any of:
	/usr/local/go/src/github.com/stretchr/testify/require (from $GOROOT)
	/go/src/github.com/stretchr/testify/require (from $GOPATH)
crypto/ledger_secp256k1.go:13:2: cannot find package "github.com/tendermint/btcd/btcec" in any of:
	/usr/local/go/src/github.com/tendermint/btcd/btcec (from $GOROOT)
	/go/src/github.com/tendermint/btcd/btcec (from $GOPATH)
codec/codec.go:7:2: cannot find package "github.com/tendermint/go-amino" in any of:
	/usr/local/go/src/github.com/tendermint/go-amino (from $GOROOT)
	/go/src/github.com/tendermint/go-amino (from $GOPATH)
store/iavl/store.go:8:2: cannot find package "github.com/tendermint/iavl" in any of:
	/usr/local/go/src/github.com/tendermint/iavl (from $GOROOT)
	/go/src/github.com/tendermint/iavl (from $GOPATH)
server/start.go:9:2: cannot find package "github.com/tendermint/tendermint/abci/server" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/abci/server (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/abci/server (from $GOPATH)
store/types/store.go:7:2: cannot find package "github.com/tendermint/tendermint/abci/types" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/abci/types (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/abci/types (from $GOPATH)
server/start.go:11:2: cannot find package "github.com/tendermint/tendermint/cmd/tendermint/commands" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/cmd/tendermint/commands (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/cmd/tendermint/commands (from $GOPATH)
server/util.go:18:2: cannot find package "github.com/tendermint/tendermint/config" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/config (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/config (from $GOPATH)
types/address.go:11:2: cannot find package "github.com/tendermint/tendermint/crypto" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/crypto (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/crypto (from $GOPATH)
crypto/keys/mintkey/mintkey.go:10:2: cannot find package "github.com/tendermint/tendermint/crypto/armor" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/crypto/armor (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/crypto/armor (from $GOPATH)
x/mock/app.go:12:2: cannot find package "github.com/tendermint/tendermint/crypto/ed25519" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/crypto/ed25519 (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/crypto/ed25519 (from $GOPATH)
codec/codec.go:8:2: cannot find package "github.com/tendermint/tendermint/crypto/encoding/amino" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/crypto/encoding/amino (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/crypto/encoding/amino (from $GOPATH)
store/iavl/store.go:10:2: cannot find package "github.com/tendermint/tendermint/crypto/merkle" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/crypto/merkle (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/crypto/merkle (from $GOPATH)
x/auth/ante.go:11:2: cannot find package "github.com/tendermint/tendermint/crypto/multisig" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/crypto/multisig (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/crypto/multisig (from $GOPATH)
x/auth/ante.go:12:2: cannot find package "github.com/tendermint/tendermint/crypto/secp256k1" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/crypto/secp256k1 (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/crypto/secp256k1 (from $GOPATH)
store/rootmulti/store.go:10:2: cannot find package "github.com/tendermint/tendermint/crypto/tmhash" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/crypto/tmhash (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/crypto/tmhash (from $GOPATH)
crypto/keys/mintkey/mintkey.go:12:2: cannot find package "github.com/tendermint/tendermint/crypto/xsalsa20symmetric" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/crypto/xsalsa20symmetric (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/crypto/xsalsa20symmetric (from $GOPATH)
types/address.go:14:2: cannot find package "github.com/tendermint/tendermint/libs/bech32" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/libs/bech32 (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/libs/bech32 (from $GOPATH)
version/command.go:10:2: cannot find package "github.com/tendermint/tendermint/libs/cli" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/libs/cli (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/libs/cli (from $GOPATH)
server/util.go:20:2: cannot find package "github.com/tendermint/tendermint/libs/cli/flags" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/libs/cli/flags (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/libs/cli/flags (from $GOPATH)
store/types/store.go:8:2: cannot find package "github.com/tendermint/tendermint/libs/common" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/libs/common (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/libs/common (from $GOPATH)
store/types/store.go:9:2: cannot find package "github.com/tendermint/tendermint/libs/db" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/libs/db (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/libs/db (from $GOPATH)
types/context.go:12:2: cannot find package "github.com/tendermint/tendermint/libs/log" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/libs/log (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/libs/log (from $GOPATH)
client/context/context.go:20:2: cannot find package "github.com/tendermint/tendermint/lite" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/lite (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/lite (from $GOPATH)
client/context/query.go:16:2: cannot find package "github.com/tendermint/tendermint/lite/errors" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/lite/errors (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/lite/errors (from $GOPATH)
client/context/context.go:21:2: cannot find package "github.com/tendermint/tendermint/lite/proxy" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/lite/proxy (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/lite/proxy (from $GOPATH)
server/start.go:13:2: cannot find package "github.com/tendermint/tendermint/node" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/node (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/node (from $GOPATH)
server/start.go:14:2: cannot find package "github.com/tendermint/tendermint/p2p" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/p2p (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/p2p (from $GOPATH)
server/start.go:15:2: cannot find package "github.com/tendermint/tendermint/privval" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/privval (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/privval (from $GOPATH)
server/start.go:16:2: cannot find package "github.com/tendermint/tendermint/proxy" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/proxy (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/proxy (from $GOPATH)
client/context/context.go:22:2: cannot find package "github.com/tendermint/tendermint/rpc/client" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/rpc/client (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/rpc/client (from $GOPATH)
types/result.go:8:2: cannot find package "github.com/tendermint/tendermint/rpc/core/types" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/rpc/core/types (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/rpc/core/types (from $GOPATH)
x/mock/simulation/mock_tendermint.go:12:2: cannot find package "github.com/tendermint/tendermint/types" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/types (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/types (from $GOPATH)
cmd/gaia/init/testnet.go:29:2: cannot find package "github.com/tendermint/tendermint/types/time" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/types/time (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/types/time (from $GOPATH)
server/tm_cmds.go:15:2: cannot find package "github.com/tendermint/tendermint/version" in any of:
	/usr/local/go/src/github.com/tendermint/tendermint/version (from $GOROOT)
	/go/src/github.com/tendermint/tendermint/version (from $GOPATH)
crypto/keys/mintkey/mintkey.go:7:2: cannot find package "golang.org/x/crypto/bcrypt" in any of:
	/usr/local/go/src/golang.org/x/crypto/bcrypt (from $GOROOT)
	/go/src/golang.org/x/crypto/bcrypt (from $GOPATH)
make: *** [Makefile:78: build] Error 1

The line cat: can't open 'vendor-deps': No such file or directory is the first sign of problems, and correlates to the following command at line 47 of the Makefile:

ldflags = -X github.com/cosmos/cosmos-sdk/version.Version=$(VERSION) \
	-X github.com/cosmos/cosmos-sdk/version.Commit=$(COMMIT) \
  -X github.com/cosmos/cosmos-sdk/version.VendorDirHash=$(shell $(CAT) vendor-deps) \
  -X "github.com/cosmos/cosmos-sdk/version.BuildTags=$(build_tags)"

I was able to build v0.32.0 tag with exactly the same commands yesterday. The issue seems to be that at the time of execution, the vendor-deps directory doesn't exist - because we are on a fresh clone of the cosmos-sdk repo.


For Admin Use

  • Not duplicate issue
  • Appropriate labels applied
  • Appropriate contributors tagged
  • Contributor assigned/self-assigned
@joe-bowman
Copy link
Contributor Author

This is due to the change in Makefile targets from get_vendors_deps to vendor_deps.

Closing,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant