electrum

Electrum Bitcoin wallet
git clone https://git.parazyd.org/electrum
Log | Files | Refs | Submodules

commit 068b6acf792d0acdc861601322e70b7d99a6842a
parent 8f25e147fdf3117d1be116b8c7952e1a3afb30d7
Author: SomberNight <somber.night@protonmail.com>
Date:   Fri, 29 Jun 2018 18:13:11 +0200

wine build: use docker to (try to) have reproducible builds

Diffstat:
Acontrib/build-wine/docker/Dockerfile | 29+++++++++++++++++++++++++++++
Acontrib/build-wine/docker/README.md | 42++++++++++++++++++++++++++++++++++++++++++
2 files changed, 71 insertions(+), 0 deletions(-)

diff --git a/contrib/build-wine/docker/Dockerfile b/contrib/build-wine/docker/Dockerfile @@ -0,0 +1,29 @@ +FROM ubuntu:18.04@sha256:5f4bdc3467537cbbe563e80db2c3ec95d548a9145d64453b06939c4592d67b6d + +ENV LC_ALL=C.UTF-8 LANG=C.UTF-8 + +RUN dpkg --add-architecture i386 && \ + apt-get update -qq && \ + apt-get install -qq \ + wget=1.19.4-1ubuntu2.1 \ + gnupg2=2.2.4-1ubuntu1.1 \ + dirmngr=2.2.4-1ubuntu1.1 \ + software-properties-common=0.96.24.32.3 \ + && \ + wget -nc https://dl.winehq.org/wine-builds/Release.key && \ + apt-key add Release.key && \ + apt-add-repository https://dl.winehq.org/wine-builds/ubuntu/ && \ + apt-get update -qq && \ + apt-get install -qq \ + winehq-stable=3.0.1~bionic \ + git=1:2.17.1-1ubuntu0.1 \ + p7zip-full=16.02+dfsg-6 \ + make=4.1-9.1ubuntu1 \ + mingw-w64=5.0.3-1 \ + autotools-dev=20180224.1 \ + autoconf=2.69-11 \ + libtool=2.4.6-2 \ + && \ + rm -rf /var/lib/apt/lists/* && \ + apt-get autoremove -y && \ + apt-get clean diff --git a/contrib/build-wine/docker/README.md b/contrib/build-wine/docker/README.md @@ -0,0 +1,42 @@ +Deterministic Windows binaries with Docker +========================================== + +This assumes an Ubuntu host, but it should not be too hard to adopt to another +similar system. + +1. Install Docker + + ``` + $ curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add - + $ sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable" + $ sudo apt-get update + $ sudo apt-get install -y docker-ce + ``` + +2. Build image + + ``` + $ cd contrib/build-wine/docker + $ PROJECT_ROOT=$(pwd)/../../../ + $ sudo docker build --no-cache -t electrum-wine-builder-img . + ``` + + Note: see [this](https://stackoverflow.com/a/40516974/7499128) if having dns problems + +3. Build Windows binaries + + ``` + $ TARGET=master + $ sudo docker run \ + --name electrum-wine-builder-cont \ + -v ${PROJECT_ROOT}:/opt/electrum \ + --rm \ + --workdir /opt/electrum/contrib/build-wine \ + electrum-wine-builder-img \ + ./build.sh $TARGET + ``` +4. The generated binaries are in `$PROJECT_ROOT/contrib/build-wine/dist`. + + + +Note: the `setup` binary (NSIS installer) is not deterministic yet.