dongyao9762 2018-09-04 10:17
浏览 175
已采纳

滑动安装go-ethereum依赖项和bidmint依赖项

I'm using "glide" to manage my go packages, here is my glide.yaml:

package: github.com/my-project
import:
- package: github.com/ethereum/go-ethereum
  version: 1.8.14
  subpackages:
  - cmd/utils
  - common
  - common/hexutil
  - consensus/ethash
  - core
  - core/state
  - core/types
  - core/vm
  - eth
  - ethdb
  - event
  - log
  - node
  - p2p
  - params
  - rlp
  - rpc
- package: github.com/tendermint/tendermint
  version: 0.23.0
  subpackages:
  - abci/types
  - libs/log
  - rpc/lib/client
- package: gopkg.in/urfave/cli.v1
testImport:
- package: github.com/stretchr/testify
  subpackages:
  - assert
- package: github.com/tendermint/go-amino

when I run glide install, then some errors show up:

[INFO]  --> Fetching updates for github.com/mattn/go-colorable
[INFO]  --> Fetching updates for github.com/huin/goupnp
[INFO]  --> Fetching updates for github.com/jackpal/go-nat-pmp
[ERROR] Error scanning github.com/prometheus/prometheus/util/flock: 
cannot find package "." in:
    /root/.glide/cache/src/https-github.com-prometheus- prometheus/util/flock
[INFO]  --> Fetching updates for github.com/elastic/gosigar
[INFO]  --> Fetching updates for github.com/mohae/deepcopy
[INFO]  --> Fetching updates for github.com/influxdata/influxdb

...

[ERROR] Error scanning golang.org/x/sys/cpu: cannot find package "." in:
/root/.glide/cache/src/https-github.com-golang-sys/cpu
[INFO]  --> Fetching updates for github.com/matttproud/golang_protobuf_extensions
[INFO]  --> Setting version for github.com/matttproud/golang_protobuf_extensions to 3247c84500bff8d9fb6d579d800f20b3e091582c. 
[ERROR] Failed to retrieve a list of dependencies: Error resolving imports

so I try to change the glide mirror to my local file (I have cloned all the dependencies already), but it still not work, if someone know how to deal with it, please give me a hand, thanks

  • 写回答

1条回答 默认 最新

  • drll42469 2018-09-14 02:35
    关注

    I figure it out, just set the mirror, and ignore some package, like this

    glide mirror set https://golang.org/x/mobile https://github.com/golang/mobile --vcs git
    glide mirror set https://golang.org/x/crypto https://github.com/golang/crypto --vcs git
    ....
    

    ignore

    - github.com/prometheus/prometheus/util/flock
    - golang.org/x/sys/cpu
    - golang.org/x/net/http2/hpack
    
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 有了解d3和topogram.js库的吗?有偿请教
  • ¥100 任意维数的K均值聚类
  • ¥15 stamps做sbas-insar,时序沉降图怎么画
  • ¥15 unity第一人称射击小游戏,有demo,在原脚本的基础上进行修改以达到要求
  • ¥15 买了个传感器,根据商家发的代码和步骤使用但是代码报错了不会改,有没有人可以看看
  • ¥15 关于#Java#的问题,如何解决?
  • ¥15 加热介质是液体,换热器壳侧导热系数和总的导热系数怎么算
  • ¥100 嵌入式系统基于PIC16F882和热敏电阻的数字温度计
  • ¥15 cmd cl 0x000007b
  • ¥20 BAPI_PR_CHANGE how to add account assignment information for service line