Skip to content

How to compile fasthash accelerations

Bilaboz edited this page Oct 1, 2022 · 9 revisions
# Update your system and python:
sudo apt update && sudo apt upgrade -y && sudo apt install curl python3 python3-pip python3-dev -y
# Install rustup for compilation (if asked, use the default settings):
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs/ | sh
source $HOME/.cargo/env
# Download duino fasthash:
wget https://server.duinocoin.com/fasthash/libducohash.tar.gz
# Unpack it:
tar -xvf libducohash.tar.gz
# Go to the dir:
cd libducohash
# Compile it:
cargo build --release
# Extract the module:
# If you're on macos the filename will be libducohasher.dylib, rename it to libducohasher.so
mv target/release/libducohasher.so .
# Confirm it works:
wget https://raw.githubusercontent.com/revoxhere/duino-coin/master/PC_Miner.py
python3 PC_Miner.py

If you enocunter the no default toolchain configured error, try this and try recompiling:

rustup install stable
rustup default stable

If you will still have problems, try reinstalling the rust toolchain and try recompiling:

rustup toolchain uninstall stable
rustup set default-host armv7-unknown-linux-gnueabihf
rustup toolchain install stable --profile minimal
rustup default stable-armv7-unknown-linux-gnueabihf