Skip to content

Instantly share code, notes, and snippets.

@louisje
Last active August 17, 2017 10:39
Show Gist options
  • Save louisje/db3deed7221188f6de94fbcea19c9383 to your computer and use it in GitHub Desktop.
Save louisje/db3deed7221188f6de94fbcea19c9383 to your computer and use it in GitHub Desktop.
targets = cpuminer-multi ccminer ethminer xmrMiner
WALLET_ETH = 0x7b2ffb19e91c325537f2b50d51626a0cbae129ce
WALLET_XMR = 45RngebM2ZtDHyQBcXcw86iuEq7awrWM43mCiyLxjMNqCLJvXtTLYgSBr8bRhF9HcjgjkQu2uws59fepWLWe5DNFMua2Gy4
.PHONY: ${targets}
.ONESHELL:
build: ${targets}
xmr-stak-cpu:
if test ! -d xmr-stak-cpu; then git clone https://github.com/fireice-uk/xmr-stak-cpu.git; fi
cd xmr-stak-cpu
git pull --rebase
cmake .
cmake --build .
xmrMiner:
if test ! -d xmrMiner; then git clone https://github.com/xmrMiner/xmrMiner.git; fi
cd xmrMiner
git pull --rebase
mkdir -p build && cd build
cmake .. -DCUDA_ARCH=61
cmake --build .
cpp-ethereum:
if test ! -d cpp-ethereum; then git clone https://github.com/ethereum/cpp-ethereum.git; fi
cd cpp-ethereum
git submodule update --init
git pull --rebase
mkdir -p build && cd build
cmake .. -DHUNTER_JOBS_NUMBER=4
cmake --build .
ethminer:
if test ! -d ethminer; then git clone https://github.com/ethereum-mining/ethminer.git; fi
cd ethminer
git pull --rebase
mkdir -p build && cd build
cmake .. -DETHASHCUDA=ON -DETHASHCL=ON -DHUNTER_JOBS_NUMBER=4
cmake --build .
cpuminer-multi:
if test ! -d cpuminer-multi; then git clone https://github.com/louisje/cpuminer-multi.git; fi
cd cpuminer-multi
git pull --rebase
./autogen.sh
./build.sh
ccminer:
if test ! -d ccminer; then git clone https://github.com/tpruvot/ccminer.git; fi
cd ccminer
git pull --rebase
./autogen.sh
./build.sh
ethermine-cuda:
./ethminer/build/ethminer/ethminer -U -S "asia1.ethermine.org:4444" -FS "us2.ethermine.org:4444" -O ${WALLET_ETH}
ethermine-opencl:
./ethminer/build/ethminer/ethminer -G -S "asia1.ethermine.org:4444" -FS "us2.ethermine.org:4444" -O ${WALLET_ETH}
minexmr-gpu:
./ccminer/ccminer -o "stratum+tcp://pool.minexmr.com:7777" -u ${WALLET_XMR} -a cryptonight -p x
minexmr-cpu:
./cpuminer-multi/cpuminer -o "stratum+tcp://pool.minexmr.com:4444" -u ${WALLET_XMR} -p x -a cryptonight -D
minexmr-full:
$(MAKE) -j2 minexmr-cpu minexmr-gpu
tonight:
sleep $$(($$(date -d "today 9:00pm" +"%s") - $$(date +"%s")))
benchmark:
$(MAKE) -j2 ethermine-cuda minexmr-cpu
clean:
rm -rf ${targets}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment