问题描述
嗨,几天后,我尝试挖掘以太坊已经取得了进展:
首先,here 是我的原始帖子,我在那里得到了部分答案。
遵循本教程:https://medium.com/coinmonks/eth-x-nvidia-x-ubuntu-1980393a36f8
我现在卡在 cmake --build .
当我第一次运行它时出现此错误消息:
CMake Error at CMakeLists.txt:68 (find_package):
Could not find a package configuration file provided by "jsoncpp" with any
of the following names:
jsoncppConfig.cmake
jsoncpp-config.cmake
Add the installation prefix of "jsoncpp" to CMAKE_PREFIX_PATH or set
"jsoncpp_DIR" to a directory containing one of the above files. If
"jsoncpp" provides a separate development package or SDK,be sure it has
been installed.
经过一番谷歌搜索后,我找到了创建文件链接 ln -s /usr/include/jsoncpp/json/ /usr/include/json
的解决方案。此命令负责处理编译文件中错误的包含路径。
但是,现在我收到了不同的消息。我认为这是一个编译时错误,我什至不知道如何用谷歌搜索这个问题。
[ 56%] Building CXX object libethcore/CMakeFiles/ethcore.dir/EthashAux.cpp.o
/home/luka/ethmining/ethminer/libethcore/EthashAux.cpp: In static member function ‘static dev::eth::Result dev::eth::EthashAux::eval(int,const h256&,uint64_t)’:
/home/luka/ethmining/ethminer/libethcore/EthashAux.cpp:28:29: error: ‘get_global_epoch_context’ is not a member of ‘ethash’
28 | auto& context = ethash::get_global_epoch_context(epoch);
| ^~~~~~~~~~~~~~~~~~~~~~~~
/home/luka/ethmining/ethminer/libethcore/EthashAux.cpp:30:88: error: no matching function for call to ‘dev::FixedHash<32>::FixedHash(<brace-enclosed initializer list>)’
30 | h256 mix{reinterpret_cast<byte*>(result.mix_hash.bytes),h256::ConstructFromPointer};
| ^
In file included from /home/luka/ethmining/ethminer/libethcore/../libdevcore/Exceptions.h:31,from /home/luka/ethmining/ethminer/libethcore/EthashAux.h:21,from /home/luka/ethmining/ethminer/libethcore/EthashAux.cpp:18:
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:136:14: note: candidate: ‘dev::FixedHash<N>::FixedHash(const string&) [with unsigned int N = 32; std::string = std::__cxx11::basic_string<char>]’
136 | explicit FixedHash(std::string const& _s)
| ^~~~~~~~~
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:136:14: note: candidate expects 1 argument,2 provided
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:130:14: note: candidate: ‘dev::FixedHash<N>::FixedHash(const byte*,dev::FixedHash<N>::ConstructFromPointerType) [with unsigned int N = 32; byte = unsigned char]’
130 | explicit FixedHash(byte const* _bs,ConstructFromPointerType /*unused*/)
| ^~~~~~~~~
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:130:14: note: conversion of argument 1 would be ill-formed:
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:112:14: note: candidate: ‘dev::FixedHash<N>::FixedHash(dev::bytesConstRef,dev::FixedHash<N>::ConstructFromHashType) [with unsigned int N = 32; dev::bytesConstRef = dev::vector_ref<const unsigned char>]’
112 | explicit FixedHash(bytesConstRef _b,ConstructFromHashType _t = FailIfDifferent)
| ^~~~~~~~~
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:112:14: note: conversion of argument 1 would be ill-formed:
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:94:14: note: candidate: ‘dev::FixedHash<N>::FixedHash(const bytes&,dev::FixedHash<N>::ConstructFromHashType) [with unsigned int N = 32; dev::bytes = std::vector<unsigned char>]’
94 | explicit FixedHash(bytes const& _b,ConstructFromHashType _t = FailIfDifferent)
| ^~~~~~~~~
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:94:14: note: conversion of argument 1 would be ill-formed:
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:91:14: note: candidate: ‘dev::FixedHash<N>::FixedHash(unsigned int) [with unsigned int N = 32]’
91 | explicit FixedHash(unsigned _u) { toBigEndian(_u,m_data); }
| ^~~~~~~~~
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:91:14: note: candidate expects 1 argument,2 provided
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:88:5: note: candidate: ‘dev::FixedHash<N>::FixedHash(const Arith&) [with unsigned int N = 32; dev::FixedHash<N>::Arith = boost::multiprecision::number<boost::multiprecision::backends::cpp_int_backend<256,256,boost::multiprecision::unsigned_magnitude,boost::multiprecision::unchecked,void> >]’
88 | FixedHash(Arith const& _arith) { toBigEndian(_arith,m_data); }
| ^~~~~~~~~
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:88:5: note: candidate expects 1 argument,2 provided
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:79:14: note: candidate: ‘template<unsigned int M> dev::FixedHash<N>::FixedHash(const dev::FixedHash<M>&,dev::FixedHash<N>::ConstructFromHashType)’
79 | explicit FixedHash(FixedHash<M> const& _h,ConstructFromHashType _t = AlignLeft)
| ^~~~~~~~~
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:79:14: note: template argument deduction/substitution Failed:
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:75:5: note: candidate: ‘dev::FixedHash<N>::FixedHash() [with unsigned int N = 32]’
75 | FixedHash() { m_data.fill(0); }
| ^~~~~~~~~
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:75:5: note: candidate expects 0 arguments,2 provided
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:41:7: note: candidate: ‘constexpr dev::FixedHash<32>::FixedHash(const dev::FixedHash<32>&)’
41 | class FixedHash
| ^~~~~~~~~
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:41:7: note: candidate expects 1 argument,2 provided
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:41:7: note: candidate: ‘constexpr dev::FixedHash<32>::FixedHash(dev::FixedHash<32>&&)’
/home/luka/ethmining/ethminer/libethcore/../libdevcore/FixedHash.h:41:7: note: candidate expects 1 argument,2 provided
/home/luka/ethmining/ethminer/libethcore/EthashAux.cpp:31:92: error: no matching function for call to ‘dev::FixedHash<32>::FixedHash(<brace-enclosed initializer list>)’
31 | h256 final{reinterpret_cast<byte*>(result.final_hash.bytes),h256::ConstructFromPointer};
| ^
In file included from /home/luka/ethmining/ethminer/libethcore/../libdevcore/Exceptions.h:31,2 provided
make[2]: *** [libethcore/CMakeFiles/ethcore.dir/build.make:63: libethcore/CMakeFiles/ethcore.dir/EthashAux.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:304: libethcore/CMakeFiles/ethcore.dir/all] Error 2
make: *** [Makefile:152: all] Error 2
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)