cpuminer 无法安装。在脚本结束时我收到错误:
/home/barv/cpuminer-multi/./compat/jansson/jansson.h:159: undefined reference to `json_object_set_new'
/tmp/ccmWdwtA.ltrans27.ltrans.o: In function `rpc2_job_decode.part.10.lto_priv.371':
/home/barv/cpuminer-multi/util.c:1578: undefined reference to `json_object_get'
/home/barv/cpuminer-multi/util.c:1583: undefined reference to `json_string_value'
/home/barv/cpuminer-multi/util.c:1584: undefined reference to `json_object_get'
/home/barv/cpuminer-multi/util.c:1589: undefined reference to `json_string_value'
collect2: error: ld returned 1 exit status
Reaping losing child 0xdf7d50 PID 3148
Makefile:900: recipe for target 'cpuminer' failed
make[2]: *** [cpuminer] Error 1
Removing child 0xdf7d50 PID 3148 from chain.
make[2]: Leaving directory '/home/barv/cpuminer/gr/cpuminer-multi'
Reaping losing child 0x16e57e0 PID 3129
Makefile:2530: recipe for target 'all-recursive' failed
make[1]: *** [all-recursive] Error 1
Removing child 0x16e57e0 PID 3129 from chain.
make[1]: Leaving directory '/home/barv/cpuminer/gr/cpuminer-multi'
Reaping losing child 0x2515710 PID 3128
Makefile:570: recipe for target 'all' failed
make: *** [all] Error 2
Removing child 0x2515710 PID 3128 from chain.
我猜安装脚本是为 14.04 编写的。这里可能出了什么问题?
干杯。Barv
答案1
我遇到了同样的问题,缺少sudo apt-get install libjansson-dev
。安装后,我重新运行了自述文件中的命令:
./autogen.sh # only needed if building from git repo
./nomacro.pl # only needed if building on Mac OS X or with Clang
./configure CFLAGS="*-march=native*" --with-crypto --with-curl
# Use -march=native if building for a single machine
make
并且成功了。我使用的是 raspbian-stretch lite,但它也使用 apt-get