@@ -7,8 +7,6 @@ make -f Makefile_rogue
|
|||||||
rm ../libcc.so
|
rm ../libcc.so
|
||||||
cp librogue.so ../libcc.so
|
cp librogue.so ../libcc.so
|
||||||
|
|
||||||
#exit 0
|
|
||||||
|
|
||||||
echo sudoku/musig/dilithium
|
echo sudoku/musig/dilithium
|
||||||
gcc -O3 -std=c++11 -I../secp256k1/include -I../univalue/include -I../cryptoconditions/include -I../cryptoconditions/src -I../cryptoconditions/src/asn -I.. -I. -fPIC -shared -c -o sudokucc.so cclib.cpp
|
gcc -O3 -std=c++11 -I../secp256k1/include -I../univalue/include -I../cryptoconditions/include -I../cryptoconditions/src -I../cryptoconditions/src/asn -I.. -I. -fPIC -shared -c -o sudokucc.so cclib.cpp
|
||||||
|
|
||||||
|
|||||||
@@ -35,3 +35,6 @@ else
|
|||||||
echo ROGUE BUILD FAILED
|
echo ROGUE BUILD FAILED
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
rm ../libcc.so
|
||||||
|
cp librogue.so ../libcc.so
|
||||||
|
|||||||
@@ -51,6 +51,7 @@ using namespace std;
|
|||||||
extern int32_t KOMODO_INSYNC;
|
extern int32_t KOMODO_INSYNC;
|
||||||
extern void TxToJSON(const CTransaction& tx, const uint256 hashBlock, UniValue& entry);
|
extern void TxToJSON(const CTransaction& tx, const uint256 hashBlock, UniValue& entry);
|
||||||
void ScriptPubKeyToJSON(const CScript& scriptPubKey, UniValue& out, bool fIncludeHex);
|
void ScriptPubKeyToJSON(const CScript& scriptPubKey, UniValue& out, bool fIncludeHex);
|
||||||
|
int32_t komodo_notarized_height(int32_t *prevMoMheightp,uint256 *hashp,uint256 *txidp);
|
||||||
#include "komodo_defs.h"
|
#include "komodo_defs.h"
|
||||||
#include "komodo_structs.h"
|
#include "komodo_structs.h"
|
||||||
|
|
||||||
@@ -133,6 +134,9 @@ UniValue blockheaderToJSON(const CBlockIndex* blockindex)
|
|||||||
result.push_back(Pair("error", "null blockhash"));
|
result.push_back(Pair("error", "null blockhash"));
|
||||||
return(result);
|
return(result);
|
||||||
}
|
}
|
||||||
|
uint256 notarized_hash,notarized_desttxid; int32_t prevMoMheight,notarized_height;
|
||||||
|
notarized_height = komodo_notarized_height(&prevMoMheight,¬arized_hash,¬arized_desttxid);
|
||||||
|
result.push_back(Pair("last_notarized_height", notarized_height));
|
||||||
result.push_back(Pair("hash", blockindex->GetBlockHash().GetHex()));
|
result.push_back(Pair("hash", blockindex->GetBlockHash().GetHex()));
|
||||||
int confirmations = -1;
|
int confirmations = -1;
|
||||||
// Only report confirmations if the block is on the main chain
|
// Only report confirmations if the block is on the main chain
|
||||||
@@ -284,6 +288,9 @@ UniValue blockToDeltasJSON(const CBlock& block, const CBlockIndex* blockindex)
|
|||||||
UniValue blockToJSON(const CBlock& block, const CBlockIndex* blockindex, bool txDetails = false)
|
UniValue blockToJSON(const CBlock& block, const CBlockIndex* blockindex, bool txDetails = false)
|
||||||
{
|
{
|
||||||
UniValue result(UniValue::VOBJ);
|
UniValue result(UniValue::VOBJ);
|
||||||
|
uint256 notarized_hash,notarized_desttxid; int32_t prevMoMheight,notarized_height;
|
||||||
|
notarized_height = komodo_notarized_height(&prevMoMheight,¬arized_hash,¬arized_desttxid);
|
||||||
|
result.push_back(Pair("last_notarized_height", notarized_height));
|
||||||
result.push_back(Pair("hash", block.GetHash().GetHex()));
|
result.push_back(Pair("hash", block.GetHash().GetHex()));
|
||||||
int confirmations = -1;
|
int confirmations = -1;
|
||||||
// Only report confirmations if the block is on the main chain
|
// Only report confirmations if the block is on the main chain
|
||||||
|
|||||||
@@ -60,7 +60,8 @@ arith_uint256 komodo_PoWtarget(int32_t *percPoSp,arith_uint256 target,int32_t he
|
|||||||
* or over the difficulty averaging window if 'lookup' is nonpositive.
|
* or over the difficulty averaging window if 'lookup' is nonpositive.
|
||||||
* If 'height' is nonnegative, compute the estimate at the time when a given block was found.
|
* If 'height' is nonnegative, compute the estimate at the time when a given block was found.
|
||||||
*/
|
*/
|
||||||
int64_t GetNetworkHashPS(int lookup, int height) {
|
int64_t GetNetworkHashPS(int lookup, int height)
|
||||||
|
{
|
||||||
CBlockIndex *pb = chainActive.LastTip();
|
CBlockIndex *pb = chainActive.LastTip();
|
||||||
|
|
||||||
if (height >= 0 && height < chainActive.Height())
|
if (height >= 0 && height < chainActive.Height())
|
||||||
|
|||||||
@@ -33,9 +33,11 @@
|
|||||||
|
|
||||||
#include <boost/filesystem/path.hpp>
|
#include <boost/filesystem/path.hpp>
|
||||||
|
|
||||||
// If CCLIB fails to compile with this, use the one below.
|
#ifdef BUILD_ROGUE
|
||||||
#include <db_cxx.h>
|
#include "../depends/x86_64-unknown-linux-gnu/include/db_cxx.h"
|
||||||
//#include "../depends/x86_64-unknown-linux-gnu/include/db_cxx.h"
|
#else
|
||||||
|
#include <db_cxx.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
extern unsigned int nWalletDBUpdated;
|
extern unsigned int nWalletDBUpdated;
|
||||||
|
|
||||||
|
|||||||
@@ -106,7 +106,7 @@ CONFIG_SITE="$PWD/depends/$HOST/share/config.site" ./configure "$HARDENING_ARG"
|
|||||||
WD=$PWD
|
WD=$PWD
|
||||||
cd src/cc
|
cd src/cc
|
||||||
echo $PWD
|
echo $PWD
|
||||||
./makecclib
|
./makerogue
|
||||||
cd $WD
|
cd $WD
|
||||||
|
|
||||||
"$MAKE" "$@" V=1
|
"$MAKE" "$@" V=1
|
||||||
|
|||||||
Reference in New Issue
Block a user