2013/04/09

[雜七雜八] Bitcoin build on Ubuntu 12.04


I started to pay attention on the Bitcoin that is from a news that discussed why bitcoin become strengthening. After weeks study and observation, I thought the bitcoin could be one of the real monetary in future.

More links are as following.
Bitcoin official site -> http://bitcoin.org/en/
Bitcoin howto in Chinese -> http://saving.cc/bitcoin/

The following article is quite earlier in Taiwan's news and it is also interesting.
Two years later today, the bitcoin's currency rush to 1BT:90USD because of the crisis of Cyprus.

We can understand the nature of the monetary and the pros/cons of the bitcoin from those articles. So I need not to talk more. What I wanna do is to study and share from the source code.

The code is managed by git and host on github and we can get it by git client tool.

The code structure of the bitcoin.



We can get the information in the README.md.


Build bitcoin on Ubuntu 12.04


# sudo apt-get install libboost-all-dev

We have to use the ppa to install the package we need.
# sudo add-apt-repository ppa:bitcoin/bitcoin

If the error occur, we have to reinstall the ca-certificates package.
# sudo apt-get install --reinstall ca-certificates

If we add the repository successfully, we can see following information.
# sudo apt-get update

Then we could install the db4.8 package on Ubuntu 12.04
# sudo apt-get install libdb4.8-dev
# sudo apt-get install libdb4.8++-dev

The default enable the USE_UNPN compile flag, and we have to install the upnp package.
# sudo apt-get install libminiupnpc-dev

Go bitcoin/src folder and make the bitcoin package.
# make -f makefile.unix

The 'bitcoind' is generated and we can start using the tool.
# ./bitcoind --help

Done!

沒有留言: