2015-11-03 11:36:09 +01:00
|
|
|
WINDOWS BUILD NOTES
|
|
|
|
====================
|
|
|
|
|
|
|
|
Some notes on how to build Bitcoin Core for Windows.
|
|
|
|
|
|
|
|
Most developers use cross-compilation from Ubuntu to build executables for
|
|
|
|
Windows. This is also used to build the release binaries.
|
|
|
|
|
|
|
|
Building on Windows itself is possible (for example using msys / mingw-w64),
|
|
|
|
but no one documented the steps to do this. If you are doing this, please contribute them.
|
|
|
|
|
|
|
|
Cross-compilation
|
|
|
|
-------------------
|
|
|
|
|
|
|
|
These steps can be performed on, for example, an Ubuntu VM. The depends system
|
|
|
|
will also work on other Linux distributions, however the commands for
|
|
|
|
installing the toolchain will be different.
|
|
|
|
|
2016-08-29 10:33:36 +02:00
|
|
|
Make sure you install the build requirements mentioned in
|
|
|
|
[build-unix.md](/doc/build-unix.md).
|
|
|
|
Then, install the toolchains and curl:
|
2015-11-03 11:36:09 +01:00
|
|
|
|
2016-08-29 10:33:36 +02:00
|
|
|
sudo apt-get install g++-mingw-w64-i686 mingw-w64-i686-dev g++-mingw-w64-x86-64 mingw-w64-x86-64-dev curl
|
2015-11-03 11:36:09 +01:00
|
|
|
|
|
|
|
To build executables for Windows 32-bit:
|
|
|
|
|
|
|
|
cd depends
|
|
|
|
make HOST=i686-w64-mingw32 -j4
|
|
|
|
cd ..
|
2016-09-22 05:10:59 +02:00
|
|
|
./autogen.sh # not required when building from tarball
|
2015-11-03 11:36:09 +01:00
|
|
|
./configure --prefix=`pwd`/depends/i686-w64-mingw32
|
|
|
|
make
|
|
|
|
|
|
|
|
To build executables for Windows 64-bit:
|
|
|
|
|
|
|
|
cd depends
|
|
|
|
make HOST=x86_64-w64-mingw32 -j4
|
|
|
|
cd ..
|
2016-09-22 05:10:59 +02:00
|
|
|
./autogen.sh # not required when building from tarball
|
2015-11-03 11:36:09 +01:00
|
|
|
./configure --prefix=`pwd`/depends/x86_64-w64-mingw32
|
|
|
|
make
|
|
|
|
|
|
|
|
For further documentation on the depends system see [README.md](../depends/README.md) in the depends directory.
|
|
|
|
|