Pages:
Author

Topic: Proposal: make it so anybody could easily compile the client (Read 2561 times)

legendary
Activity: 1470
Merit: 1005
Bringing Legendary Har® to you since 1952

I've tried once to compile it. Gave up.

I don't understand why can't you bundle all the needed libraries and distribute the complete source code with the client?

1) You will get more trust. What's the point of doing code review if you can't compile a binary version from it?

2) You will get more developers involved. I, personally, can't spend several days, figuring out just how to compile it. But if it were a matter of loading it into VS and hitting Build, I might work on small features or optimizations.

And the most annoying is that I don't see any rational reasons not to do it! Why hasn't it been done from the beginning? Are you trying to impose some sort of an artificial "entry barrier"?


P.S. I am specifically talking about Windows.

It is more difficult to compile anything on windows by default.
If you want to EASILY compile things, move to an Open Source UNIX-like system (such as Linux), which is designed for ease of compilation by default.

However, having a proper ./configure script on UNIX/Linux wouldn't hurt. For now it is not possible to do the following on the Bitcoin client sources:

Code:
./configure
make
make install

Which is a little annoying. Other then that, compilation on UNIX is not problematic.
vip
Activity: 1386
Merit: 1136
The Casascius 1oz 10BTC Silver Round (w/ Gold B)
I finally got it to work, my issue was that I had two different versions of openssl, one with includes at /usr/local/include/openssl and the other with /usr/include/openssl, and they were managing to include one another's include files due to the way the include search path apparently works.  Would yield screenfuls of compile errors all related to ECDSA.  So removing one of them solved the problem.

SO yeah, that's not the fault of the Bitcoin project.  But having a list of the dependencies and the typical instructions to install them (either HTTP URL, git clone path, apt-get package name, etc.) in the README wouldn't hurt.
full member
Activity: 175
Merit: 102
I too am frustrated by difficulty getting this to compile (on Linux).

I too want to contribute a little here and there.  Even if the README was a bit of a HOWTO that said go get this, go get that, I'd do it.

I am hoping that someone will be able to walk me through getting past whatever is throwing me for a loop.  It looks related to OpenSSL.

http://pastebin.com/wYDFLzds

makefile.unix?  What OS are you compiling on?
sr. member
Activity: 322
Merit: 251
Well, I finally managed to create a stand-alone 1-click Windows build.

You can download it here (25 Mb):

http://qbizy.com/bitcoin-one-click-win-build-0.4.0rc2.7z

It's based on the latest official version (0.4.0 RC 2).

