psy 1 день назад
Родитель
Сommit
6d7d50b55c

+ 1 - 1
ecoin/INSTALL

@@ -48,7 +48,7 @@ All of the commands should be executed in a shell:
 See doc/MINING.txt for detailed instructions on running /ecoin-miner/ on different platforms.
 
     cd miner/
-    sh build.sh
+    bash build.sh
 	
     ./cpuminer
     

+ 2 - 14
ecoin/doc/REWARDS.txt

@@ -5,24 +5,12 @@ ECOin - Copyright (c) - 2014/2026 - GPLv3 - epsylon@riseup.net (https://03c8.net
 # REWARDS - ECOlogical P2P Crypto-Currency (ECOin) #
 ====================================================
 
- + Proof-Of-Work Mining (POW) Rewards (halving every 262,800 blocks):
+ + Proof-Of-Work Mining (POW) Rewards:
 
        -------------------------------------------------------------
 	Block	 		Reward
        -------------------------------------------------------------
-	Block 1 - 3263: 	Random 500 5000 (1 minute blocks)
-	Block 3264 - 22000: 	Random 1000 10000 (2 minute blocks)
-	Block 22001 - 34750: 	Static reward 5000
-	Block 34751 - 39791: 	Static reward 2500
-	Block 39792 - 44832: 	Static reward 1250
-	Block 44833 - 49873: 	Static reward 625
-	Block 49874 - 54914: 	Static reward 312.50
-	Block 54915 - 59955: 	Static reward 156.25
-	Block 59956 - 64996: 	Static reward 78.125
-	Block 64997 - 70037: 	Static reward 39.0625
-	Block 70038 - 332838: 	static reward 20
-
-	Halving every 262800 blocks
+	Block 1+: 		Static reward 100
 
 ==================================
 

+ 1 - 18
ecoin/miner/build.sh

@@ -1,29 +1,12 @@
 #!/bin/bash
 set -euo pipefail
 
-if [ "$OS" = "Windows_NT" ]; then
-    ./mingw64.sh
-    exit 0
-fi
-
 make clean || echo clean
 
 rm -f config.status
 ./autogen.sh
 
-if [[ "$OSTYPE" == "darwin"* ]]; then
-    ./nomacro.pl
-    ./configure \
-        CFLAGS="-march=native -O2 -Ofast -flto -DUSE_ASM -pg" \
-        --with-crypto=/usr/local/opt/openssl \
-        --with-curl=/usr/local/opt/curl
-    make -j4
-    strip cpuminer
-    exit 0
-fi
-
-# Linux build
-extracflags="$extracflags -Ofast -fuse-linker-plugin -ftree-loop-if-convert-stores"
+extracflags="-Ofast -fuse-linker-plugin -ftree-loop-if-convert-stores"
 
 if [ ! "0" = `cat /proc/cpuinfo | grep -c avx` ]; then
     extracflags="$extracflags -march=native"

+ 1 - 1
ecoin/src/boost_1_68_0/boost/python/object/forward.hpp

@@ -15,7 +15,7 @@
 namespace boost { namespace python { namespace objects { 
 
 // Very much like boost::reference_wrapper<T>, except that in this
-// case T can be a reference already without causing a
+// case T can be a reference already without causing a
 // reference-to-reference error.
 template <class T>
 struct reference_to_value

+ 0 - 2
ecoin/src/checkpoints.cpp

@@ -14,8 +14,6 @@ namespace Checkpoints
     static MapCheckpoints mapCheckpoints =
         boost::assign::map_list_of
         ( 0,     std::make_pair(hashGenesisBlock, 1610833657) )
-        ( 5000,  std::make_pair(uint256("0x954c8ec4a89ba0d1c88ad5be0d135231b3808288098a98876cf50bd407298479"), 1740236667u) )
-        ( 10000, std::make_pair(uint256("0x15c75213288609b82cda1200528219f4c65cf89109e3aea6977a02b7b02f9c90"), 1769800237u) )
     ;
 
     static MapCheckpoints mapCheckpointsTestnet =

+ 1 - 47
ecoin/src/main.cpp

@@ -832,53 +832,7 @@ int static StartDigging(unsigned int seed, int minreward, int maxreward)
 
 int64 GetProofOfWorkReward(unsigned int nHeight, uint256 hashSeed)
 {
-		int64 nSubsidy = 0;
-		std::string strHash = hashSeed.ToString().substr(6,7);
-		const char* chSeed = strHash.c_str();
-		long lSeed = ConvertLong(chSeed);
-		int nBlockValue = 0;
-		int nMaxSubsidy = 5000;
-		int nMinSubsidy = 500;
-
-        // doubled the reward to compensate for 2 minute blocks
-		if (nHeight > 3295 && nHeight < 22001)
-		{
-		    nMaxSubsidy = nMaxSubsidy*2;
-		    nMinSubsidy = nMinSubsidy*2;
-	    }
-
-        // the random reward era,
-		if (nHeight <= 22000)
-		{
-			nBlockValue = StartDigging(lSeed, nMinSubsidy, nMaxSubsidy);
-			return nBlockValue * COIN;
-		}
-
-	    if (nHeight > 22000 && nHeight <= 34750)
-		{
-			nSubsidy = 5000;
-			return nSubsidy * COIN;
-		}
-
-		if (nHeight > 34750 && nHeight <= 70037)
-	    {
-			nSubsidy = 2500;
-
-			unsigned int nHeightTemp = nHeight - 34750;
-			nSubsidy >>= (nHeightTemp / 5040);
-			return nSubsidy * COIN;
-		}
-
-		if (nHeight > 70037)
-	    {
-            nSubsidy = 20;
-
-            unsigned int nHeightTemp = nHeight - 70037;
-			nSubsidy >>= (nHeightTemp / 262800);
-			return nSubsidy * COIN;
-		}
-
-     	return nSubsidy * COIN;
+	return 100 * COIN;
 }
 
 int64 GetProofOfStakeReward(int64 nCoinAge, unsigned int nBits, unsigned int nTime, bool bCoinYearOnly)

+ 1 - 1
ecoin/src/main.h

@@ -32,7 +32,7 @@ static const unsigned int MAX_INV_SZ = 50000;
 static const int64 MIN_TX_FEE = CENT;
 static const int64 MIN_RELAY_TX_FEE = CENT;
 static const int64 MAX_MONEY = 50000000000LL * COIN;
-static const int64 MAX_MINT_PROOF_OF_WORK = 10000 * COIN;
+static const int64 MAX_MINT_PROOF_OF_WORK = 100 * COIN;
 static const int64 MAX_MINT_PROOF_OF_STAKE = 1 * COIN;
 static const int64 MIN_TXOUT_AMOUNT = MIN_TX_FEE;
 static const unsigned int ENTROPY_SWITCH_TIME = 1420070399; // Dec 31 2014, 23:59:59 PM GMT

+ 1 - 1
ecoin/src/rpcmining.cpp

@@ -60,7 +60,7 @@ Value getmininginfo(const Array& params, bool fHelp)
 
     obj.push_back(Pair("blockvalue",    (uint64_t)GetProofOfWorkReward(GetLastBlockIndex(pindexBest, false)->nHeight+1, GetLastBlockIndex(pindexBest, false)->GetBlockHash())));
     //obj.push_back(Pair("netmhashps",     GetPoWMHashPS()));
-    obj.push_back(Pair("netmhashps",     GetRandHash));
+    obj.push_back(Pair("netmhashps", GetRandHash));
 
     obj.push_back(Pair("netstakeweight", GetPoSKernelPS()));
     obj.push_back(Pair("errors",        GetWarnings("statusbar")));