Wednesday, 7 September 2016

Software Engineering : Building Cryptozoidberg (Boolberry)

I recently received a request via YouTube to help a fellow programmer out, they were having issues building this library against the boost libraries... https://github.com/cryptozoidberg/boolberry

The problem essentially is the lack of transparency in CMake when it looks for boost with it's "FindBoost" functionality, because neither he, nor I build boost with CMake.  I personally don't use or like CMake, I do use make however, and am happy to look around in the make files.

So, I did... And there's nothing specifically wrong with this makefile, but it is insisting on looking for boost within the system, not the version built by yourself.

My Solution therefore has been:

sudo apt-get install libboost-all-dev
sudo apt-get install git
sudo apt-get install cmake
cd ~
mkdir c++
cd c++
git clone //https://github.com/cryptozoidberg/boolberry.git
cd boolberry
make -j4

(Note, replace 4 here with as many cores as your PC has available!  More cores will speed this build up, and it will take a long while)

And this works fine:


As you can see.  However, I did this from my main build machine, which has a whole bunch of additional and historic settings.  Which is the most common pitfall for others coming to build your software later, they lack these customisation's.

My build environment: Ubuntu 16.04 Desktop, with the i3 Window Manager (just open a terminal), and I have installed gcc (sudo apt-get install gcc).  These are the only steps before running the above script in a terminal window.

I therefore decided to perform a full clean setup of this system in a new Ubuntu 16.04 (64bit) VMware Virtual machine.

From this, I realise I needed to explain how to install the boost libraries, how to set up cmake and how to get git working before the build would work....

You can see this whole process below, please accept my apologies that this was recorded on an extremely slow internet connection, it got smushed during recording over the mobile link, and I've not had chance to re-shoot or edit the video.



As you can see however, the build worked perfectly.

To Muhmad whom asked for this, you'll find the Donate page at the top right!

10 comments:

  1. Thank you- I try intil i get it to work. Ihave 12gb ram.

    ReplyDelete
    Replies
    1. Literally do as I do, it works :D

      Delete
  2. It worked- had to install on pc and run it. Thank you alot. One last Q. There is a way to build til exe? So i can run booldb on Windows? Thank you☺

    ReplyDelete
    Replies
    1. I've not even looked at the windows instructions, I'd just have a poke around with a Virtual machine again, if I get chance, I'll let you know :)

      Delete
    2. Hang on... On a PC.. what was it being run on before? What gave the virtual memory error?... (you've peaked my interest)

      Delete
  3. I intstalled Linux systemet on a harddrive and it worked- I wonder if can bulid it to EXE so can run the relaese on windows. thank you :)

    ReplyDelete
  4. got Erro because i run frist on laptop--

    ReplyDelete
    Replies
    1. Hmm, the actual machine should make no difference, you had an out of virtual memory error, which is going to be a full disk... :(

      But hey ho, you got it working in the end :)

      Delete
  5. This comment has been removed by the author.

    ReplyDelete
    Replies
    1. yes. now i bulid like a boss on linux- did you look at how to do it on windows? eks this https://github.com/BlockchainDevelopmentCompany/boolberry.

      i watched your video on youtube and didnt work for me. thank you.

      Delete