douhao6271 2018-09-11 06:27
浏览 194
已采纳

即使程序包存在,Dep init也会失败

I am trying to package a go application using dep and when doing dep init the below error occours.

I have installed the amcl library from here - https://github.com/milagro-crypto/amcl/tree/master/version3/go

Even the following packages exists

nithin@XPS-L401X:~/go/src/github.com/milagro-crypto/amcl/version3/go/amcl/FP256BN$ ls
ARCH.go  BIG.go  DBIG.go  ECDH.go  ECP2.go  ECP.go  FP12.go  FP2.go  FP4.go  FP.go  MPIN.go  PAIR.go  ROM.go

But still i get the following error

init failed: unable to solve the dependency graph: Solving failure: No versions of github.com/milagro-crypto/amcl met constraints:
    281d0829b307c911bb2f14f2fedc414a257cb8c8: Could not introduce github.com/milagro-crypto/amcl@281d0829b307c911bb2f14f2fedc414a257cb8c8 due to multiple problematic subpackages:
    Subpackage github.com/milagro-crypto/amcl/version3/go/amcl/FP256BN is missing. (Package is required by github.com/hyperledger/fabric@release-1.1.)  Subpackage github.com/milagro-crypto/amcl/version3/go/amcl is missing. (Package is required by github.com/hyperledger/fabric@release-1.1.)
    master: Could not introduce github.com/milagro-crypto/amcl@master due to multiple problematic subpackages:
    Subpackage github.com/milagro-crypto/amcl/version3/go/amcl is missing. (Package is required by github.com/hyperledger/fabric@release-1.1.)  Subpackage github.com/milagro-crypto/amcl/version3/go/amcl/FP256BN is missing. (Package is required by github.com/hyperledger/fabric@release-1.1.)
    add-js-tests: Could not introduce github.com/milagro-crypto/amcl@add-js-tests due to multiple problematic subpackages:
    Subpackage github.com/milagro-crypto/amcl/version3/go/amcl is missing. (Package is required by github.com/hyperledger/fabric@release-1.1.)  Subpackage github.com/milagro-crypto/amcl/version3/go/amcl/FP256BN is missing. (Package is required by github.com/hyperledger/fabric@release-1.1.)
    fix-retval: Could not introduce github.com/milagro-crypto/amcl@fix-retval due to multiple problematic subpackages:
    Subpackage github.com/milagro-crypto/amcl/version3/go/amcl is missing. (Package is required by github.com/hyperledger/fabric@release-1.1.)  Subpackage github.com/milagro-crypto/amcl/version3/go/amcl/FP256BN is missing. (Package is required by github.com/hyperledger/fabric@release-1.1.)
    milagro-crypto-c: Could not introduce github.com/milagro-crypto/amcl@milagro-crypto-c due to multiple problematic subpackages:
    Subpackage github.com/milagro-crypto/amcl/version3/go/amcl/FP256BN is missing. (Package is required by github.com/hyperledger/fabric@release-1.1.)  Subpackage github.com/milagro-crypto/amcl/version3/go/amcl is missing. (Package is required by github.com/hyperledger/fabric@release-1.1.)
  • 写回答

1条回答 默认 最新

  • dongyutan1703 2018-11-16 11:17
    关注

    I found the answer.

    Firstly go get github.com/milagro-crypto/amcl

    Then cd into this location (based on your $GOPATH) github.com/milagro-crypto/amcl/version3/go

    Follow this instructions to instal milagro
    https://github.com/milagro-crypto/amcl/tree/master/version3/go

    I recommend installing all options one after the other and then don't forget to

    go run TestALL.go

    and

    go run BenchtestALL.go

    else it fails to resolve, idk why.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 C#算法问题, 不知道怎么处理这个数据的转换
  • ¥15 YoloV5 第三方库的版本对照问题
  • ¥15 请完成下列相关问题!
  • ¥15 drone 推送镜像时候 purge: true 推送完毕后没有删除对应的镜像,手动拷贝到服务器执行结果正确在样才能让指令自动执行成功删除对应镜像,如何解决?
  • ¥15 求daily translation(DT)偏差订正方法的代码
  • ¥15 js调用html页面需要隐藏某个按钮
  • ¥15 ads仿真结果在圆图上是怎么读数的
  • ¥20 Cotex M3的调试和程序执行方式是什么样的?
  • ¥20 java项目连接sqlserver时报ssl相关错误
  • ¥15 一道python难题3