Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Building bitcoin with gitian-builder
# First run:
apt-get install apt-cacher python-vm-builder
vi /etc/default/apt-cacher # ensure autostart is enabled
sudo service apt-cacher start
# Note that apt-cacher caused some problems for me, you can also try apt-cacher-ng, making sure to set the listen address to (which it for some reason doesn't do if you have IPv6 in some cases)
git clone git://
git clone git://
mkdir gitian-builder/inputs
wget '' -O gitian-builder/inputs/miniupnpc-1.5.tar.gz
wget '' -O gitian-builder/inputs/wxWidgets-2.9.1.tar.bz2
# These are only required for Win32 Cross compiling
wget '' -O gitian-builder/inputs/boost_1_43_0.tar.bz2
wget '' -O gitian-builder/inputs/db-4.7.25.NC.tar.gz
wget '' -O gitian-builder/inputs/
wget '' -O gitian-builder/inputs/miniupnpc-1.5.20110215.tar.gz
wget '' -O gitian-builder/inputs/openssl-1.0.0d.tar.gz
cd gitian-builder
bin/make-base-vm --arch i386
bin/make-base-vm --arch amd64
cd ..
# To build for Linux
cd bitcoin
git pull
git checkout gitian0.3.22
cd ../gitian-builder
cp ../bitcoin/contrib/toplevel.* ./inputs/
git pull
./bin/gbuild --commit bitcoin=0c97aa9e141f5c23dc9f ../bitcoin/contrib/gitian.yml # 0.3.22 RC2
cd ..
# To cross compile for Win32 (via MinGW)
cd bitcoin
git checkout crosscompile
cd ../gitian-builder
cp ../bitcoin/src/makefile.linux-mingw inputs/
git pull
./bin/gbuild --commit bitcoin=0c97aa9e141f5c23dc9f ../bitcoin/contrib/gitian-win32.yml # 0.3.22 RC2
cd ..
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment