douwei7203 2017-07-22 07:33
浏览 45

Fabric-SDK-GO'ld.exe:找不到-lltdl'错误

When I try to get the fabric-sdk-go I get the following error:

$ go get github.com/hyperledger/fabric-sdk-go/pkg/fabric-client
# github.com/hyperledger/fabric-sdk-go/vendor/github.com/miekg/pkcs11
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/6.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find -lltdl
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/6.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find -lltdl
collect2.exe: error: ld returned 1 exit status

Does anyone have an idea what is the issue and how to resolve this?

  • 写回答

1条回答 默认 最新

  • duanhongyi2964 2017-07-22 11:24
    关注

    The error message told us that the library libltdl which is required by github.com/miekg/pkcs11 is missing. Although you didn't mention it explicitly, I think you're using MSYS2 as the development environment. Do the following steps to install the missing library.

    1. Search for the missing library, type pacman -Ss ltdl in MSYS2 terminal to get the exact package name. Here, ltdl is the keyword related to missing library which we got from error message. You should get something like:

      msys/libltdl 2.4.6-2  
          A system independent dlopen wrapper for GNU libtool
      

      From the result we know that the missing library is provided in libltdl package. It seems trivial, but sometimes a library may be provided by more than one package, e.g. a package which has prefix mingw-w64-i686-* for 32-bit system and the other with prefix mingw-w64-x86_64-* for 64-bit system.

    2. Install the package by: pacman -S libltdl.
    3. Reinstall the go package by: go get -v github.com/hyperledger/fabric-sdk-go/pkg/fabric-client.
    评论

报告相同问题?

悬赏问题

  • ¥15 基于单片机的靶位控制系统
  • ¥15 AT89C51控制8位八段数码管显示时钟。
  • ¥15 真我手机蓝牙传输进度消息被关闭了,怎么打开?(关键词-消息通知)
  • ¥15 下图接收小电路,谁知道原理
  • ¥15 装 pytorch 的时候出了好多问题,遇到这种情况怎么处理?
  • ¥20 IOS游览器某宝手机网页版自动立即购买JavaScript脚本
  • ¥15 手机接入宽带网线,如何释放宽带全部速度
  • ¥30 关于#r语言#的问题:如何对R语言中mfgarch包中构建的garch-midas模型进行样本内长期波动率预测和样本外长期波动率预测
  • ¥15 ETLCloud 处理json多层级问题
  • ¥15 matlab中使用gurobi时报错