Forum Home
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Popular

    [Dev] Documenting Feathercoin Specific Software settings - Part 14

    Technical Development
    1
    34
    8230
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • wrapper
      wrapper Moderators last edited by

      Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

      Patch missing :: commit

      Bug fix

      https://github.com/FeatherCoin/Feathercoin/commit/7b5d133d41fef537a49145346a31b8358d5b83c2

      src/rpcserver.cpp

       +    { "makekeypair",     				&makekeypair,      			 true,      false,      true },
      

      Code added

      1 Reply Last reply Reply Quote 1
      • wrapper
        wrapper Moderators last edited by

        Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

        Patch missing :: commit

        Bug fix

        https://github.com/FeatherCoin/Feathercoin/commit/7b5d133d41fef537a49145346a31b8358d5b83c2

        src/rpcserver.h

         +extern json_spirit::Value makekeypair(const json_spirit::Array& params, bool fHelp);
        

        Code added

        1 Reply Last reply Reply Quote 1
        • wrapper
          wrapper Moderators last edited by

          Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

          Patch missing :: commit

          Bug fix

          https://github.com/FeatherCoin/Feathercoin/commit/7b5d133d41fef537a49145346a31b8358d5b83c2

          Code review

          I think that more logprintf statements should be executed only,if the debug flag is set.
          The current log is to exhaustive and a 'normal ’ user doesn’t need it. Please insert back the 'if fDebug…'statements and add themto the new log entries

          Was this checked for compliance?

          1 Reply Last reply Reply Quote 1
          • wrapper
            wrapper Moderators last edited by wrapper

            Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

            Patch missing :: commit

            Bug fix

            https://github.com/FeatherCoin/Feathercoin/commit/f0229d3371cf2811ded7ad8641c1a1834862c2d9

            src/main.cpp

             -    LogPrintf("CheckProofOfWork() hash=%s \n",hash.ToString().c_str());
            
             +    //LogPrintf("CheckProofOfWork() hash=%s \n",hash.ToString().c_str());
             +    //LogPrintf("CheckProofOfWork() nBits=%i \n",nBits);
             +    //LogPrintf("CheckProofOfWork() bnTarget.getuint256=%s \n",bnTarget.getuint256().ToString().c_str());
            
             +		LogPrintf("SetBestChain:100 chainActive nHeight=%d,BlockHash=%s\n",pindexOldTip->nHeight,pindexOldTip->GetBlockHash().ToString());
            
             +		LogPrintf("SetBestChain:100 pindexNew 
            
             +    LogPrintf("SetBestChain:110 pfork nHeight=%d,BlockHash=%s\n",pfork->nHeight,pfork->GetBlockHash().ToString());
            
             +        LogPrintf("SetBestChain:120: Disconnect %"PRIszu" blocks; %s...\n", vDisconnect.size(), pfork->GetBlockHash().ToString());
             +        LogPrintf("SetBestChain:120: Connect %"PRIszu" blocks; ...%s\n", vConnect.size(), pindexNew->GetBlockHash().ToString());
            

            Code replaced

             +    // Disconnect shorter branch
             +    vector<CTransaction> vResurrect;
             +    BOOST_FOREACH(CBlockIndex* pindex, vDisconnect) {
             +        CBlock block;
             +        if (!ReadBlockFromDisk(block, pindex))
             +            return state.Abort(_("Failed to read block"));
             +        int64 nStart = GetTimeMicros();
             +        bool fClean = true;
             +        if (!DisconnectBlock(block, state, pindex, view, &fClean))
             +            return error("SetBestBlock() : DisconnectBlock %s failed", pindex->GetBlockHash().ToString().c_str());
             +        if (fBenchmark)
             +            LogPrintf("- Disconnect: %.2fms\n", (GetTimeMicros() - nStart) * 0.001);
             +
             +        // Queue memory transactions to resurrect.
             +        // We only do this for blocks after the last checkpoint (reorganisation before that
             +        // point should only happen with -reindex/-loadblock, or a misbehaving peer.
             +        BOOST_FOREACH(const CTransaction& tx, block.vtx)
             +            if (!tx.IsCoinBase() && pindex->nHeight > Checkpoints::GetTotalBlocksEstimate())
             +                vResurrect.push_back(tx);
             +    }
             +    
             +    // Connect longer branch
             +    vector<CTransaction> vDelete;
             +    BOOST_FOREACH(CBlockIndex *pindex, vConnect) {
             +        CBlock block;
             +        if (!ReadBlockFromDisk(block, pindex))
             +            return state.Abort(_("Failed to read block"));
             +        int64 nStart = GetTimeMicros();
             +        if (!ConnectBlock(block, state, pindex, view)) {
             +            if (state.IsInvalid()) {
             +                InvalidChainFound(pindexNew);
             +                InvalidBlockFound(pindex,state);
             +            }
             +            return error("SetBestBlock() : ConnectBlock %s failed", pindex->GetBlockHash().ToString().c_str());
             +        }
             +        if (fBenchmark)
             +            LogPrintf("- Connect: %.2fms\n", (GetTimeMicros() - nStart) * 0.001);
             +
             +        // Queue memory transactions to delete
             +        BOOST_FOREACH(const CTransaction& tx, block.vtx)
             +            vDelete.push_back(tx);
             +    }
             +    LogPrintf("SetBestChain:130: \n");
             +    
             +    // Flush changes to global coin state
             +    int64 nStart = GetTimeMicros();
             +    int nModified = view.GetCacheSize();
             +    assert(view.Flush());
             +    int64 nTime = GetTimeMicros() - nStart;
             +    if (fBenchmark)
             +        LogPrintf("- Flush %i transactions: %.2fms (%.4fms/tx)\n", nModified, 0.001 * nTime, 0.001 * nTime / nModified);    
             +    
             +    if (!WriteChainState(state))
             +        return false;
             +        
             +    // Resurrect memory transactions that were in the disconnected branch
             +    BOOST_FOREACH(CTransaction& tx, vResurrect) {
             +        // ignore validation errors in resurrected transactions
             +        CValidationState stateDummy;
             +        list<CTransaction> removed;
             +        if (!AcceptToMemoryPool(mempool, stateDummy, tx, false, NULL))
             +            mempool.remove(tx, removed, true);               
             +    }
             
             
             +    // Delete redundant memory transactions that are in the connected branch
             +    list<CTransaction> txConflicted;
             +    BOOST_FOREACH(CTransaction& tx, vDelete) {
             +        list<CTransaction> removed;
             +        mempool.remove(tx, removed);
             +        mempool.removeConflicts(tx, txConflicted);
             +    }
             
             
             +    mempool.check(pcoinsTip);
             +    LogPrintf("SetBestChain:140: \n");
             +    
             +    UpdateTip(pindexNew);
             +    
             +    // Tell wallet about transactions that went from mempool to conflicted:
             +    BOOST_FOREACH(const CTransaction &tx, txConflicted) {
             +        SyncWithWallets(tx.GetHash(), tx, NULL);
             +    }
            

            Code added

            +		LogPrintf("SetBestChain:150 true.\n");
            

            Code replaced

             -		//return (pnext || this == chainActive.Tip());
            

            Comment removed

            1 Reply Last reply Reply Quote 1
            • wrapper
              wrapper Moderators last edited by wrapper

              Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

              Updated FTC Install dependencies guide, build zxing (c++ version) :: commit

              Various layout changes, dependency updates and build zxing help

              https://github.com/FeatherCoin/Feathercoin/commit/b54181e2bb36983ba35933845203a182a966deef

              doc/README.md

               +    sudo apt-get install libqt5printsupport5 libqt5opengl5-dev  
              

              Now Qt5

               +    sudo apt-get install libqt5gui5 libqt5core5a libqt5dbus5  
              

              Now libqt5core5a

               +    sudo apt-get install libssl-dev 
              

              Typo no install

               +### If PPA or .deb does not work, compile the zxing libraries yourself, download the sources from github.com.
               +
               +Search for zxing-cpp to get the c++ version of the code.   
               +
               +https://github.com/glassechidna/zxing-cpp
               +
               +Build command for libzxing : 
              
              
               +export CXXFLAGS="-D_GLIBCXX_USE_CXX11_ABI=0"
               +cmake -G “Unix Makefiles” … -D_GLIBCXX_USE_CXX11_ABI=0 -DCMAKE_BUILD_TYPE=Release
               +make 
               +sudo make install 
              

              Additional code / build instruction text

              1 Reply Last reply Reply Quote 1
              • wrapper
                wrapper Moderators last edited by wrapper

                Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                Updated FTC Install dependencies guide, build zxing (c++ version) :: commit

                Various MD layout changes

                https://github.com/FeatherCoin/Feathercoin/commit/20e75314f47ff6bb8d625bcee86c934b76a8679a

                doc/README.md

                 +mkdir build
                 +cd build
                

                Extra instructions for zxing build

                1 Reply Last reply Reply Quote 1
                • wrapper
                  wrapper Moderators last edited by

                  Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                  Further tweeks to zxing build from source instructions :: commit

                  Various MD layout changes

                  https://github.com/FeatherCoin/Feathercoin/commit/4a1fd9b460e266ee74af34a6bc10b73c7001aba7

                  doc/README.md

                   +cmake -G “Unix Makefiles”.. -D_GLIBCXX_USE_CXX11_ABI=0 -DCMAKE_BUILD_TYPE=Release   
                  

                  Instructions don’t copy from markdown. …

                    +--with-incompatible-bdb
                  

                  Additional build instructions available

                  1 Reply Last reply Reply Quote 1
                  • wrapper
                    wrapper Moderators last edited by

                    Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                    Further tweeks to zxing build from source instructions :: commit

                    Various MD layout changes, further updates

                    https://github.com/FeatherCoin/Feathercoin/commit/acb5abcbbeac0cec38fe9665f364900704d01f60

                    doc/README.md

                     -export CXXFLAGS="-D_GLIBCXX_USE_CXX11_ABI=0"  
                    
                     +export CXXFLAGS="-fPIC"
                    

                    Code replaced

                     +sudo nano /usr/local/include/zxing/LuminanceSource.h
                    
                    +On Line 30 : Change public to private:
                    

                    Code replaced

                     +     ./configure --with-gui=qt5 --enable-tests=no  --with-incompatible-bdb --enable-upnp-default --with-qrcode=yes
                    

                    Additional switches

                     +### Build Berkley database version 4.8 from source.     
                     +
                     +wget http://download.oracle.com/berkeley-db/db-4.8.30.NC.tar.gz
                     +tar -xzvf db-4.8.30.NC.tar.gz
                     +cd db-4.8.30.NC/build_unix/
                     +…/dist/configure --enable-cxx
                     +make
                     +sudo make install
                     +
                     +Example config usage :
                     +
                     +./configure --disable-upnp-default --disable-tests --with-boost-libdir=/usr/lib/arm-linux-gnueabihf CPPFLAGS="-I/usr/local/BerkeleyDB.4.8/include -O2" LDFLAGS="-L/usr/local/BerkeleyDB.4.8/lib"
                    

                    Add code for Berkelay self build

                    1 Reply Last reply Reply Quote 1
                    • wrapper
                      wrapper Moderators last edited by

                      Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                      ** Updated main.cpp to remove unused variable :: commit**

                      Updated main.cpp to remove unused variable pblockindexFBBHLast and ./…

                      …autoconfig.sh to use autoupdate

                      https://github.com/FeatherCoin/Feathercoin/commit/acb5abcbbeac0cec38fe9665f364900704d01f60

                      autogen.sh

                       -autoreconf -if --warnings=all
                      
                      +autoupdate
                      +autoreconf  -if --warnings=all
                      

                      Code replaced

                      1 Reply Last reply Reply Quote 1
                      • wrapper
                        wrapper Moderators last edited by

                        Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                        ** Updated main.cpp to remove unused variable :: commit**

                        Updated main.cpp to remove unused variable pblockindexFBBHLast and ./…

                        …autoconfig.sh to use autoupdate

                        https://github.com/FeatherCoin/Feathercoin/commit/acb5abcbbeac0cec38fe9665f364900704d01f60

                        src/main.cpp

                        -static CBlockIndex* pblockindexFBBHLast;
                        
                         +// pblockindexFBBHLast : no longer used 
                         +// static CBlockIndex* pblockindexFBBHLast;
                        

                        Comments and code removed

                        1 Reply Last reply Reply Quote 1
                        • wrapper
                          wrapper Moderators last edited by wrapper

                          Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                          Correct spelling / typo wit = with in the Bitcoingui.cpp :: commit

                          Correct spelling / typo wit = with in the Bitcoingui.cpp connector menu

                          https://github.com/FeatherCoin/Feathercoin/commit/acb5abcbbeac0cec38fe9665f364900704d01f60

                          src/qt/bitcoingui.cpp

                           +    coinnectorAction->setStatusTip(tr("Exchange other coins with your feathercoin on Coinnector"));
                          

                          Needs review against Translation database.

                          1 Reply Last reply Reply Quote 1
                          • wrapper
                            wrapper Moderators last edited by

                            Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                            ScanHash_CryptoPP unused function remove :: commit

                            ScanHash_CryptoPP unused function removed from miner.cpp

                            https://github.com/FeatherCoin/Feathercoin/commit/2ac641ec011faf29f669f8b1e8449ef7e94b2af2

                            src/miner.cpp

                             +// ScanHash_CryptoPP not used
                             +//unsigned int static ScanHash_CryptoPP(char* pmidstate, char* pdata, char* phash1, char* phash, unsigned int& nHashesDone)
                             +//{
                             +//    unsigned int& nNonce = *(unsigned int*)(pdata + 12);
                             +//    for (;;)
                             +//    {
                             +//        // Crypto++ SHA256
                             +//        // Hash pdata using pmidstate as the starting state into
                             +//        // pre-formatted buffer phash1, then hash phash1 into phash
                             +//        nNonce++;
                            

                            Start of code which is commented out, so can be put back

                            1 Reply Last reply Reply Quote 1
                            • wrapper
                              wrapper Moderators last edited by wrapper

                              Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                              Hash out deprecated autoconfig and add autoupdate t :: commit

                              Hash out deprecated autoconfig and add autoupdate to stop build warnings

                              https://github.com/FeatherCoin/Feathercoin/commit/0edb5929d63efc16c7b3c599732173243ea01e9d

                              autogen.sh

                                -autoreconf  -if --warnings=all
                               +# autoreconf  -if --warnings=all
                              

                              Minor update

                              1 Reply Last reply Reply Quote 0
                              • wrapper
                                wrapper Moderators last edited by wrapper

                                Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                                Removed an unused variable sw :: commit

                                https://github.com/FeatherCoin/Feathercoin/commit/9a7b663c75fcc443d9118df0db9c6105760982db

                                src/qt/coinnectordialog.cpp

                                 +//  int sw=0;
                                

                                Code commented out

                                1 Reply Last reply Reply Quote 0
                                • wrapper
                                  wrapper Moderators last edited by wrapper

                                  Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                                  Re-included autoreconf in ./autogen.sh :: commit

                                  Re-included autoreconf in ./autogen.sh, included echo messages autoupdate is running

                                  https://github.com/FeatherCoin/Feathercoin/commit/fdc52bc1c0e366f30c2c3f80af9128dcd556fdb1

                                  autogen.sh

                                   -# autoreconf  -if --warnings=all
                                  
                                   +echo running autoreconf .....
                                   +autoreconf  -if --warnings=all
                                     autoupdate
                                   +echo
                                   +echo running autoupdate completed .....
                                  

                                  Code replaced

                                  1 Reply Last reply Reply Quote 0
                                  • First post
                                    Last post