Jump to content

NEWS
  • WELCOME TO CRYPTOCURRENCYTALK!
  • We've upgraded the website with a lot of new features!
  • 3 NEW THEMES! Click on the + Themes button above!
  • Notice about SOCIAL LINKS: UPDATE YOUR SOCIAL LINKS
  • New video section, add your videos: VIDEO SECTION
  • Advertising will be available shortly, hold tight.
  • If you have any issues with the new site, please submit a support ticket: SUPPORT
Smokeasy

How to Compile Bitcoin sCrypt v.1.3.3 for Windows using Gitian

Recommended Posts

[Edited 2014-05-08 to work on v.1.3.3]

 

Instructions for building a Windows Bitcoin sCrypt client v.1.3.3 from source code using a deterministic gitian build.

 

 

Amended for Bitcoin-sCrypt by Smokeasy from Gavin's Notes to getting gitian builds up and running and Onichan's Guide to compiling on Windows (https://bitcointalk.org/index.php?topic=84984.0).

 

Gitian uses a deterministic build process to allow multiple builders to create verifiably identical binaries thereby allowing users to download trusted binaries that are verified by multiple builders.  (http://gitian.org). 

 

REQUIREMENTS:  You need the right hardware - you need a 64-bit-capable CPU with hardware virtualization support (Intel VT-x or AMD-V). Not all modern CPUs support hardware virtualization.  You probably need to enable hardware virtualization in your machine's BIOS. You need to be running a recent version of 64-bit-Ubuntu because Gitian supports only Ubuntu hosts (so the Windows client must be cross-compiled on Ubuntu). Check the log files if you run into errors.

 

 

 

 

First, install dependencies:

1. sudo apt-get install apache2 git apt-cacher-ng python-vm-builder qemu-kvm ruby qemu-utils rubygems

Sanity checks:

2. sudo service apt-cacher-ng status   # Should return apt-cacher-ng is running
3. ls -l /dev/kvm   # Should show a /dev/kvm device

Once you've got the right hardware and software we can compile the Windows client

Clone local copies of bitcoin-scrypt and gitian source-codes

4. Enter Ubuntu terminal
5. git clone git://github.com/bitcoin-scrypt/bitcoin-scrypt.git bitcoin
    // (OR use mirror:  git clone git://github.com/Omega6/bitcoin-scrypt.git bitcoin)
6. git clone git://github.com/devrandom/gitian-builder.git gitian
7. mkdir gitian/inputs
8. zip -r gitian/inputs/bitcoin-1.3.3.zip bitcoin
9. cd gitian/inputs

Fetch and build inputs

10. wget 'http://downloads.sourceforge.net/project/boost/boost/1.49.0/boost_1_49_0.tar.bz2'
11. wget 'http://www.openssl.org/source/openssl-1.0.1g.tar.gz'
12. wget 'http://download.oracle.com/berkeley-db/db-4.8.30.NC.tar.gz'
13. wget 'http://miniupnp.free.fr/files/download.php?file=miniupnpc-1.6.tar.gz' -O miniupnpc-1.6.tar.gz
14. wget 'http://downloads.sourceforge.net/project/libpng/zlib/1.2.7/zlib-1.2.7.tar.gz'
15. wget 'http://sourceforge.net/projects/libpng/files/libpng15/older-releases/1.5.12/libpng-1.5.12.tar.gz/download'
16. wget 'http://fukuchi.org/works/qrencode/qrencode-3.2.0.tar.bz2'
17. wget 'http://download.qt-project.org/archive/qt/4.7/qt-everywhere-opensource-src-4.7.4.tar.gz'
18. cd ..

Build Base Virtual Machine (this will take some time so do not quit prematurely)

19. sudo bin/make-base-vm --arch i386

Build Bitcoin-sCrypt Windows Client

20. sudo bin/gbuild ../bitcoin/contrib/gitian-descriptors/qt-win32.yml
21. cp build/out/qt-win32-4.7.4-gitian.zip inputs
22. sudo bin/gbuild ../bitcoin/contrib/gitian-descriptors/boost-win32.yml
23. cp build/out/boost-win32-1.49.0-gitian2.zip inputs
24. sudo bin/gbuild ../bitcoin/contrib/gitian-descriptors/deps-win32.yml
25. cp build/out/bitcoin-deps-1.3.3.zip inputs
26. sudo bin/gbuild ../bitcoin/contrib/gitian-descriptors/gitian-win32.yml

The compiled Windows GUI client, daemon and Windows Installer binaries (along with the source-code) will output to gitian/build/out.

 

 

============================== THE END ==================================

 

 

 

SHA256 file checksums for input files:

dd748a7f5507a7e7af74f452e1c52a64e651ed1f7263fce438a06641d2180d3c  boost_1_49_0.tar.bz2
12edc0df75bf9abd7f82f821795bcee50f42cb2e5f76a6a281b85732798364ef  db-4.8.30.NC.tar.gz
aae4c469f5f03e7c180708fc547335ad1e29854bfdda992196e9c39d2447e9f6  libpng-1.5.12.tar.gz
bbd6b756e6af44b5a5b0f9b93eada3fb8922ed1d6451b7d6f184d0ae0c813994  miniupnpc-1.6.tar.gz
53cb818c3b90e507a8348f4f5eaedb05d8bfe5358aabb508b7263cc670c3e028  openssl-1.0.1g.tar.gz
03c4bc7cd9a75747c3815d509bbe061907d615764f2357923f0db948c567068f  qrencode-3.2.0.tar.bz2
97195ebce8a46f9929fb971d9ae58326d011c4d54425389e6e936514f540221e  qt-everywhere-opensource-src-4.7.4.tar.gz
fa9c9c8638efb8cb8ef5e4dd5453e455751e1c530b1595eed466e1be9b7e26c5  zlib-1.2.7.tar.gz

SHA256 file checksums for output and distribution files:

e82898ba52d0d45dd0fe58cf44936d3810e5b8680570cc79e9fa64f5a29464ab  Bitcoin-sCrypt.exe
8d3cb466ef7ca116e89c856c7a03df2c624ce5efc9991c330b77492958e49ee7  Bitcoin-sCryptd.exe
0bb7d7703921a5e48b1cf1417f5af91a01a68976fcd032204ac256891ef8c911  Bitcoin-sCrypt-1.3.3-win32-setup.exe

~ Smokeasy 

http://theotherbitcoin.com

Edited by Smokeasy
Updated instructions for v.1.3.3

Share this post


Link to post
Share on other sites

Hi, generally there is no need to worry if running 64-BIT OS, if the build is 32-BIT.
It should still run fine. There is no special reason to need 64-BIT for the intensivity
of the application resources, will not need it. I hope this helps.

However, if you did receive a 64-BIT COMPILED APPLICATION, you MUST have a 64-BIT OS
to run it. The other way is different.

1. 32-BIT apps work fine on 64-BIT OS
2. 64-BIT apps work fine on 64-BIT OS
3. 32-BIT apps work fine on 32-BIT OS
4. 64-BIT apps oops - will not work ;)

Good luck!

Share this post


Link to post
Share on other sites

Hi,

 

Nice instruction set. I followed the instructions step by step and everything went perfect until I got to step 22, then I got the following error. Can someone please advise me on how to correct the problem. Thanks.

 

user@user-ThinkPad-T60:~/gitian$ sudo bin/gbuild ../bitcoin/contrib/gitian-descriptors/deps-win32.yml
[sudo] password for user:
sha256sum: libpng-1.5.12.tar.gz: No such file or directory
--- Building for lucid i386 ---
Stopping target if it is up
Killing target since it did not shutdown within 10 seconds
Making a new image copy
Formatting 'target-lucid-i386.qcow2', fmt=qcow2 size=11811160064 backing_file='base-lucid-i386.qcow2' encryption=off cluster_size=65536
Starting target
Checking if target is up.
Preparing build environment
openssl-1.0.1g.tar.gz                         100% 4403KB   4.3MB/s   00:01    
db-4.8.30.NC.tar.gz                           100%   22MB  21.8MB/s   00:01    
miniupnpc-1.6.tar.gz                          100%   65KB  64.9KB/s   00:00    
zlib-1.2.7.tar.gz                             100%  547KB 547.2KB/s   00:00    
inputs/libpng-1.5.12.tar.gz: No such file or directory
bin/gbuild:21:in `system!': failed to run copy-to-target  inputs/libpng-1.5.12.tar.gz build/ (RuntimeError)
    from bin/gbuild:80:in `build_one_configuration'
    from bin/gbuild:78:in `each'
    from bin/gbuild:78:in `build_one_configuration'
    from bin/gbuild:233
    from bin/gbuild:228:in `each'
    from bin/gbuild:228
    from bin/gbuild:226:in `each'
    from bin/gbuild:226
user@user-ThinkPad-T60:~/gitian$ cp build/out/bitcoin-deps-1.3.3.zip inputs
cp: cannot stat `build/out/bitcoin-deps-1.3.3.zip': No such file or directory
user@user-ThinkPad-T60:~/gitian$
 

Share this post


Link to post
Share on other sites

By the way, I am running ubuntu 12.04 64bit when I got the following error.

 

user@user-ThinkPad-T60:~/gitian$ sudo bin/gbuild ../bitcoin/contrib/gitian-descriptors/deps-win32.yml
[sudo] password for user:
sha256sum: libpng-1.5.12.tar.gz: No such file or directory
--- Building for lucid i386 ---
Stopping target if it is up
Killing target since it did not shutdown within 10 seconds
Making a new image copy
Formatting 'target-lucid-i386.qcow2', fmt=qcow2 size=11811160064 backing_file='base-lucid-i386.qcow2' encryption=off cluster_size=65536
Starting target
Checking if target is up.
Preparing build environment
openssl-1.0.1g.tar.gz                         100% 4403KB   4.3MB/s   00:01    
db-4.8.30.NC.tar.gz                           100%   22MB  21.8MB/s   00:01    
miniupnpc-1.6.tar.gz                          100%   65KB  64.9KB/s   00:00    
zlib-1.2.7.tar.gz                             100%  547KB 547.2KB/s   00:00    
inputs/libpng-1.5.12.tar.gz: No such file or directory
bin/gbuild:21:in `system!': failed to run copy-to-target  inputs/libpng-1.5.12.tar.gz build/ (RuntimeError)
    from bin/gbuild:80:in `build_one_configuration'
    from bin/gbuild:78:in `each'
    from bin/gbuild:78:in `build_one_configuration'
    from bin/gbuild:233
    from bin/gbuild:228:in `each'
    from bin/gbuild:228
    from bin/gbuild:226:in `each'
    from bin/gbuild:226
user@user-ThinkPad-T60:~/gitian$ cp build/out/bitcoin-deps-1.3.3.zip inputs
cp: cannot stat `build/out/bitcoin-deps-1.3.3.zip': No such file or directory
user@user-ThinkPad-T60:~/gitian$
 

Share this post


Link to post
Share on other sites

Hi,

 

Thanks for your help. I moved the file libpng-1.5.12.tar.gz. to gitian/inputs and that fixed the problem. I am now on the last step, and the computer is compiling. Do you have any idea how long it will take to compile this last step? I get that some processors work faster than others. This thing has been going since 1pm, and it is now 11 pm. Could the process be frozen? I have a Intel Core Duoprocessor T7200 (2GHz) .

 

Thanks again.

 

Andrew

Share this post


Link to post
Share on other sites

OK, so I'm a windows newbie dummy and can't figure out any of the instructions.  Can you dumb it down a little for newbies?

 

These are the instructions to compile the Bitcoin-sCrypt source code into a Windows executable using a Linux box with a virtual machine emulator running on said Linux box.  If this sentence doesn't make sense to you then you will have to figure out what that sentence means before attempting to compile it yourself. 

 

But, if you do understand that sentence and if you have the hardware/OS requirements (as provided in the intro quote), then you can simply copy and paste each numbered step in order onto the Linux command-line and it will compile or return errors stating why it didn't compile.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


  • Recently Browsing   0 members

    No registered users viewing this page.

×

Important Information

By using CRYPTOCURRENCYTALK.COM, you agree to our Terms of Use.