From af6e26a2880256a667438566034a976ed6f9e230 Mon Sep 17 00:00:00 2001 From: lateminer Date: Mon, 4 Dec 2017 23:43:49 +0300 Subject: [PATCH 1/6] Get staking parameters from chainparams.cpp nStakeTimestampMask, nStakeMinConfirmations, nStakeMinAge --- src/chainparams.cpp | 4 +++- src/consensus/params.h | 2 ++ src/main.cpp | 4 ++-- src/miner.cpp | 4 ++-- src/pos.cpp | 2 +- src/pos.h | 6 ------ src/rpcmining.cpp | 2 +- src/wallet/wallet.cpp | 6 +++--- 8 files changed, 14 insertions(+), 16 deletions(-) diff --git a/src/chainparams.cpp b/src/chainparams.cpp index 2979a7502..e69b8c7a5 100644 --- a/src/chainparams.cpp +++ b/src/chainparams.cpp @@ -101,7 +101,9 @@ public: consensus.nProtocolV2Time = 1407053625; consensus.nProtocolV3Time = 1444028400; consensus.nLastPOWBlock = 10000; - consensus.nStakeTimestampMask = 0xf; + consensus.nStakeTimestampMask = 0xf; // 15 + consensus.nStakeMinConfirmations = 500; + consensus.nStakeMinAge = 8 * 60 * 60; // 8 hours /** * The message start string is designed to be unlikely to occur in normal data. diff --git a/src/consensus/params.h b/src/consensus/params.h index b9813a2ab..f2d916869 100644 --- a/src/consensus/params.h +++ b/src/consensus/params.h @@ -70,6 +70,8 @@ struct Params { unsigned int GetTargetSpacing(int nHeight) { return IsProtocolV2(nHeight) ? 64 : 60; } int nLastPOWBlock; int nStakeTimestampMask; + int nStakeMinConfirmations; + unsigned int nStakeMinAge; }; } // namespace Consensus diff --git a/src/main.cpp b/src/main.cpp index 8f1c08a83..166e1e8ba 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -3437,7 +3437,7 @@ bool GetCoinAge(const CTransaction& tx, CBlockTreeDB& txdb, const CBlockIndex* p if (Params().GetConsensus().IsProtocolV3(tx.nTime)) { int nSpendDepth; - if (IsConfirmedInNPrevBlocks(txindex, pindexPrev, nStakeMinConfirmations - 1, nSpendDepth)) + if (IsConfirmedInNPrevBlocks(txindex, pindexPrev, Params().GetConsensus().nStakeMinConfirmations - 1, nSpendDepth)) { LogPrint("coinage", "coin age skip nSpendDepth=%d\n", nSpendDepth + 1); continue; // only count coins meeting min confirmations requirement @@ -3450,7 +3450,7 @@ bool GetCoinAge(const CTransaction& tx, CBlockTreeDB& txdb, const CBlockIndex* p const CDiskBlockPos& pos = CDiskBlockPos(txindex.nFile, txindex.nPos); if (!ReadBlockFromDisk(block, pos, Params().GetConsensus())) return false; // unable to read block of previous transaction - if (block.GetBlockTime() + nStakeMinAge > tx.nTime) + if (block.GetBlockTime() + Params().GetConsensus().nStakeMinAge > tx.nTime) continue; // only count coins meeting min age requirement } diff --git a/src/miner.cpp b/src/miner.cpp index 48f269d81..5d793e46f 100644 --- a/src/miner.cpp +++ b/src/miner.cpp @@ -417,7 +417,7 @@ void static BitcoinMiner(const CChainParams& chainparams) } //check the block height - if (chainActive.Tip()->nHeight > Params().LastPOWBlock() + nStakeMinConfirmations) + if (chainActive.Tip()->nHeight > Params().LastPOWBlock() + Params().GetConsensus().nStakeMinConfirmations) { // The stake is confirmed, stop the PoW miner throw boost::thread_interrupted(); @@ -568,7 +568,7 @@ bool SignBlock(CBlock& block, CWallet& wallet, int64_t& nFees) CMutableTransaction txCoinBase(block.vtx[0]); CMutableTransaction txCoinStake; txCoinStake.nTime = GetAdjustedTime(); - txCoinStake.nTime &= ~STAKE_TIMESTAMP_MASK; + txCoinStake.nTime &= ~Params().GetConsensus().nStakeTimestampMask; int64_t nSearchTime = txCoinStake.nTime; // search to current time diff --git a/src/pos.cpp b/src/pos.cpp index 4554db3a7..55957b7db 100644 --- a/src/pos.cpp +++ b/src/pos.cpp @@ -132,7 +132,7 @@ bool CheckProofOfStake(CBlockIndex* pindexPrev, const CTransaction& tx, unsigned // Min age requirement int nDepth; - if (IsConfirmedInNPrevBlocks(txindex, pindexPrev, nStakeMinConfirmations - 1, nDepth)) + if (IsConfirmedInNPrevBlocks(txindex, pindexPrev, Params().GetConsensus().nStakeMinConfirmations - 1, nDepth)) return state.DoS(100, error("CheckProofOfStake() : tried to stake at depth %d", nDepth + 1)); if (!CheckStakeKernelHash(pindexPrev, nBits, new CCoins(txPrev, pindexPrev->nHeight), txin.prevout, tx.nTime)) diff --git a/src/pos.h b/src/pos.h index eb3532b30..827c85bae 100644 --- a/src/pos.h +++ b/src/pos.h @@ -21,12 +21,6 @@ using namespace std; /** Compute the hash modifier for proof-of-stake */ uint256 ComputeStakeModifier(const CBlockIndex* pindexPrev, const uint256& kernel); -static const int nStakeMinConfirmations = 500; -static const unsigned int nStakeMinAge = 8 * 60 * 60; // 8 hours -// To decrease granularity of timestamp -// Supposed to be 2^n-1 -static const int STAKE_TIMESTAMP_MASK = 15; - // Check whether the coinstake timestamp meets protocol bool CheckCoinStakeTimestamp(int64_t nTimeBlock, int64_t nTimeTx); bool CheckStakeBlockTimestamp(int64_t nTimeBlock); diff --git a/src/rpcmining.cpp b/src/rpcmining.cpp index 50c4028e8..b7ee47c16 100644 --- a/src/rpcmining.cpp +++ b/src/rpcmining.cpp @@ -769,7 +769,7 @@ UniValue checkkernel(const UniValue& params, bool fHelp) CBlockHeader blockHeader = pindexPrev->GetBlockHeader(); unsigned int nBits = GetNextTargetRequired(pindexPrev, &blockHeader, true, Params().GetConsensus()); int64_t nTime = GetAdjustedTime(); - nTime &= ~STAKE_TIMESTAMP_MASK; + nTime &= ~Params().GetConsensus().nStakeTimestampMask; for (unsigned int idx = 0; idx < inputs.size(); idx++) { const UniValue& input = inputs[idx]; diff --git a/src/wallet/wallet.cpp b/src/wallet/wallet.cpp index 255fe8610..1209c3fec 100644 --- a/src/wallet/wallet.cpp +++ b/src/wallet/wallet.cpp @@ -580,7 +580,7 @@ void CWallet::AvailableCoinsForStaking(std::vector& vCoins) const if (nDepth < 1) continue; - if (nDepth < nStakeMinConfirmations) + if (nDepth < Params().GetConsensus().nStakeMinConfirmations) continue; if (pcoin->GetBlocksToMaturity() > 0) @@ -654,7 +654,7 @@ bool CheckKernel(CBlockIndex* pindexPrev, unsigned int nBits, int64_t nTime, con return false; int nDepth; - if (IsConfirmedInNPrevBlocks(txindex, pindexPrev, nStakeMinConfirmations - 1, nDepth)) + if (IsConfirmedInNPrevBlocks(txindex, pindexPrev, Params().GetConsensus().nStakeMinConfirmations - 1, nDepth)) return false; if (pBlockTime) @@ -3315,7 +3315,7 @@ uint64_t CWallet::GetStakeWeight() const LOCK2(cs_main, cs_wallet); BOOST_FOREACH(PAIRTYPE(const CWalletTx*, unsigned int) pcoin, setCoins) { - if (pcoin.first->GetDepthInMainChain() >= nStakeMinConfirmations) + if (pcoin.first->GetDepthInMainChain() >= Params().GetConsensus().nStakeMinConfirmations) nWeight += pcoin.first->vout[pcoin.second].nValue; } From 0252c5cea3dcdd0b6abcab0dbbd2703da10067b2 Mon Sep 17 00:00:00 2001 From: lateminer Date: Sun, 17 Dec 2017 13:18:04 +0300 Subject: [PATCH 2/6] Replace STAKE_MIN_CONFIRMATIONS... ...with nStakeMinConfirmations --- src/main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.cpp b/src/main.cpp index 166e1e8ba..4bbc94f00 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -2476,7 +2476,7 @@ bool ConnectBlock(const CBlock& block, CValidationState& state, CBlockIndex* pin REJECT_INVALID, "bad-cs-kernel"); // Check proof-of-stake min confirmations - if (pindex->nHeight - coins->nHeight < STAKE_MIN_CONFIRMATIONS) + if (pindex->nHeight - coins->nHeight < Params().GetConsensus().nStakeMinConfirmations) return state.DoS(100, error("%s: tried to stake at depth %d", __func__, pindex->nHeight - coins->nHeight), REJECT_INVALID, "bad-cs-premature"); From f536a8126eaae7ac9e16e4166f6518242355ca70 Mon Sep 17 00:00:00 2001 From: lateminer Date: Sun, 17 Dec 2017 15:21:59 +0300 Subject: [PATCH 3/6] Replace COINBASE_MATURITY... ...with nCoinbaseMaturity --- src/chainparams.cpp | 1 + src/consensus/params.h | 1 + src/main.cpp | 4 ++-- src/qt/transactiondesc.cpp | 2 +- src/test/test_bitcoin.cpp | 2 +- src/txmempool.cpp | 2 +- src/wallet/wallet.cpp | 2 +- 7 files changed, 8 insertions(+), 6 deletions(-) diff --git a/src/chainparams.cpp b/src/chainparams.cpp index e69b8c7a5..0cc6cc8e5 100644 --- a/src/chainparams.cpp +++ b/src/chainparams.cpp @@ -102,6 +102,7 @@ public: consensus.nProtocolV3Time = 1444028400; consensus.nLastPOWBlock = 10000; consensus.nStakeTimestampMask = 0xf; // 15 + consensus.nCoinbaseMaturity = 500; consensus.nStakeMinConfirmations = 500; consensus.nStakeMinAge = 8 * 60 * 60; // 8 hours diff --git a/src/consensus/params.h b/src/consensus/params.h index f2d916869..4921c7a5f 100644 --- a/src/consensus/params.h +++ b/src/consensus/params.h @@ -70,6 +70,7 @@ struct Params { unsigned int GetTargetSpacing(int nHeight) { return IsProtocolV2(nHeight) ? 64 : 60; } int nLastPOWBlock; int nStakeTimestampMask; + int nCoinbaseMaturity; int nStakeMinConfirmations; unsigned int nStakeMinAge; }; diff --git a/src/main.cpp b/src/main.cpp index 4bbc94f00..66a12d5ea 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -1915,7 +1915,7 @@ bool CheckTxInputs(const CTransaction& tx, CValidationState& state, const CCoins // If prev is coinbase or coinstake, check that it's matured if (coins->IsCoinBase() || coins->IsCoinStake()) { - if (nSpendHeight - coins->nHeight < COINBASE_MATURITY) + if (nSpendHeight - coins->nHeight < Params().nCoinbaseMaturity) return state.Invalid( error("CheckInputs(): tried to spend %s at depth %d", coins->IsCoinBase() ? "coinbase" : "coinstake", nSpendHeight - coins->nHeight), REJECT_INVALID, "bad-txns-premature-spend-of-coinbase"); @@ -2476,7 +2476,7 @@ bool ConnectBlock(const CBlock& block, CValidationState& state, CBlockIndex* pin REJECT_INVALID, "bad-cs-kernel"); // Check proof-of-stake min confirmations - if (pindex->nHeight - coins->nHeight < Params().GetConsensus().nStakeMinConfirmations) + if (pindex->nHeight - coins->nHeight < chainparams.GetConsensus().nStakeMinConfirmations) return state.DoS(100, error("%s: tried to stake at depth %d", __func__, pindex->nHeight - coins->nHeight), REJECT_INVALID, "bad-cs-premature"); diff --git a/src/qt/transactiondesc.cpp b/src/qt/transactiondesc.cpp index 56ac2bffe..8d82e8305 100644 --- a/src/qt/transactiondesc.cpp +++ b/src/qt/transactiondesc.cpp @@ -262,7 +262,7 @@ QString TransactionDesc::toHTML(CWallet *wallet, CWalletTx &wtx, TransactionReco if (wtx.IsCoinBase()) { - quint32 numBlocksToMaturity = COINBASE_MATURITY + 1; + quint32 numBlocksToMaturity = Params().GetConsensus().nCoinbaseMaturity + 1; strHTML += "
" + tr("Generated coins must mature %1 blocks before they can be spent. When you generated this block, it was broadcast to the network to be added to the block chain. If it fails to get into the chain, its state will change to \"not accepted\" and it won't be spendable. This may occasionally happen if another node generates a block within a few seconds of yours.").arg(QString::number(numBlocksToMaturity)) + "
"; } diff --git a/src/test/test_bitcoin.cpp b/src/test/test_bitcoin.cpp index eb7400cf5..ccce6e071 100644 --- a/src/test/test_bitcoin.cpp +++ b/src/test/test_bitcoin.cpp @@ -101,7 +101,7 @@ TestChain100Setup::TestChain100Setup() : TestingSetup(CBaseChainParams::REGTEST) // Generate a 100-block chain: coinbaseKey.MakeNewKey(true); CScript scriptPubKey = CScript() << ToByteVector(coinbaseKey.GetPubKey()) << OP_CHECKSIG; - for (int i = 0; i < COINBASE_MATURITY; i++) + for (int i = 0; i < Params().GetConsensus().nCoinbaseMaturity; i++) { std::vector noTxns; CBlock b = CreateAndProcessBlock(noTxns, scriptPubKey); diff --git a/src/txmempool.cpp b/src/txmempool.cpp index 55356189a..97a335a99 100644 --- a/src/txmempool.cpp +++ b/src/txmempool.cpp @@ -665,7 +665,7 @@ void CTxMemPool::removeForReorg(const CCoinsViewCache *pcoins, unsigned int nMem continue; const CCoins *coins = pcoins->AccessCoins(txin.prevout.hash); if (nCheckFrequency != 0) assert(coins); - if (!coins || (coins->IsCoinBase() || coins->IsCoinStake() && ((signed long)nMemPoolHeight) - coins->nHeight < COINBASE_MATURITY)) { + if (!coins || (coins->IsCoinBase() || coins->IsCoinStake() && ((signed long)nMemPoolHeight) - coins->nHeight < Params().GetConsensus().nCoinbaseMaturity)) { transactionsToRemove.push_back(tx); break; } diff --git a/src/wallet/wallet.cpp b/src/wallet/wallet.cpp index 1209c3fec..aef70773f 100644 --- a/src/wallet/wallet.cpp +++ b/src/wallet/wallet.cpp @@ -3520,7 +3520,7 @@ int CMerkleTx::GetBlocksToMaturity() const { if (!(IsCoinBase() || IsCoinStake())) return 0; - return max(0, (COINBASE_MATURITY+1) - GetDepthInMainChain()); + return max(0, (Params().GetConsensus().nCoinbaseMaturity+1) - GetDepthInMainChain()); } From f303365bd3a35fc26bb1907ffe5bbbb5cfead8b8 Mon Sep 17 00:00:00 2001 From: lateminer Date: Sat, 30 Dec 2017 00:20:44 +0300 Subject: [PATCH 4/6] Build blackcoind instead of bitcoind... ...and so on --- Makefile.am | 20 ++++++++-------- src/Makefile.am | 52 ++++++++++++++++++++--------------------- src/Makefile.qt.include | 32 ++++++++++++------------- 3 files changed, 52 insertions(+), 52 deletions(-) diff --git a/Makefile.am b/Makefile.am index 3d81263e9..759690c0f 100644 --- a/Makefile.am +++ b/Makefile.am @@ -9,14 +9,14 @@ pkgconfigdir = $(libdir)/pkgconfig pkgconfig_DATA = libbitcoinconsensus.pc endif -BITCOIND_BIN=$(top_builddir)/src/bitcoind$(EXEEXT) -BITCOIN_QT_BIN=$(top_builddir)/src/qt/bitcoin-qt$(EXEEXT) -BITCOIN_CLI_BIN=$(top_builddir)/src/bitcoin-cli$(EXEEXT) +BITCOIND_BIN=$(top_builddir)/src/blackcoind$(EXEEXT) +BITCOIN_QT_BIN=$(top_builddir)/src/qt/blackcoin-qt$(EXEEXT) +BITCOIN_CLI_BIN=$(top_builddir)/src/blackcoin-cli$(EXEEXT) WALLET_UTILITY_BIN=$(top_builddir)/src/wallet-utility$(EXEEXT) BITCOIN_WIN_INSTALLER=$(PACKAGE)-$(PACKAGE_VERSION)-win$(WINDOWS_BITS)-setup$(EXEEXT) -OSX_APP=Bitcoin-Qt.app -OSX_DMG=Bitcoin-Core.dmg +OSX_APP=Blackcoin-Qt.app +OSX_DMG=Blackcoin-Lore.dmg OSX_BACKGROUND_IMAGE=background.tiff OSX_DEPLOY_SCRIPT=$(top_srcdir)/contrib/macdeploy/macdeployqtplus OSX_FANCY_PLIST=$(top_srcdir)/contrib/macdeploy/fancy.plist @@ -88,7 +88,7 @@ $(OSX_APP)/Contents/Resources/bitcoin.icns: $(OSX_INSTALLER_ICONS) $(MKDIR_P) $(@D) $(INSTALL_DATA) $< $@ -$(OSX_APP)/Contents/MacOS/Bitcoin-Qt: $(BITCOIN_QT_BIN) +$(OSX_APP)/Contents/MacOS/Blackcoin-Qt: $(BITCOIN_QT_BIN) $(MKDIR_P) $(@D) STRIPPROG="$(STRIP)" $(INSTALL_STRIP_PROGRAM) $< $@ @@ -98,7 +98,7 @@ $(OSX_APP)/Contents/Resources/Base.lproj/InfoPlist.strings: $(OSX_BASE_LPROJ_DIR OSX_APP_BUILT=$(OSX_APP)/Contents/PkgInfo $(OSX_APP)/Contents/Resources/empty.lproj \ $(OSX_APP)/Contents/Resources/bitcoin.icns $(OSX_APP)/Contents/Info.plist \ - $(OSX_APP)/Contents/MacOS/Bitcoin-Qt $(OSX_APP)/Contents/Resources/Base.lproj/InfoPlist.strings + $(OSX_APP)/Contents/MacOS/Blackcoin-Qt $(OSX_APP)/Contents/Resources/Base.lproj/InfoPlist.strings if BUILD_DARWIN $(OSX_DMG): $(OSX_APP_BUILT) $(OSX_PACKAGING) @@ -113,10 +113,10 @@ $(APP_DIST_DIR)/Applications: @rm -f $@ @cd $(@D); $(LN_S) /Applications $(@F) -$(APP_DIST_EXTRAS): $(APP_DIST_DIR)/$(OSX_APP)/Contents/MacOS/Bitcoin-Qt +$(APP_DIST_EXTRAS): $(APP_DIST_DIR)/$(OSX_APP)/Contents/MacOS/Blackcoin-Qt $(OSX_DMG): $(APP_DIST_EXTRAS) - $(GENISOIMAGE) -no-cache-inodes -D -l -probe -V "Bitcoin-Core" -no-pad -r -dir-mode 0755 -apple -o $@ dist + $(GENISOIMAGE) -no-cache-inodes -D -l -probe -V "Blackcoin-Lore" -no-pad -r -dir-mode 0755 -apple -o $@ dist $(APP_DIST_DIR)/.background/$(OSX_BACKGROUND_IMAGE): contrib/macdeploy/$(OSX_BACKGROUND_IMAGE) $(MKDIR_P) $(@D) @@ -124,7 +124,7 @@ $(APP_DIST_DIR)/.background/$(OSX_BACKGROUND_IMAGE): contrib/macdeploy/$(OSX_BAC $(APP_DIST_DIR)/.DS_Store: contrib/macdeploy/DS_Store $(INSTALL) $< $@ -$(APP_DIST_DIR)/$(OSX_APP)/Contents/MacOS/Bitcoin-Qt: $(OSX_APP_BUILT) $(OSX_PACKAGING) +$(APP_DIST_DIR)/$(OSX_APP)/Contents/MacOS/Blackcoin-Qt: $(OSX_APP_BUILT) $(OSX_PACKAGING) INSTALLNAMETOOL=$(INSTALLNAMETOOL) OTOOL=$(OTOOL) STRIP=$(STRIP) $(OSX_DEPLOY_SCRIPT) $(OSX_APP) -translations-dir=$(QT_TRANSLATION_DIR) -add-qt-tr $(OSX_QT_TRANSLATIONS) -verbose 2 deploydir: $(APP_DIST_EXTRAS) diff --git a/src/Makefile.am b/src/Makefile.am index 9d9a1596c..d3713c12a 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -71,11 +71,11 @@ TESTS = BENCHMARKS = if BUILD_BITCOIND - bin_PROGRAMS += bitcoind + bin_PROGRAMS += blackcoind endif if BUILD_BITCOIN_UTILS - bin_PROGRAMS += bitcoin-cli bitcoin-tx + bin_PROGRAMS += blackcoin-cli blackcoin-tx if ENABLE_WALLET bin_PROGRAMS += wallet-utility endif @@ -373,17 +373,17 @@ libbitcoin_cli_a_SOURCES = \ nodist_libbitcoin_util_a_SOURCES = $(srcdir)/obj/build.h # -# bitcoind binary # -bitcoind_SOURCES = bitcoind.cpp -bitcoind_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) -bitcoind_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) -bitcoind_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) +# blackcoind binary # +blackcoind_SOURCES = bitcoind.cpp +blackcoind_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) +blackcoind_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) +blackcoind_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) if TARGET_WINDOWS -bitcoind_SOURCES += bitcoind-res.rc +blackcoind_SOURCES += bitcoind-res.rc endif -bitcoind_LDADD = \ +blackcoind_LDADD = \ $(LIBBITCOIN_SERVER) \ $(LIBBITCOIN_COMMON) \ $(LIBUNIVALUE) \ @@ -395,13 +395,13 @@ bitcoind_LDADD = \ $(LIBMEMENV) \ $(LIBSECP256K1) -bitcoind_LDADD += $(BOOST_LIBS) $(BDB_LIBS) $(SSL_LIBS) $(CRYPTO_LIBS) $(MINIUPNPC_LIBS) $(EVENT_PTHREADS_LIBS) $(EVENT_LIBS) $(ZMQ_LIBS) +blackcoind_LDADD += $(BOOST_LIBS) $(BDB_LIBS) $(SSL_LIBS) $(CRYPTO_LIBS) $(MINIUPNPC_LIBS) $(EVENT_PTHREADS_LIBS) $(EVENT_LIBS) $(ZMQ_LIBS) -# bitcoin-cli binary # -bitcoin_cli_SOURCES = bitcoin-cli.cpp -bitcoin_cli_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) $(EVENT_CFLAGS) -bitcoin_cli_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) -bitcoin_cli_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) +# blackcoin-cli binary # +blackcoin_cli_SOURCES = bitcoin-cli.cpp +blackcoin_cli_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) $(EVENT_CFLAGS) +blackcoin_cli_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) +blackcoin_cli_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) # wallet-utility binary # if ENABLE_WALLET @@ -412,39 +412,39 @@ wallet_utility_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) endif if TARGET_WINDOWS -bitcoin_cli_SOURCES += bitcoin-cli-res.rc +blackcoin_cli_SOURCES += bitcoin-cli-res.rc endif -bitcoin_cli_LDADD = \ +blackcoin_cli_LDADD = \ $(LIBBITCOIN_CLI) \ $(LIBUNIVALUE) \ $(LIBBITCOIN_UTIL) -bitcoin_cli_LDADD += $(BOOST_LIBS) $(SSL_LIBS) $(CRYPTO_LIBS) $(EVENT_LIBS) +blackcoin_cli_LDADD += $(BOOST_LIBS) $(SSL_LIBS) $(CRYPTO_LIBS) $(EVENT_LIBS) if ENABLE_WALLET wallet_utility_LDADD = libbitcoin_wallet.a $(LIBBITCOIN_COMMON) $(LIBBITCOIN_CRYPTO) $(LIBSECP256K1) $(LIBBITCOIN_UTIL) $(BOOST_LIBS) $(BDB_LIBS) $(CRYPTO_LIBS) endif # -# bitcoin-tx binary # -bitcoin_tx_SOURCES = bitcoin-tx.cpp -bitcoin_tx_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) -bitcoin_tx_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) -bitcoin_tx_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) +# blackcoin-tx binary # +blackcoin_tx_SOURCES = bitcoin-tx.cpp +blackcoin_tx_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) +blackcoin_tx_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) +blackcoin_tx_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) if TARGET_WINDOWS -bitcoin_tx_SOURCES += bitcoin-tx-res.rc +blackcoin_tx_SOURCES += bitcoin-tx-res.rc endif -bitcoin_tx_LDADD = \ +blackcoin_tx_LDADD = \ $(LIBUNIVALUE) \ $(LIBBITCOIN_COMMON) \ $(LIBBITCOIN_UTIL) \ $(LIBBITCOIN_CRYPTO) \ $(LIBSECP256K1) -bitcoin_tx_LDADD += $(BOOST_LIBS) $(CRYPTO_LIBS) +blackcoin_tx_LDADD += $(BOOST_LIBS) $(CRYPTO_LIBS) # # bitcoinconsensus library # diff --git a/src/Makefile.qt.include b/src/Makefile.qt.include index d88942d23..0fe4914fe 100644 --- a/src/Makefile.qt.include +++ b/src/Makefile.qt.include @@ -1,4 +1,4 @@ -bin_PROGRAMS += qt/bitcoin-qt +bin_PROGRAMS += qt/blackcoin-qt EXTRA_LIBRARIES += qt/libbitcoinqt.a # bitcoin qt core # @@ -357,37 +357,37 @@ QT_FORMS_H=$(join $(dir $(QT_FORMS_UI)),$(addprefix ui_, $(notdir $(QT_FORMS_UI: # Most files will depend on the forms and moc files as includes. Generate them # before anything else. $(QT_MOC): $(QT_FORMS_H) -$(qt_libbitcoinqt_a_OBJECTS) $(qt_bitcoin_qt_OBJECTS) : | $(QT_MOC) +$(qt_libbitcoinqt_a_OBJECTS) $(qt_blackcoin_qt_OBJECTS) : | $(QT_MOC) #Generating these with a half-written protobuf header leads to wacky results. #This makes sure it's done. $(QT_MOC): $(PROTOBUF_H) $(QT_MOC_CPP): $(PROTOBUF_H) -# bitcoin-qt binary # -qt_bitcoin_qt_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) $(BITCOIN_QT_INCLUDES) \ +# blackcoin-qt binary # +qt_blackcoin_qt_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) $(BITCOIN_QT_INCLUDES) \ $(QT_INCLUDES) $(PROTOBUF_CFLAGS) $(QR_CFLAGS) -qt_bitcoin_qt_CXXFLAGS = $(AM_CXXFLAGS) $(QT_PIE_FLAGS) +qt_blackcoin_qt_CXXFLAGS = $(AM_CXXFLAGS) $(QT_PIE_FLAGS) -qt_bitcoin_qt_SOURCES = qt/bitcoin.cpp +qt_blackcoin_qt_SOURCES = qt/bitcoin.cpp if TARGET_DARWIN - qt_bitcoin_qt_SOURCES += $(BITCOIN_MM) + qt_blackcoin_qt_SOURCES += $(BITCOIN_MM) endif if TARGET_WINDOWS - qt_bitcoin_qt_SOURCES += $(BITCOIN_RC) + qt_blackcoin_qt_SOURCES += $(BITCOIN_RC) endif -qt_bitcoin_qt_LDADD = qt/libbitcoinqt.a $(LIBBITCOIN_SERVER) +qt_blackcoin_qt_LDADD = qt/libbitcoinqt.a $(LIBBITCOIN_SERVER) if ENABLE_WALLET -qt_bitcoin_qt_LDADD += $(LIBBITCOIN_WALLET) +qt_blackcoin_qt_LDADD += $(LIBBITCOIN_WALLET) endif if ENABLE_ZMQ -qt_bitcoin_qt_LDADD += $(LIBBITCOIN_ZMQ) $(ZMQ_LIBS) +qt_blackcoin_qt_LDADD += $(LIBBITCOIN_ZMQ) $(ZMQ_LIBS) endif -qt_bitcoin_qt_LDADD += $(LIBBITCOIN_CLI) $(LIBBITCOIN_COMMON) $(LIBBITCOIN_UTIL) $(LIBBITCOIN_CRYPTO) $(LIBUNIVALUE) $(LIBLEVELDB) $(LIBMEMENV) \ +qt_blackcoin_qt_LDADD += $(LIBBITCOIN_CLI) $(LIBBITCOIN_COMMON) $(LIBBITCOIN_UTIL) $(LIBBITCOIN_CRYPTO) $(LIBUNIVALUE) $(LIBLEVELDB) $(LIBMEMENV) \ $(BOOST_LIBS) $(QT_LIBS) $(QT_DBUS_LIBS) $(QR_LIBS) $(PROTOBUF_LIBS) $(BDB_LIBS) $(SSL_LIBS) $(CRYPTO_LIBS) $(MINIUPNPC_LIBS) $(LIBSECP256K1) \ $(EVENT_PTHREADS_LIBS) $(EVENT_LIBS) -qt_bitcoin_qt_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(QT_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) -qt_bitcoin_qt_LIBTOOLFLAGS = --tag CXX +qt_blackcoin_qt_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(QT_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) +qt_blackcoin_qt_LIBTOOLFLAGS = --tag CXX #locale/foo.ts -> locale/foo.qm QT_QM=$(QT_TS:.ts=.qm) @@ -418,9 +418,9 @@ CLEAN_QT = $(nodist_qt_libbitcoinqt_a_SOURCES) $(QT_QM) $(QT_FORMS_H) qt/*.gcda CLEANFILES += $(CLEAN_QT) bitcoin_qt_clean: FORCE - rm -f $(CLEAN_QT) $(qt_libbitcoinqt_a_OBJECTS) $(qt_bitcoin_qt_OBJECTS) qt/bitcoin-qt$(EXEEXT) $(LIBBITCOINQT) + rm -f $(CLEAN_QT) $(qt_libbitcoinqt_a_OBJECTS) $(qt_blackcoin_qt_OBJECTS) qt/blackcoin-qt$(EXEEXT) $(LIBBITCOINQT) -bitcoin_qt : qt/bitcoin-qt$(EXEEXT) +bitcoin_qt : qt/blackcoin-qt$(EXEEXT) ui_%.h: %.ui @test -f $(UIC) From d0de6a0e31213746d6c7144481ef7f505d508261 Mon Sep 17 00:00:00 2001 From: lateminer Date: Sat, 30 Dec 2017 00:21:58 +0300 Subject: [PATCH 5/6] Use "blackcoin:" URI instead of "bitcoin:"... ...and so on --- src/bitcoind.cpp | 10 +++++----- src/qt/openuridialog.cpp | 4 ++-- src/qt/paymentserver.cpp | 4 ++-- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/bitcoind.cpp b/src/bitcoind.cpp index 3b6608c95..a8cc256bc 100644 --- a/src/bitcoind.cpp +++ b/src/bitcoind.cpp @@ -74,7 +74,7 @@ bool AppInit(int argc, char* argv[]) // Process help and version before taking care about datadir if (mapArgs.count("-?") || mapArgs.count("-h") || mapArgs.count("-help") || mapArgs.count("-version")) { - std::string strUsage = _("Bitcoin Core Daemon") + " " + _("version") + " " + FormatFullVersion() + "\n"; + std::string strUsage = _("Blackcoin Lore Daemon") + " " + _("version") + " " + FormatFullVersion() + "\n"; if (mapArgs.count("-version")) { @@ -83,7 +83,7 @@ bool AppInit(int argc, char* argv[]) else { strUsage += "\n" + _("Usage:") + "\n" + - " bitcoind [options] " + _("Start Bitcoin Core Daemon") + "\n"; + " blackcoind [options] " + _("Start Blackcoin Lore Daemon") + "\n"; strUsage += "\n" + HelpMessage(HMM_BITCOIND); } @@ -117,19 +117,19 @@ bool AppInit(int argc, char* argv[]) // Command-line RPC bool fCommandLine = false; for (int i = 1; i < argc; i++) - if (!IsSwitchChar(argv[i][0]) && !boost::algorithm::istarts_with(argv[i], "bitcoin:")) + if (!IsSwitchChar(argv[i][0]) && !boost::algorithm::istarts_with(argv[i], "blackcoin:")) fCommandLine = true; if (fCommandLine) { - fprintf(stderr, "Error: There is no RPC client functionality in bitcoind anymore. Use the bitcoin-cli utility instead.\n"); + fprintf(stderr, "Error: There is no RPC client functionality in blackcoind anymore. Use the blackcoin-cli utility instead.\n"); exit(1); } #ifndef WIN32 fDaemon = GetBoolArg("-daemon", false); if (fDaemon) { - fprintf(stdout, "Bitcoin server starting\n"); + fprintf(stdout, "Blackcoin server starting\n"); // Daemonize pid_t pid = fork(); diff --git a/src/qt/openuridialog.cpp b/src/qt/openuridialog.cpp index 1c843aecb..80d0b8228 100644 --- a/src/qt/openuridialog.cpp +++ b/src/qt/openuridialog.cpp @@ -16,7 +16,7 @@ OpenURIDialog::OpenURIDialog(QWidget *parent) : { ui->setupUi(this); #if QT_VERSION >= 0x040700 - ui->uriEdit->setPlaceholderText("bitcoin:"); + ui->uriEdit->setPlaceholderText("blackcoin:"); #endif } @@ -48,5 +48,5 @@ void OpenURIDialog::on_selectFileButton_clicked() if(filename.isEmpty()) return; QUrl fileUri = QUrl::fromLocalFile(filename); - ui->uriEdit->setText("bitcoin:?r=" + QUrl::toPercentEncoding(fileUri.toString())); + ui->uriEdit->setText("blackcoin:?r=" + QUrl::toPercentEncoding(fileUri.toString())); } diff --git a/src/qt/paymentserver.cpp b/src/qt/paymentserver.cpp index 6dd22528e..a8b346808 100644 --- a/src/qt/paymentserver.cpp +++ b/src/qt/paymentserver.cpp @@ -47,7 +47,7 @@ #endif const int BITCOIN_IPC_CONNECT_TIMEOUT = 1000; // milliseconds -const QString BITCOIN_IPC_PREFIX("bitcoin:"); +const QString BITCOIN_IPC_PREFIX("blackcoin:"); // BIP70 payment protocol messages const char* BIP70_MESSAGE_PAYMENTACK = "PaymentACK"; const char* BIP70_MESSAGE_PAYMENTREQUEST = "PaymentRequest"; @@ -326,7 +326,7 @@ PaymentServer::PaymentServer(QObject* parent, bool startLocalServer) : if (!uriServer->listen(name)) { // constructor is called early in init, so don't use "Q_EMIT message()" here QMessageBox::critical(0, tr("Payment request error"), - tr("Cannot start bitcoin: click-to-pay handler")); + tr("Cannot start blackcoin: click-to-pay handler")); } else { connect(uriServer, SIGNAL(newConnection()), this, SLOT(handleURIConnection())); From 02db6a0dd9e9688bb29436aaa82dc45bab9470e3 Mon Sep 17 00:00:00 2001 From: lateminer Date: Sat, 30 Dec 2017 12:48:59 +0300 Subject: [PATCH 6/6] Use Lore instead of Blackcoin --- Makefile.am | 16 ++++++------- src/Makefile.am | 52 ++++++++++++++++++++--------------------- src/Makefile.qt.include | 32 ++++++++++++------------- src/bitcoind.cpp | 4 ++-- 4 files changed, 52 insertions(+), 52 deletions(-) diff --git a/Makefile.am b/Makefile.am index 759690c0f..643e048d0 100644 --- a/Makefile.am +++ b/Makefile.am @@ -9,13 +9,13 @@ pkgconfigdir = $(libdir)/pkgconfig pkgconfig_DATA = libbitcoinconsensus.pc endif -BITCOIND_BIN=$(top_builddir)/src/blackcoind$(EXEEXT) -BITCOIN_QT_BIN=$(top_builddir)/src/qt/blackcoin-qt$(EXEEXT) -BITCOIN_CLI_BIN=$(top_builddir)/src/blackcoin-cli$(EXEEXT) +BITCOIND_BIN=$(top_builddir)/src/lored$(EXEEXT) +BITCOIN_QT_BIN=$(top_builddir)/src/qt/lore-qt$(EXEEXT) +BITCOIN_CLI_BIN=$(top_builddir)/src/lore-cli$(EXEEXT) WALLET_UTILITY_BIN=$(top_builddir)/src/wallet-utility$(EXEEXT) BITCOIN_WIN_INSTALLER=$(PACKAGE)-$(PACKAGE_VERSION)-win$(WINDOWS_BITS)-setup$(EXEEXT) -OSX_APP=Blackcoin-Qt.app +OSX_APP=Lore-Qt.app OSX_DMG=Blackcoin-Lore.dmg OSX_BACKGROUND_IMAGE=background.tiff OSX_DEPLOY_SCRIPT=$(top_srcdir)/contrib/macdeploy/macdeployqtplus @@ -88,7 +88,7 @@ $(OSX_APP)/Contents/Resources/bitcoin.icns: $(OSX_INSTALLER_ICONS) $(MKDIR_P) $(@D) $(INSTALL_DATA) $< $@ -$(OSX_APP)/Contents/MacOS/Blackcoin-Qt: $(BITCOIN_QT_BIN) +$(OSX_APP)/Contents/MacOS/Lore-Qt: $(BITCOIN_QT_BIN) $(MKDIR_P) $(@D) STRIPPROG="$(STRIP)" $(INSTALL_STRIP_PROGRAM) $< $@ @@ -98,7 +98,7 @@ $(OSX_APP)/Contents/Resources/Base.lproj/InfoPlist.strings: $(OSX_BASE_LPROJ_DIR OSX_APP_BUILT=$(OSX_APP)/Contents/PkgInfo $(OSX_APP)/Contents/Resources/empty.lproj \ $(OSX_APP)/Contents/Resources/bitcoin.icns $(OSX_APP)/Contents/Info.plist \ - $(OSX_APP)/Contents/MacOS/Blackcoin-Qt $(OSX_APP)/Contents/Resources/Base.lproj/InfoPlist.strings + $(OSX_APP)/Contents/MacOS/Lore-Qt $(OSX_APP)/Contents/Resources/Base.lproj/InfoPlist.strings if BUILD_DARWIN $(OSX_DMG): $(OSX_APP_BUILT) $(OSX_PACKAGING) @@ -113,7 +113,7 @@ $(APP_DIST_DIR)/Applications: @rm -f $@ @cd $(@D); $(LN_S) /Applications $(@F) -$(APP_DIST_EXTRAS): $(APP_DIST_DIR)/$(OSX_APP)/Contents/MacOS/Blackcoin-Qt +$(APP_DIST_EXTRAS): $(APP_DIST_DIR)/$(OSX_APP)/Contents/MacOS/Lore-Qt $(OSX_DMG): $(APP_DIST_EXTRAS) $(GENISOIMAGE) -no-cache-inodes -D -l -probe -V "Blackcoin-Lore" -no-pad -r -dir-mode 0755 -apple -o $@ dist @@ -124,7 +124,7 @@ $(APP_DIST_DIR)/.background/$(OSX_BACKGROUND_IMAGE): contrib/macdeploy/$(OSX_BAC $(APP_DIST_DIR)/.DS_Store: contrib/macdeploy/DS_Store $(INSTALL) $< $@ -$(APP_DIST_DIR)/$(OSX_APP)/Contents/MacOS/Blackcoin-Qt: $(OSX_APP_BUILT) $(OSX_PACKAGING) +$(APP_DIST_DIR)/$(OSX_APP)/Contents/MacOS/Lore-Qt: $(OSX_APP_BUILT) $(OSX_PACKAGING) INSTALLNAMETOOL=$(INSTALLNAMETOOL) OTOOL=$(OTOOL) STRIP=$(STRIP) $(OSX_DEPLOY_SCRIPT) $(OSX_APP) -translations-dir=$(QT_TRANSLATION_DIR) -add-qt-tr $(OSX_QT_TRANSLATIONS) -verbose 2 deploydir: $(APP_DIST_EXTRAS) diff --git a/src/Makefile.am b/src/Makefile.am index d3713c12a..b63bdfc99 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -71,11 +71,11 @@ TESTS = BENCHMARKS = if BUILD_BITCOIND - bin_PROGRAMS += blackcoind + bin_PROGRAMS += lored endif if BUILD_BITCOIN_UTILS - bin_PROGRAMS += blackcoin-cli blackcoin-tx + bin_PROGRAMS += lore-cli lore-tx if ENABLE_WALLET bin_PROGRAMS += wallet-utility endif @@ -373,17 +373,17 @@ libbitcoin_cli_a_SOURCES = \ nodist_libbitcoin_util_a_SOURCES = $(srcdir)/obj/build.h # -# blackcoind binary # -blackcoind_SOURCES = bitcoind.cpp -blackcoind_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) -blackcoind_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) -blackcoind_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) +# lored binary # +lored_SOURCES = bitcoind.cpp +lored_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) +lored_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) +lored_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) if TARGET_WINDOWS -blackcoind_SOURCES += bitcoind-res.rc +lored_SOURCES += bitcoind-res.rc endif -blackcoind_LDADD = \ +lored_LDADD = \ $(LIBBITCOIN_SERVER) \ $(LIBBITCOIN_COMMON) \ $(LIBUNIVALUE) \ @@ -395,13 +395,13 @@ blackcoind_LDADD = \ $(LIBMEMENV) \ $(LIBSECP256K1) -blackcoind_LDADD += $(BOOST_LIBS) $(BDB_LIBS) $(SSL_LIBS) $(CRYPTO_LIBS) $(MINIUPNPC_LIBS) $(EVENT_PTHREADS_LIBS) $(EVENT_LIBS) $(ZMQ_LIBS) +lored_LDADD += $(BOOST_LIBS) $(BDB_LIBS) $(SSL_LIBS) $(CRYPTO_LIBS) $(MINIUPNPC_LIBS) $(EVENT_PTHREADS_LIBS) $(EVENT_LIBS) $(ZMQ_LIBS) -# blackcoin-cli binary # -blackcoin_cli_SOURCES = bitcoin-cli.cpp -blackcoin_cli_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) $(EVENT_CFLAGS) -blackcoin_cli_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) -blackcoin_cli_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) +# lore-cli binary # +lore_cli_SOURCES = bitcoin-cli.cpp +lore_cli_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) $(EVENT_CFLAGS) +lore_cli_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) +lore_cli_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) # wallet-utility binary # if ENABLE_WALLET @@ -412,39 +412,39 @@ wallet_utility_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) endif if TARGET_WINDOWS -blackcoin_cli_SOURCES += bitcoin-cli-res.rc +lore_cli_SOURCES += bitcoin-cli-res.rc endif -blackcoin_cli_LDADD = \ +lore_cli_LDADD = \ $(LIBBITCOIN_CLI) \ $(LIBUNIVALUE) \ $(LIBBITCOIN_UTIL) -blackcoin_cli_LDADD += $(BOOST_LIBS) $(SSL_LIBS) $(CRYPTO_LIBS) $(EVENT_LIBS) +lore_cli_LDADD += $(BOOST_LIBS) $(SSL_LIBS) $(CRYPTO_LIBS) $(EVENT_LIBS) if ENABLE_WALLET wallet_utility_LDADD = libbitcoin_wallet.a $(LIBBITCOIN_COMMON) $(LIBBITCOIN_CRYPTO) $(LIBSECP256K1) $(LIBBITCOIN_UTIL) $(BOOST_LIBS) $(BDB_LIBS) $(CRYPTO_LIBS) endif # -# blackcoin-tx binary # -blackcoin_tx_SOURCES = bitcoin-tx.cpp -blackcoin_tx_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) -blackcoin_tx_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) -blackcoin_tx_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) +# lore-tx binary # +lore_tx_SOURCES = bitcoin-tx.cpp +lore_tx_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) +lore_tx_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS) +lore_tx_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) if TARGET_WINDOWS -blackcoin_tx_SOURCES += bitcoin-tx-res.rc +lore_tx_SOURCES += bitcoin-tx-res.rc endif -blackcoin_tx_LDADD = \ +lore_tx_LDADD = \ $(LIBUNIVALUE) \ $(LIBBITCOIN_COMMON) \ $(LIBBITCOIN_UTIL) \ $(LIBBITCOIN_CRYPTO) \ $(LIBSECP256K1) -blackcoin_tx_LDADD += $(BOOST_LIBS) $(CRYPTO_LIBS) +lore_tx_LDADD += $(BOOST_LIBS) $(CRYPTO_LIBS) # # bitcoinconsensus library # diff --git a/src/Makefile.qt.include b/src/Makefile.qt.include index 0fe4914fe..135ff070b 100644 --- a/src/Makefile.qt.include +++ b/src/Makefile.qt.include @@ -1,4 +1,4 @@ -bin_PROGRAMS += qt/blackcoin-qt +bin_PROGRAMS += qt/lore-qt EXTRA_LIBRARIES += qt/libbitcoinqt.a # bitcoin qt core # @@ -357,37 +357,37 @@ QT_FORMS_H=$(join $(dir $(QT_FORMS_UI)),$(addprefix ui_, $(notdir $(QT_FORMS_UI: # Most files will depend on the forms and moc files as includes. Generate them # before anything else. $(QT_MOC): $(QT_FORMS_H) -$(qt_libbitcoinqt_a_OBJECTS) $(qt_blackcoin_qt_OBJECTS) : | $(QT_MOC) +$(qt_libbitcoinqt_a_OBJECTS) $(qt_lore_qt_OBJECTS) : | $(QT_MOC) #Generating these with a half-written protobuf header leads to wacky results. #This makes sure it's done. $(QT_MOC): $(PROTOBUF_H) $(QT_MOC_CPP): $(PROTOBUF_H) -# blackcoin-qt binary # -qt_blackcoin_qt_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) $(BITCOIN_QT_INCLUDES) \ +# lore-qt binary # +qt_lore_qt_CPPFLAGS = $(AM_CPPFLAGS) $(BITCOIN_INCLUDES) $(BITCOIN_QT_INCLUDES) \ $(QT_INCLUDES) $(PROTOBUF_CFLAGS) $(QR_CFLAGS) -qt_blackcoin_qt_CXXFLAGS = $(AM_CXXFLAGS) $(QT_PIE_FLAGS) +qt_lore_qt_CXXFLAGS = $(AM_CXXFLAGS) $(QT_PIE_FLAGS) -qt_blackcoin_qt_SOURCES = qt/bitcoin.cpp +qt_lore_qt_SOURCES = qt/bitcoin.cpp if TARGET_DARWIN - qt_blackcoin_qt_SOURCES += $(BITCOIN_MM) + qt_lore_qt_SOURCES += $(BITCOIN_MM) endif if TARGET_WINDOWS - qt_blackcoin_qt_SOURCES += $(BITCOIN_RC) + qt_lore_qt_SOURCES += $(BITCOIN_RC) endif -qt_blackcoin_qt_LDADD = qt/libbitcoinqt.a $(LIBBITCOIN_SERVER) +qt_lore_qt_LDADD = qt/libbitcoinqt.a $(LIBBITCOIN_SERVER) if ENABLE_WALLET -qt_blackcoin_qt_LDADD += $(LIBBITCOIN_WALLET) +qt_lore_qt_LDADD += $(LIBBITCOIN_WALLET) endif if ENABLE_ZMQ -qt_blackcoin_qt_LDADD += $(LIBBITCOIN_ZMQ) $(ZMQ_LIBS) +qt_lore_qt_LDADD += $(LIBBITCOIN_ZMQ) $(ZMQ_LIBS) endif -qt_blackcoin_qt_LDADD += $(LIBBITCOIN_CLI) $(LIBBITCOIN_COMMON) $(LIBBITCOIN_UTIL) $(LIBBITCOIN_CRYPTO) $(LIBUNIVALUE) $(LIBLEVELDB) $(LIBMEMENV) \ +qt_lore_qt_LDADD += $(LIBBITCOIN_CLI) $(LIBBITCOIN_COMMON) $(LIBBITCOIN_UTIL) $(LIBBITCOIN_CRYPTO) $(LIBUNIVALUE) $(LIBLEVELDB) $(LIBMEMENV) \ $(BOOST_LIBS) $(QT_LIBS) $(QT_DBUS_LIBS) $(QR_LIBS) $(PROTOBUF_LIBS) $(BDB_LIBS) $(SSL_LIBS) $(CRYPTO_LIBS) $(MINIUPNPC_LIBS) $(LIBSECP256K1) \ $(EVENT_PTHREADS_LIBS) $(EVENT_LIBS) -qt_blackcoin_qt_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(QT_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) -qt_blackcoin_qt_LIBTOOLFLAGS = --tag CXX +qt_lore_qt_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(QT_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) +qt_lore_qt_LIBTOOLFLAGS = --tag CXX #locale/foo.ts -> locale/foo.qm QT_QM=$(QT_TS:.ts=.qm) @@ -418,9 +418,9 @@ CLEAN_QT = $(nodist_qt_libbitcoinqt_a_SOURCES) $(QT_QM) $(QT_FORMS_H) qt/*.gcda CLEANFILES += $(CLEAN_QT) bitcoin_qt_clean: FORCE - rm -f $(CLEAN_QT) $(qt_libbitcoinqt_a_OBJECTS) $(qt_blackcoin_qt_OBJECTS) qt/blackcoin-qt$(EXEEXT) $(LIBBITCOINQT) + rm -f $(CLEAN_QT) $(qt_libbitcoinqt_a_OBJECTS) $(qt_lore_qt_OBJECTS) qt/lore-qt$(EXEEXT) $(LIBBITCOINQT) -bitcoin_qt : qt/blackcoin-qt$(EXEEXT) +bitcoin_qt : qt/lore-qt$(EXEEXT) ui_%.h: %.ui @test -f $(UIC) diff --git a/src/bitcoind.cpp b/src/bitcoind.cpp index a8cc256bc..7c5cf9d44 100644 --- a/src/bitcoind.cpp +++ b/src/bitcoind.cpp @@ -83,7 +83,7 @@ bool AppInit(int argc, char* argv[]) else { strUsage += "\n" + _("Usage:") + "\n" + - " blackcoind [options] " + _("Start Blackcoin Lore Daemon") + "\n"; + " lored [options] " + _("Start Blackcoin Lore Daemon") + "\n"; strUsage += "\n" + HelpMessage(HMM_BITCOIND); } @@ -122,7 +122,7 @@ bool AppInit(int argc, char* argv[]) if (fCommandLine) { - fprintf(stderr, "Error: There is no RPC client functionality in blackcoind anymore. Use the blackcoin-cli utility instead.\n"); + fprintf(stderr, "Error: There is no RPC client functionality in lored anymore. Use the lore-cli utility instead.\n"); exit(1); } #ifndef WIN32