marksteven2017 / Scorecoin

Scorecoin
MIT License
5 stars 8 forks source link

Issue with Recent Update #6

Closed daygle closed 6 years ago

daygle commented 7 years ago

Update failing when compiling, see below error:-

root@score:~/scorecoin/src# make -f makefile.unix USE_UPNP=- /bin/sh ../share/genbuild.sh obj/build.h g++ -c -O2 -pthread -Wall -Wextra -Wconversion-null -Wmaybe-uninitialized -Wno-ignored-qualifiers -Wformat -Wunused-variable -Wformat-security -Wno-unused-parameter -g -DBOOST_SPIRIT_THREADSAFE -I/root/scorecoin/src -I/root/scorecoin/src/obj -I/root/scorecoin/src/secp256k1/include -DUSE_IPV6=1 -I/root/scorecoin/src/leveldb/include -I/root/scorecoin/src/leveldb/helpers -DHAVE_BUILD_INFO -fno-stack-protector -fstack-protector-all -Wstack-protector -D_FORTIFY_SOURCE=2 -MMD -MF obj/main.d -o obj/main.o main.cpp main.cpp: In function 'unsigned int GetNextWorkRequired(const CBlockIndex, const CBlockHeader)': main.cpp:1268:37: warning: unused variable 'BlocksTargetSpacing' [-Wunused-variable] static const int64 BlocksTargetSpacing = 60; // 1 minute ^ main.cpp:1269:45: warning: unused variable 'TimeDaySeconds' [-Wunused-variable] unsigned int TimeDaySeconds = 60 60 24; ^ main.cpp: In function 'void Misbehaving(NodeId, int)': main.cpp:1389:125: error: cannot pass objects of non-trivially-copyable type 'std::string {aka class std::basic_string}' through '...' printf("Misbehaving: %s (%d -> %d) BAN THRESHOLD EXCEEDED\n", pn->addrName, pn->nMisbehavior - howmuch, pn->nMisbehavior); ^ main.cpp:1393:102: error: cannot pass objects of non-trivially-copyable type 'std::string {aka class std::basic_string}' through '...' printf("Misbehaving: %s (%d -> %d)\n", pn->addrName, pn->nMisbehavior - howmuch, pn->nMisbehavior); ^ main.cpp: In member function 'bool CBlock::CheckBlock(CValidationState&, bool, bool) const': main.cpp:2356:226: warning: format '%d' expects argument of type 'int', but argument 3 has type 'CAmount {aka long int}' [-Wformat=] if (fDebug) { printf("CheckBlock() : Couldn't find masternode payment(%d|%d) or payee(%d|%s) nHeight %d. \n", foundPaymentAmount, masternodePaymentAmount, foundPayee, address2.ToString().c_str(), pindexBest->nHeight + 1); } ^ makefile.unix:203: recipe for target 'obj/main.o' failed

RyanEmerick commented 6 years ago

this issue is related to the old source code which wont be developed any more. see master or branch 2.0 for working implemenation