英文:
How to make thrift 0.8 build go library?
问题
我下载了thrift 0.8的压缩包,我的GOROOT是"/home/alex/go",为了确保在编译thrift时能够构建go库,应该修改什么?
目前,运行./configure时得到以下输出:
.......
Building PHP Library ......... : no
Building Erlang Library ...... : yes
Building Go Library .......... : no (这是说go库不会被构建吗?)
英文:
I download thrift 0.8 tarball,and my GOROOT is "/home/alex/go",what should be modified to make sure go library got built when compile thrift?
Currently,when run ./configure got
.......
Building PHP Library ......... : no
Building Erlang Library ...... : yes
Building Go Library .......... : no (is this saying go library won't be built?)
答案1
得分: 1
configure:19244: 检查是否有6g
configure:19274: 结果: /home/jarod/dev/go/go-hg/bin//6g
configure:19284: 检查是否有6l
configure:19314: 结果: /home/jarod/dev/go/go-hg/bin//6l
configure:19324: 检查是否有gomake
configure:19354: 结果: /home/jarod/dev/go/go-hg/bin//gomake
configure:19364: 检查是否有goinstall
configure:19394: 结果: /home/jarod/dev/go/go-hg/bin//goinstall
英文:
thrift do not support Go 1 yet. The configure script try to find the old go commands to build go library.
configure:19244: checking for 6g
configure:19274: result: /home/jarod/dev/go/go-hg/bin//6g
configure:19284: checking for 6l
configure:19314: result: /home/jarod/dev/go/go-hg/bin//6l
configure:19324: checking for gomake
configure:19354: result: /home/jarod/dev/go/go-hg/bin//gomake
configure:19364: checking for goinstall
configure:19394: result: /home/jarod/dev/go/go-hg/bin//goinstall
答案2
得分: 0
首先,运行./configure --help
,查找类似--enable-go
或--with-go
的命令行选项,可能构建Go库默认情况下并没有尝试。我从未尝试过自己构建thrift,所以不清楚是否正确;请自行检查。
如果你确定默认情况下启用了构建Go库,你需要检查为什么configure
对你的环境不满意。查看由./configure
运行产生的config.log
文件,并在其中搜索“Building go Library”子字符串,大约在其出现附近,你会找到configure
脚本执行的测试以及失败的原因。
如果调查后仍然不清楚原因,请查看configure
脚本代码,它只是一个shell脚本(复杂但对于程序员来说仍然可读)。
英文:
First of all, run ./configure --help
and look for something like --enable-go
or --with-go
command line options — it may well happen that building of the Go library is just not attempted by default. I have never tried to build thrift myself so I have no idea about whether it's true or not; check yourself.
If you're sure building of the Go library is enabled by default, you'll have to check why configure
was not satisfied with your environment. Look at the config.log
file produced by the ./configure
run and search for the "Building go Library" substring in there — somewhere around its occurence, you'll find what test the configure
script performed, and why it failed.
If the cause is still unclear after investigation, look at the configure
script code — it's just a shell script after all (complex but still readable for a programmer).
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论