You will need Visual Studio 2005 to build it (if you'll manage to compile it in later versions - please post here).

--

The source code is not modified in any way, except one line in the "util.h" - I've added "typedef int pid_t;" because it didn't recognize this type.

The code that uses it should probably be #ifdef'ed with "__WXMSW__". Developers, please fix it!

Another thing - the "bitcoin.ico" converted to uncompressed format so VS's resource compiler would understand it.

Also, developers, please put the updated icon into the main distribution:

http://qbizy.com/bitcoin-vs2005-compatible-ico.zip

--

No UPNP yet. Is it important? No daemon too. Latest OpenSSL 1.0.0e is used instead of 1.0.0d.

EXE file size is 6 instead of 11 Mb.

Still tries to load "WMIApSrv" driver, same as the official client. Need to find how to turn this off...

To save space only the essential dependencies were included. For example, no debug libraries. All the added Windows stuff is in the single "windows" folder.

Comments and ideas appreciated.


You can submit a pull request to the core project on github, I believe.
vip
Activity: 1386
Merit: 1136
The Casascius 1oz 10BTC Silver Round (w/ Gold B)
I too am frustrated by difficulty getting this to compile (on Linux).

I too want to contribute a little here and there.  Even if the README was a bit of a HOWTO that said go get this, go get that, I'd do it.

I am hoping that someone will be able to walk me through getting past whatever is throwing me for a loop.  It looks related to OpenSSL.

http://pastebin.com/wYDFLzds
hero member
Activity: 966
Merit: 501
Leading Crypto Sports Betting & Casino Platform
+1 to Alex Zee point.


I never fiddled with the sources myself, because my time is too precious to waste trying to compile stuff.
member
Activity: 112
Merit: 10
Well, I finally managed to create a stand-alone 1-click Windows build.

You can download it here (25 Mb):

http://qbizy.com/bitcoin-one-click-win-build-0.4.0rc2.7z

It's based on the latest official version (0.4.0 RC 2).

You will need Visual Studio 2005 to build it (if you'll manage to compile it in later versions - please post here).

--

The source code is not modified in any way, except one line in the "util.h" - I've added "typedef int pid_t;" because it didn't recognize this type.

The code that uses it should probably be #ifdef'ed with "__WXMSW__". Developers, please fix it!

Another thing - the "bitcoin.ico" converted to uncompressed format so VS's resource compiler would understand it.

Also, developers, please put the updated icon into the main distribution:

http://qbizy.com/bitcoin-vs2005-compatible-ico.zip

--

No UPNP yet. Is it important? No daemon too. Latest OpenSSL 1.0.0e is used instead of 1.0.0d.

EXE file size is 6 instead of 11 Mb.

Still tries to load "WMIApSrv" driver, same as the official client. Need to find how to turn this off...

To save space only the essential dependencies were included. For example, no debug libraries. All the added Windows stuff is in the single "windows" folder.

Comments and ideas appreciated.
full member
Activity: 175
Merit: 102
Is it possible to make a bat that uses wget to download all sources? Grin

This is what my pushpool/bitcoin installer does. I can set up a new (Linux) pool server in minutes without having any of the dependencies on the machine.  No, I won't share it, it's a mess and is quite brittle Smiley

License questions aside, it can be difficult to include all the required dependencies for a project, particularly anything built in C++ on Windows.  Windows/MSVC runtime has a *&(@$ load of library dependencies it doesn't advertise that can bite you hard when deploying an application.  The redistributables do a good job of addressing 99.8% of the problems so usually just distributing the msvc redistributables will do the job, but then there are the edge cases...

Qt's full build is over 30 GB.  The core libraries (release) are only a couple hundred kb, but debug ones are about 10gb total.  Any developer will need the debug ones if they want to do their own compiling without worrying about dependencies.  I know of no place currently that will host binary lib drops that big, so cuts/choices would have to be made - a Qt GUI project could include only the QtGui.dll and QtGuid.dll files, which amounts to about 10 MB. But you wouldn't be able to link/include functionality from any other Qt libraries.

The situation is much simpler with the .NET Framework on Windows. It includes everything, and because you can run the framework installer as part of a setup package, you don't even need to include the framework, just include the redistributable installer.  And because with .NET, a dependency list is as simple as a list of DLL's you drop in your exe dir, including non-Framework libraries is trivial.

Remember, all this is licensing aside.  Redistribution is a hot topic in software licensing and you can get burned pretty badly by it if you're not careful.
legendary
Activity: 1862
Merit: 1011
Reverse engineer from time to time
I am glad to see a person who thinks like me.

+1 AlexZ!
member
Activity: 112
Merit: 10
Ok, what I will do is create a separate package with a single addition - a "windows" folder where I will put everything required to build it on Windows.

It's in the process of being merged.

That's kinda vague Smiley

When do you guys plan to make the official 0.5 branch?
staff
Activity: 4256
Merit: 1203
I support freedom of choice
Is it possible to make a bat that uses wget to download all sources? Grin
hero member
Activity: 812
Merit: 1022
No Maps for These Territories
Developers. Do just this step one: include all the source into the main branch. QT includes, what have you. All. No downloads required.
This is not possible license-wise. You can externally release a tarball with all source code and dependencies, if you make it clear that it includes project+dependencies.

However, including the source and headers of entire frameworks such as boost and Qt into the git branch would be extremely unwise and also wasteful of space. LGPL and GPL allow linking against, but not copying the files into your project, except by making the entire project (L)GPL.

If you don't believe that, name one project that does this...

Quote
But now I am confused, which version to work with. Is your bitcoin-qt going to be the new official master branch as is? Or will there be some kind of merging process?
It's in the process of being merged.
member
Activity: 112
Merit: 10
You raise valid points.

But if we want to attract more developers to Bitcoin, and not only "core full-time" developers, but people who will do minor optimizations and bug-fixes in their little spare time, we need to have a one-click setup. It's crucial.

Yes, a developer might use some other libraries, but they can be of different versions. And most importantly - our hypothetical developer probably wouldn't care if they will be duplicated in Bitcoin distribution.

He installed the Bitcoin client, he noticed a bug or had an idea for a "20-minute work" feature. All that he needs is to go to the "source", click on solution, make some tweaks in code, fix a bug, whatever, and compile himself a new binary.

If he is required to spend 40 minutes on top of those 20 minutes just to make it compile, he might just give up.

So, Ok, if there are nobody else to do a full Windows build, I will do it.

But now I am confused, which version to work with. Is your bitcoin-qt going to be the new official master branch as is? Or will there be some kind of merging process?

hero member
Activity: 812
Merit: 1022
No Maps for These Territories
Because you already have all the libraries installed! You already have it set up!
No I don't. I don't even have Visual Studio and rarely use Windows. And when I do I use the Qt SDK with Qt Creator, for which I also published the four simple steps for building in the README file...

Quote
Why don't you just publish the whole project, not just a part that requires lots of dependencies?
Because on non-windows platforms it is not normal to bundle all the libraries a project makes use of. They are installed as separate packages.

Even on Windows, many people already use the libraries such as boost and openssl so have them installed in their own locations.

Releasing a tangle of source files that include copied boost, upnp, openssl headers and source files would certainly be useful for some people, but could also create more problems than it's worth.

Quote
If you dare me, hell, sure, I can do it. I would be glad to help all the future possible developers who might want to get involved.
Yes, maybe you should do that. That's a much better attitude Smiley
hero member
Activity: 518
Merit: 500
You realize those libraries might be published under different licenses, some of which would prevent him from redistributing them? I dont know if its the case here, but you usually cant just go and put "everything thats needed" in a tarball for your convenience.

BTW, I just compiled bitcoin-qt. Copy pasted 3 commands (yes, I use linux) and its working and looking great. Thank you John Smith.
member
Activity: 112
Merit: 10
Let's make it practical.

If you don't have time to create VS projects - let me do it.

Developers. Do just this step one: include all the source into the main branch. QT includes, what have you. All. No downloads required.

I will do the projects.
member
Activity: 112
Merit: 10
Then why not do it and contribute the result, to save "all those many other people" the work.

Oh wait, this is just about you.

Because you already have all the libraries installed! You already have it set up!

Why don't you just publish the whole project, not just a part that requires lots of dependencies?

If you dare me, hell, sure, I can do it. I would be glad to help all the future possible developers who might want to get involved.

It just would be much easier for you, since you already have it on your machine.

Besides, the "full" distribution should be supported by those, who work on it "full time".

It would be cumbersome for me to follow your release schedule and update a stand-alone "full" package for others.

hero member
Activity: 812
Merit: 1022
No Maps for These Territories
It's funny how such a simple thing as bundling all the libraries, since you already have them, and creating projects for them becomes an "unreasonably high requirement".
Then why not do it and contribute the result, to save "all those many other people" the work.

Oh wait, this is just about you.

member
Activity: 112
Merit: 10
It's funny how people's requirements can become unreasonably high so quickly when they're not paying for something.

It's funny how such a simple thing as bundling all the libraries, since you already have them, and creating projects for them becomes an "unreasonably high requirement".

Of course, it's better to not include them for no reason whatsoever and then force everyone who will try to help you develop the project to spend time jumping from site to site, searching for the exact versions, downloading and placing into proper folders and doing the whole setup again.

"Come on in, developers, help me develop it! But you need to dance for an hour and upload the video of your dance on YouTube, before I let you work on my project!"

That's a cool attitude. It goes great with "hey, I am not being paid, so I am free to do a crappy job".
member
Activity: 112
Merit: 10
I'm now seeing it as an offense you're trying to invade my time. Welcome to my ignore list.

Developers are few and people who will be using their project are many. That's enough reason to try and make it as easy for them as possible, to save their time and not yours.

But whatever.
Pages:
Jump to: