Pages:
Author

Topic: Building headless Bitcoin and Bitcoin-qt on Windows - page 11. (Read 419389 times)

sr. member
Activity: 444
Merit: 250
I prefer evolution to revolution.
After a pauze of 5-6 weeks... (all this code really drove me insane after a while) I finally managed to compile bitcoin and litecoin qt static.. Works like a charm  Grin

After failing over and over again on windows 7 (never again Tongue ), I tried windows 8.1. And after the first try it was already done. Very happy with this Smiley

Thanks a lot for this guide, and all the help from the other members  Smiley

Cheers,


Banzai

Teach Me! I am using Windows 10! I am trying to compile Crave! (PM If Possible)
PM is not an ideal way to help.  All the problems are undoubtedly going to affect others.  If you keep it public then everyone can see the solutions.

I think if you want someone to teach you, offering an hourly rate - even "just for starters, to see if I like how you teach" would work well for both parties.

If you can explain a specific problem that you run into, then someone here will provide an answer.  Some people might just answer RTFM, and if they have any sense, they'll also provide you with a link (to TFM) and maybe even some terms you could use in a search engine to find other links.

My best advice (other than the general stuff I just wrote above) is to compile bitcoin according to Nitro's OP first.  If you've already got that working, then copy the src and start altering it to be like the other thing you're trying to compile - baby steps - so when you hit a change that causes a problem, you'll know what difference caused the problem.
newbie
Activity: 56
Merit: 0
Had never tried qt client.
I will make a try.
Didnt worked for me.
Shall give a once more try.
legendary
Activity: 1526
Merit: 1002
Chipcoin Developer
Are you Dutch irritant? If so, I can try and help you in Dutch Wink I am not a pro coder.. But I have seen a lot of compile issues the last few weeks/months Grin Cheesy


Next step for me is compiling with Qt 5.3.2. Hope I can work this out... Things go a little bit different in the newer source.. instead of a .pro I only see autogen.sh and confgure.ac.. Diving back into the tutorial and sourcecode.. Fingers crossed  Grin


Cheers,

Banzai

EDIT: Well that was easy.. Only had one error with upnp.. After I disabled it in bitcoin_config.h everything went great  Smiley
sr. member
Activity: 473
Merit: 250
Sodium hypochlorite, acetone, ethanol
After a pauze of 5-6 weeks... (all this code really drove me insane after a while) I finally managed to compile bitcoin and litecoin qt static.. Works like a charm  Grin

After failing over and over again on windows 7 (never again Tongue ), I tried windows 8.1. And after the first try it was already done. Very happy with this Smiley

Thanks a lot for this guide, and all the help from the other members  Smiley

Cheers,


Banzai

not me, im still going insane  Cheesy
legendary
Activity: 1526
Merit: 1002
Chipcoin Developer
After a pauze of 5-6 weeks... (all this code really drove me insane after a while) I finally managed to compile bitcoin and litecoin qt static.. Works like a charm  Grin

After failing over and over again on windows 7 (never again Tongue ), I tried windows 8.1. And after the first try it was already done. Very happy with this Smiley

Thanks a lot for this guide, and all the help from the other members  Smiley

Cheers,


Banzai
full member
Activity: 131
Merit: 108
Thanks, nitrogenetics for keeping this guide updated; it did help me track down an issue trying to compile a coin based on Bitcoin 0.8. Though I noticed a few things that probably should be noted from the shift to version "L" of OpenSSL 1.0.1 from version "J":
Not so up to date, but still working. In the next update I'll replace msys with msys2 Wink

In the 0.8 headless client modifications to the "makefile.mingw" file, you still have references to "openssl-1.0.1j" that should be updated to "openssl-1.0.1l".
As specified, openssl v1.0.1k and later may lead to consesus forks when used with older unpatched bitcoin code releases. http://sourceforge.net/p/bitcoin/mailman/message/33221963/

Also, when compiling OpenSSL (step 2.1) after running the "./Configure" command, the output from that command suggests running "make depend" first, before running "make", which should probably be part of the instructions? My compile of OpenSSL actually failed out, while parsing the "test" directory (ideatest.c:1:1: error: expected identifier or '(' before '.' token, ../crypto/idea/ideatest.c), but all the source files got properly built before that, so it didn't affect final compilation. Is there a flag to turn off running tests of OpenSSL?
Openssl always suggest doing a make depend when disabling algorithms. Configure options are the same as in https://github.com/bitcoin/bitcoin/blob/master/depends/packages/openssl.mk, so they should be well tested.
Tests should not run unless you do a make test.

