Bitcoin Forum

Bitcoin => Bitcoin Technical Support => Topic started by: bitfawkes on May 04, 2017, 03:58:46 PM



Title: how to build core wallet as standalone file
Post by: bitfawkes on May 04, 2017, 03:58:46 PM
Hello, I'm looking for a way to build a coin wallet for linux in standalone file, when I build any wallet it depends from library I use to compile it, and for example if I remove from system libdb5.1-dev the wallet doesn't start... It does't happens with precompiled daemon like bitcoind or dogecoind downloaded from ufficial page. I'm asking, what is the way to build a coin from source including all package it need? I don't find a tutorial or guide to do it, can someone help me?

thanks.

bitfawkes


Title: Re: how to build core wallet as standalone file
Post by: achow101 on May 04, 2017, 05:08:14 PM
In order for a standalone binary to work, it needs to be statically linked. Bitcoin Core does this through its depends system which builds all of the dependencies and statically links them to the Bitcoin Core binaries. However most altcoins don't do this because most altcoin devs do not understand all of the intricacies involved in making the Bitcoin Core releases.


Title: Re: how to build core wallet as standalone file
Post by: bitfawkes on May 04, 2017, 05:12:26 PM
In order for a standalone binary to work, it needs to be statically linked. Bitcoin Core does this through its depends system which builds all of the dependencies and statically links them to the Bitcoin Core binaries. However most altcoins don't do this because most altcoin devs do not understand all of the intricacies involved in making the Bitcoin Core releases.

You have been great in your explanation, can you in tell me a tutorial to link libraries statically? My target is to be able to compile any wallet and to run it in a system it have no libraries installed as bitcoin yet do.


Title: Re: how to build core wallet as standalone file
Post by: achow101 on May 04, 2017, 05:18:25 PM
You have been great in your explanation, can you in tell me a tutorial to link libraries statically? My target is to be able to compile any wallet and to run it in a system it have no libraries installed as bitcoin yet do.
Bitcoin Core builds the binaries through the gitian build system which you can read about here: https://github.com/bitcoin/bitcoin/blob/master/doc/gitian-building.md and here: https://github.com/bitcoin/bitcoin/blob/master/doc/release-process.md. If you use the same process for an altcoin (assuming that the dependencies and gitian descriptors are correct), then you will get standalone binaries.


Title: Re: how to build core wallet as standalone file
Post by: bitfawkes on May 04, 2017, 09:07:16 PM
You have been great in your explanation, can you in tell me a tutorial to link libraries statically? My target is to be able to compile any wallet and to run it in a system it have no libraries installed as bitcoin yet do.
Bitcoin Core builds the binaries through the gitian build system which you can read about here: https://github.com/bitcoin/bitcoin/blob/master/doc/gitian-building.md and here: https://github.com/bitcoin/bitcoin/blob/master/doc/release-process.md. If you use the same process for an altcoin (assuming that the dependencies and gitian descriptors are correct), then you will get standalone binaries.

You have been kindly, I appreciate. Have a nice time.