- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我正在关注 cryptonote starter关于在自己的区 block 链上创建加密货币。到目前为止一切顺利,只是它无法编译。我在 Ubuntu 18.04 和 16.04 上都试过了,我得到了同样的错误。按照指南中的说明创建代码后,我留下创世地址并点击编译。
当我运行 make 我得到这个错误:
[ 53%] Building CXX object src/CMakeFiles/ConnectivityTool.dir/ConnectivityTool/ConnectivityTool.cpp.o
[ 53%] Linking CXX executable connectivity_tool
/usr/bin/ld: StreamTools.cpp.o: plugin needed to handle lto object
/tmp/ccn2FxVh.ltrans2.ltrans.o: In function `std::_Function_handler<void (), handle_request_stat(boost::program_options::variables_map&, unsigned long long)::{lambda()#4}>::_M_invoke(std::_Any_data const&) [clone .lto_priv.448]':
<artificial>:(.text+0x161b): undefined reference to `Common::write(Common::IOutputStream&, void const*, unsigned int)'
<artificial>:(.text+0x164b): undefined reference to `Common::write(Common::IOutputStream&, void const*, unsigned int)'
<artificial>:(.text+0x1798): undefined reference to `Common::write(Common::IOutputStream&, void const*, unsigned int)'
<artificial>:(.text+0x17d2): undefined reference to `Common::write(Common::IOutputStream&, void const*, unsigned int)'
/tmp/ccn2FxVh.ltrans2.ltrans.o: In function `std::_Function_handler<void (), handle_request_stat(boost::program_options::variables_map&, unsigned long long)::{lambda()#3}>::_M_invoke(std::_Any_data const&) [clone .lto_priv.450]':
<artificial>:(.text+0x1b35): undefined reference to `Common::write(Common::IOutputStream&, void const*, unsigned int)'
/tmp/ccn2FxVh.ltrans2.ltrans.o:<artificial>:(.text+0x1b5b): more undefined references to `Common::write(Common::IOutputStream&, void const*, unsigned int)' follow
/tmp/ccn2FxVh.ltrans27.ltrans.o: In function `(anonymous namespace)::loadSection(Common::IInputStream&) [clone .lto_priv.376]':
<artificial>:(.text+0x391): undefined reference to `Common::read(Common::IInputStream&, unsigned char&)'
<artificial>:(.text+0x3db): undefined reference to `Common::read(Common::IInputStream&, unsigned char&)'
<artificial>:(.text+0x42d): undefined reference to `Common::read(Common::IInputStream&, void*, unsigned int)'
<artificial>:(.text+0x485): undefined reference to `Common::read(Common::IInputStream&, void*, unsigned int)'
<artificial>:(.text+0x4ae): undefined reference to `Common::read(Common::IInputStream&, void*, unsigned int)'
<artificial>:(.text+0x4ed): undefined reference to `Common::read(Common::IInputStream&, unsigned char&)'
<artificial>:(.text+0x52b): undefined reference to `Common::read(Common::IInputStream&, unsigned char&)'
/tmp/ccn2FxVh.ltrans27.ltrans.o: In function `(anonymous namespace)::loadValue(Common::IInputStream&, unsigned char)':
<artificial>:(.text+0x8f4): undefined reference to `Common::read(Common::IInputStream&, unsigned char&)'
<artificial>:(.text+0x961): undefined reference to `Common::read(Common::IInputStream&, void*, unsigned int)'
<artificial>:(.text+0x9c1): undefined reference to `Common::read(Common::IInputStream&, void*, unsigned int)'
<artificial>:(.text+0x9f1): undefined reference to `Common::read(Common::IInputStream&, void*, unsigned int)'
<artificial>:(.text+0xa11): undefined reference to `Common::read(Common::IInputStream&, void*, unsigned int)'
<artificial>:(.text+0xa31): undefined reference to `Common::read(Common::IInputStream&, void*, unsigned int)'
/tmp/ccn2FxVh.ltrans27.ltrans.o:<artificial>:(.text+0xa51): more undefined references to `Common::read(Common::IInputStream&, void*, unsigned int)' follow
/tmp/ccn2FxVh.ltrans27.ltrans.o: In function `(anonymous namespace)::loadValue(Common::IInputStream&, unsigned char)':
<artificial>:(.text+0xb5c): undefined reference to `Common::read(Common::IInputStream&, unsigned char&)'
<artificial>:(.text+0xb98): undefined reference to `Common::read(Common::IInputStream&, unsigned char&)'
<artificial>:(.text+0xc29): undefined reference to `Common::read(Common::IInputStream&, unsigned char&)'
<artificial>:(.text+0xcb9): undefined reference to `Common::read(Common::IInputStream&, unsigned char&)'
<artificial>:(.text+0xcf9): undefined reference to `Common::read(Common::IInputStream&, void*, unsigned int)'
/tmp/ccn2FxVh.ltrans29.ltrans.o: In function `CryptoNote::KVBinaryInputStreamSerializer::KVBinaryInputStreamSerializer(Common::IInputStream&)':
<artificial>:(.text+0x1087): undefined reference to `Common::read(Common::IInputStream&, void*, unsigned int)'
collect2: error: ld returned 1 exit status
src/CMakeFiles/ConnectivityTool.dir/build.make:113: recipe for target 'src/connectivity_tool' failed
make[3]: *** [src/connectivity_tool] Error 1
make[3]: Leaving directory '/home/user/Desktop/mycoin/build/release'
CMakeFiles/Makefile2:415: recipe for target 'src/CMakeFiles/ConnectivityTool.dir/all' failed
make[2]: *** [src/CMakeFiles/ConnectivityTool.dir/all] Error 2
make[2]: Leaving directory '/home/user/Desktop/mycoin/build/release'
Makefile:94: recipe for target 'all' failed
make[1]: *** [all] Error 2
make[1]: Leaving directory '/home/user/Desktop/mycoin/build/release'
Makefile:20: recipe for target 'build-release' failed
make: *** [build-release] Error 2
Here is one that you can setup without errors on latest Ubuntu https://github.com/Matthuffy/eightcoin
sudo apt install build-essential libqt4-dev qt5-qmake cmake qttools5-dev libqt5webkit5-dev qttools5-dev-tools qt5-default python-sphinx texlive-latex-base inotify-tools openssl libssl-dev libdb++-dev libminiupnpc-dev git sqlite3 libsqlite3-dev g++ libpng-dev gedit python gcc make libbz2-dev libdb-dev libssl-dev libreadline-dev autoconf libtool libleveldb-dev libblkid-dev e2fslibs-dev libboost-all-dev libaudit-dev nano qtbase5-dev qt4-dev-tools libqtcore4 libqtgui4 automake -y
make -v
GNU Make 4.1
dpkg -s libboost-dev | grep 'Version'
Version: 1.58.0.1ubuntu1
最佳答案
让我告诉你我有同样的错误,但是寻找解决方案并进行调查,我终于找到了解决这个问题的方法。
你必须删除set (RELEASE_FLAGS "$ {RELEASE_FLAGS} -flto")
或者只是在它前面放一个#,这样#set (RELEASE_FLAGS "$ {RELEASE_FLAGS} -flto")
这可以在 CMakeList.txt 中找到
您必须按如下方式运行它
sudo make -j
关于c++ - CryptoNote 使编译问题 Ubuntu,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/57289217/
我正在关注 cryptonote starter关于在自己的区 block 链上创建加密货币。到目前为止一切顺利,只是它无法编译。我在 Ubuntu 18.04 和 16.04 上都试过了,我得到了同
我正在为一个项目使用 cryptonote 存储库,现在我需要编译二进制文件。 当我运行 make 时,出现以下错误: /Documents/huntcoin/src/CryptoNoteCore
我是一名优秀的程序员,十分优秀!