Its mentioned a few times to make sure various things are on in your PATH variable, and an example is shown in the compiling the GUI/Qt step of how to do that in the command prompt, but it's not shown for the MSYS shell; it might be useful to spell it out specifically that to add the MinGW binaries to your PATH in MYSYS, do:

Code:
PATH=/c/mingw32/bin:$PATH

But to add them to your PATH in a standard command prompt (which is needed for compiling the QT 4.8 library), do:

Code:
set PATH=C:\mingw32\bin;%PATH%
Msys will automatically set environment variables from the current windows setup, so just adding your toolchain bin folder to windows PATH should be enough.
When using qt5 submodules after compiling the base package a 'set PATH=%PATH%;C:\Qt\5.3.2\bin' will be needed in order to have qmake, lrelease, etc available for qt-tools build.
This is not necessary for qt4.8 (available as full package only).

Also, compiling QT 4 requires Perl be installed; my Windows 8.1 box didn't have that by default, so a link to http://www.activestate.com/activeperl might be useful.
Perl will only be required when compiling qt with qt-webkit enabled.

You mention commenting out the "genleveldb.commands" in the "bitcoin.pro" project file, but if you do that, you should probably also comment out the "QMAKE_CLEAN" line, which attempts to delete the "libleveldb.a" file when a "clean" action is run.
Yes, qmake clean will fail for leveldb and can be probably commented out also (doesn't make a big difference, whereas genleveldb.commands would stop the build process).
sr. member
Activity: 293
Merit: 251
Director - www.cubeform.io
Is it possible to do a one click compile on windows yet or not? The process is too painful.

If you need 'one click' why not just download the official binary instead of compiling?

What I mean is that in Java I just type mvn package or ant jar, which takes care of everything. Something like this would be great for Bitcoin-qt.



While out of date now, there was the short lived https://bitcointalksearch.org/topic/ann-easywinbuilder-the-easy-way-to-build-bitcoin-on-windows-252931.
sr. member
Activity: 260
Merit: 251

What I mean is that in Java I just type mvn package or ant jar, which takes care of everything. Something like this would be great for Bitcoin-qt.


There's always Bitcoinj
https://github.com/bitcoinj/bitcoinj

But if you want QT, you just have to
accept -- ickiness (Sorry, Ron!  Cheesy)
Ah Yarkol, but did you see
https://bitcointalksearch.org/topic/m.4489334
and
https://bitcointalk.org/index.php?topic=349094.0;all from almost a year and a half ago?

Ron

legendary
Activity: 996
Merit: 1013

What I mean is that in Java I just type mvn package or ant jar, which takes care of everything. Something like this would be great for Bitcoin-qt.


There's always Bitcoinj
https://github.com/bitcoinj/bitcoinj

But if you want QT, you just have to
accept -- ickiness (Sorry, Ron!  Cheesy)
legendary
Activity: 1001
Merit: 1005
Is it possible to do a one click compile on windows yet or not? The process is too painful.

If you need 'one click' why not just download the official binary instead of compiling?

What I mean is that in Java I just type mvn package or ant jar, which takes care of everything. Something like this would be great for Bitcoin-qt.

sr. member
Activity: 293
Merit: 251
Director - www.cubeform.io
Is it possible to do a one click compile on windows yet or not? The process is too painful.

If you need 'one click' why not just download the official binary instead of compiling?
legendary
Activity: 1001
Merit: 1005
Is it possible to do a one click compile on windows yet or not? The process is too painful.
member
Activity: 68
Merit: 10
Thanks, nitrogenetics for keeping this guide updated; it did help me track down an issue trying to compile a coin based on Bitcoin 0.8. Though I noticed a few things that probably should be noted from the shift to version "L" of OpenSSL 1.0.1 from version "J":

In the 0.8 headless client modifications to the "makefile.mingw" file, you still have references to "openssl-1.0.1j" that should be updated to "openssl-1.0.1l".

Also, when compiling OpenSSL (step 2.1) after running the "./Configure" command, the output from that command suggests running "make depend" first, before running "make", which should probably be part of the instructions? My compile of OpenSSL actually failed out, while parsing the "test" directory (ideatest.c:1:1: error: expected identifier or '(' before '.' token, ../crypto/idea/ideatest.c), but all the source files got properly built before that, so it didn't affect final compilation. Is there a flag to turn off running tests of OpenSSL?

Its mentioned a few times to make sure various things are on in your PATH variable, and an example is shown in the compiling the GUI/Qt step of how to do that in the command prompt, but it's not shown for the MSYS shell; it might be useful to spell it out specifically that to add the MinGW binaries to your PATH in MYSYS, do:

Code:
PATH=/c/mingw32/bin:$PATH

But to add them to your PATH in a standard command prompt (which is needed for compiling the QT 4.8 library), do:

Code:
set PATH=C:\mingw32\bin;%PATH%

Also, compiling QT 4 requires Perl be installed; my Windows 8.1 box didn't have that by default, so a link to http://www.activestate.com/activeperl might be useful.

You mention commenting out the "genleveldb.commands" in the "bitcoin.pro" project file, but if you do that, you should probably also comment out the "QMAKE_CLEAN" line, which attempts to delete the "libleveldb.a" file when a "clean" action is run.
sr. member
Activity: 260
Merit: 251

Managing a coin, developing a coin, and building a Win/Mac wallet are
different things altogether.

In practice there exists a natural division of labor, so you can concentrate
on either promoting or coding and leave all this icky windows stuff to a specialist.
Hello Yarkol,

How can you say icky, when I thought I took all the ick out in my videos, https://www.youtube.com/channel/UCytoaHvG3H1y9CnxZS819eQ.  Note that there is no specific/required/special directory mentioned!  You can have anything anywhere,  etc. etc.

Ron
legendary
Activity: 996
Merit: 1013

Managing a coin, developing a coin, and building a Win/Mac wallet are
different things altogether.

In practice there exists a natural division of labor, so you can concentrate
on either promoting or coding and leave all this icky windows stuff to a specialist.
full member
Activity: 219
Merit: 102
if you cannot properly/easily compile a client you should not be running an alt coin or developing a coin unless it is just for your own instructional purposes.   The best way to learn is to learn to compile bitcoin first. Then learn to compile litecoin. These are the basics.

This attitude is why PGP was such a failure and why we don't have email encryption as standard. Roll Eyes
legendary
Activity: 1148
Merit: 1018
It's about time -- All merrit accepted !!!
sorry for drifting off topic here but....


please consider this....


if you cannot properly/easily compile a client you should not be running an alt coin or developing a coin unless it is just for your own instructional purposes.   The best way to learn is to learn to compile bitcoin first. Then learn to compile litecoin. These are the basics.

This being said before you even consider running a coin please listen to these two people who I think are pretty smart......
(if you don't think what I say credible or responsible advice I hope you believe them)

Gavin Andresen

https://bitcointalksearch.org/topic/m.2037447

Peter Todd

https://bitcointalksearch.org/topic/m.1952356




Anyone can help
try to build windows wallet from https://github.com/bananabits/bananabits

This error drive me crazy.

You need to compile secp256k1. https://github.com/bitcoin/secp256k1
sr. member
Activity: 293
Merit: 251
Director - www.cubeform.io

Anyone can help
try to build windows wallet from https://github.com/bananabits/bananabits

This error drive me crazy.

You need to compile secp256k1. https://github.com/bitcoin/secp256k1
hero member
Activity: 564
Merit: 516


If the data directory does exsist, is there a conf file inside of it?
The client automatically closes and tells you that you need to add rpc username and pass to the conf file, if it isn't there or if the conf file isn't present. Unlike the data directory, it does not create this for you. If the data directory is there, and the conf file isn't, this might be a candidate -- although like most issues, it should be telling you the problem, and if Im not mistaken debug.log should already be generated at this point.






Actually it wont do this unless you run the server tag or if you are running the daemon file. If you are in console only tho, the qt is never going to run :-P
sr. member
Activity: 638
Merit: 250
Pages:
Jump to: