Binary vs. source code

Programming, for all ages and all languages.
User avatar
Brendan
Member
Member
Posts: 8561
Joined: Sat Jan 15, 2005 12:00 am
Location: At his keyboard!
Contact:

Re: Binary vs. source code

Post by Brendan »

Hi,
iansjack wrote:
Brendan wrote:OS developers who use existing tools and techniques to implement things they've seen in existing OS designs (e.g. *nix clones) are like the children who follow others. They will never be the first to get anywhere because they are following someone that is moving faster and/or had a huge head start. If you're trying to make an OS that other people will actually want to use, this is completely pointless.
Fine words, but I can't help but think "What about Linux? What about OS X?" Both operating systems built with existing tools implementing things seen in existing OS designs. And both, I would venture to say, OSs that other people want to use. The truth is that I can't think of many other OSs that people do want to use (not in numbers anywhere near as large as these two) - except, of course, for Windows.
When Linux started, BSD was in legal trouble (and a lot of its developers moved to safer ground at the time) and GNU (who already did most of the user-space work) needed Linux as a weapon to use against commercial Unix. The GNU/Linux combo sucked for many years and (for desktop/server) still doesn't have much market share despite being the cheaper than both of their major competitors. Eventually, someone (Google) took it and threw away the *nix user-land, developed their own virtual machine layer (Dalvik) and a lot of other stuff, and now that it isn't a *nix clone Android is everywhere.

Apple created their own GUI, their own APIs, their own file formats, their own languages (e.g. Objective-C, Xcode), their own tools, their own applications, their own hardware, etc. They never really have "followed".

Microsoft are similar - they created their own everything except hardware (APIs, file formats, languages, tools, etc) themselves.

These are probably the 4 most well known OSs (Windows, OS X, Android and iOS) and none of them are "followers".


Cheers,

Brendan
For all things; perfection is, and will always remain, impossible to achieve in practice. However; by striving for perfection we create things that are as perfect as practically possible. Let the pursuit of perfection be our guide.
User avatar
Owen
Member
Member
Posts: 1700
Joined: Fri Jun 13, 2008 3:21 pm
Location: Cambridge, United Kingdom
Contact:

Re: Binary vs. source code

Post by Owen »

iansjack wrote:We still have the question that I raised earlier, but everyone seems to be studiously avoiding, of producing binaries that are tailored to a particular user's needs. A good example would be a highly configurable program like Apache. With source code you can produce a version configured to your exact needs which will be a nice lean, efficient binary. Without the ability to configure the binary I think we are left with the Windows model of huge do-it-all programs that can be configured to do what you want but contain loads of code that any given user will never need. I believe this leads to the phenomenon known as "bloatware"; the very opposite of what I would like to produce.

Another good example is the Linux kernel. That provided with most distributions is a bloated version, with many options enabled that I don't need and a host of modules that will never see the light of day but just lurk hidden somewhere on my hard disk. On the other hand, my Gentoo install has a kernel compiled specifically for my hardware and my needs. There are very few modules as the hardware I need to support is compiled into the kernel; I know I need it, so let's not piss about with modules. It loads far quicker than the bloated, monolithic version, it is more efficient, and it knows how to make the most of my processor - it knows what processor it is going to run on, so it knows exactly what registers and instructions are available and how to optimize the code. It is, without doubt, a better kernel than that supplied with - say - Ubuntu.
Great job picking two examples which are both modular! Neither distribution shipped Apache nor distribution shipped Linux are any more "bloatware" than the one you built because they only load the modules which they need (Sure, the modules are resident on the users' hard disk. The entire source code of Linux is resident on yours)

Now, efficiency, I ask you: Have you ever benchmarked the difference? No? Please, go and do so (in terms of either CPU cycles or energy consumed). Lets pick a period of, say, 1 month (approximate time between Linux kernel security updates?)

Done? Now, I ask you this: Over that period of time, has recompiling your kernel for your exact hardware actually been a net positive over somebody compiling the kernel for a million machines?

And, even in the unlikely case that it has: Is that miniscule increase in performance resulted in sufficient gains to justify the time you spend reconfiguring and recompiling your kernel?
User avatar
iansjack
Member
Member
Posts: 4706
Joined: Sat Mar 31, 2012 3:07 am
Location: Chichester, UK

Re: Binary vs. source code

Post by iansjack »

I think you overestimate the work involved in rebuilding the kernel to your particular requirements. A configuration, once arrived upon, can be applied to later compiles trivially. And as for the input involved - make; make install; make modules_install. It's not a big deal, and I don't have to sit and watch the progress of the 5-minute compile.

You are correct that the source code is on my disk - for the duration of the compile.

And no, I haven't done meticulous timings of the difference - a watch with a second hand suffices to time the difference in boot times between my optimized Gentoo install and my generic Fedora one.

In the end it is, to me, a matter of choice. Give me the source code and I can choose to configure it for myself or I can accept the generic binary that you (or someone else provides). Give me just the binary and I am stuck with your choices. It's the Microsoft philosophy versus the GNU one; I prefer the latter. Do it my way and we can both have what we want.
Kevin
Member
Member
Posts: 1071
Joined: Sun Feb 01, 2009 6:11 am
Location: Germany
Contact:

Re: Binary vs. source code

Post by Kevin »

Brendan wrote:From my perspective; source code is only really useful for developers, means larger downloads for users, is slower to install, tends to have more dependencies (the tools used become dependencies), and can be a serious barrier for commercial application and device driver developers who (whether we like it or not) prefer closed source.
You don't mean commercial, but proprietary.

And I disagree with device driver developers prefering closed source. Yes, there are hardware vendors who employ driver developers and tell them to produce closed source drivers (which doesn't say anything about what the developers themselves would want), but I dare say that for the majority of hobby OSes in this community, the hardware vendors don't write the drivers anyway. So the relevant driver developers are the members of this community, and I doubt that all of them prefer closed drivers.
Developer of tyndur - community OS of Lowlevel (German)
Antti
Member
Member
Posts: 923
Joined: Thu Jul 05, 2012 5:12 am
Location: Finland

Re: Binary vs. source code

Post by Antti »

iansjack wrote:We still have the question that I raised earlier, but everyone seems to be studiously avoiding, of producing binaries that are tailored to a particular user's needs.
Uncomfortable questions are put aside. However, I think this same could be done with binaries also. If we had a relatively small main executable and modules that are loaded on demand, we would have a very non-bloatware application. You will need to recompile your application if you want to use a feature you did not include into your first build.

Do you think your custom-compiled application has any kind of warranty? This might be a little bit far-fetched but if thinking mission-critical applications, it is still a valid point.
User avatar
iansjack
Member
Member
Posts: 4706
Joined: Sat Mar 31, 2012 3:07 am
Location: Chichester, UK

Re: Binary vs. source code

Post by iansjack »

Do you think your custom-compiled application has any kind of warranty?
I'd imagine the same laws apply as to pre-compiled software. Otherwise it's up to the publisher. Irrelevant, of course, when talking of free software.
Kevin
Member
Member
Posts: 1071
Joined: Sun Feb 01, 2009 6:11 am
Location: Germany
Contact:

Re: Binary vs. source code

Post by Kevin »

I'd be more intersted in why there is an inherent difference in this respect between free and non-free software. (I think we're talking about "speech" here, but I believe for "beer" it doesn't make a difference either.)
Developer of tyndur - community OS of Lowlevel (German)
User avatar
iansjack
Member
Member
Posts: 4706
Joined: Sat Mar 31, 2012 3:07 am
Location: Chichester, UK

Re: Binary vs. source code

Post by iansjack »

I may be mistaken, and the situation probably differs in different countries, but most countries have legislation covering the fitness for use of goods and services. What we might call a warranty. I don't believe there is an obligation for free goods or services to be fit for purpose. Hence the distinction between free and paid for is, I think, relevant to Antti's question.
Kevin
Member
Member
Posts: 1071
Joined: Sun Feb 01, 2009 6:11 am
Location: Germany
Contact:

Re: Binary vs. source code

Post by Kevin »

As far as I know, there is no difference in this respect under German law. My uninformed guess would have been that something like this must be the same in all Europe, but perhaps it's not.
Developer of tyndur - community OS of Lowlevel (German)
User avatar
iansjack
Member
Member
Posts: 4706
Joined: Sat Mar 31, 2012 3:07 am
Location: Chichester, UK

Re: Binary vs. source code

Post by iansjack »

Consumer laws in the UK relate to what happens when you "buy" goods. If you don't pay for them you can hardly be said to buy them. On the other hand, no doubt the "vendor" would be duty bound to recompense you to the full value that you paid for the goods (or rather didn't pay).
Antti
Member
Member
Posts: 923
Joined: Thu Jul 05, 2012 5:12 am
Location: Finland

Re: Binary vs. source code

Post by Antti »

iansjack wrote:I'd imagine the same laws apply as to pre-compiled software. Otherwise it's up to the publisher. Irrelevant, of course, when talking of free software.
It is irrelevant when talking of free software because that is always "no warranty" and that would be an interesting topic in itself. Actually I am quite worried about the fact that software is widely considered as "no warranty of any kind" and people are so used to it. When it comes to a source release, it is quite hard to guarantee its functionality. I would not dare to give a warranty if I were a publisher.
User avatar
iansjack
Member
Member
Posts: 4706
Joined: Sat Mar 31, 2012 3:07 am
Location: Chichester, UK

Re: Binary vs. source code

Post by iansjack »

You get consumer rights with self-assembly furniture (well, you do in the UK). Why not with self-assembly software?
User avatar
bwat
Member
Member
Posts: 359
Joined: Fri Jul 03, 2009 6:21 am

Re: Binary vs. source code

Post by bwat »

iansjack wrote:Consumer laws in the UK relate to what happens when you "buy" goods. If you don't pay for them you can hardly be said to buy them. On the other hand, no doubt the "vendor" would be duty bound to recompense you to the full value that you paid for the goods (or rather didn't pay).

From http://www.simkins.co.uk/ebulletins/Fit ... a2013.aspx
Also, where provided under a contract (whether for a price or for free), the digital content must not cause damage to other digital content
In that document software is defined as digitial content. I don't know just how reliable this all is but it does look like there is a warranty of sorts for gratis software in the UK. I'm no expert just interested in it all so take what I write with a pinch of salt.


EDIT: Ooops it's a draft bill, so not law yet.
Last edited by bwat on Fri Nov 29, 2013 12:01 pm, edited 1 time in total.
Every universe of discourse has its logical structure --- S. K. Langer.
Antti
Member
Member
Posts: 923
Joined: Thu Jul 05, 2012 5:12 am
Location: Finland

Re: Binary vs. source code

Post by Antti »

iansjack wrote:Why not with self-assembly software?
It is possible if the toolchain is really reliable. How can I say whether it is or not if we are using general programming languages and there are hundreds of compilers (including almost infinite number of configurations if compilers itself are compiled from sources) available. Of course, I could say that the warranty is valid if you only use some very specific platform and compiler to compile software. In practice, there is no warranty of any kind.
User avatar
bwat
Member
Member
Posts: 359
Joined: Fri Jul 03, 2009 6:21 am

Re: Binary vs. source code

Post by bwat »

Antti wrote: Actually I am quite worried about the fact that software is widely considered as "no warranty of any kind" and people are so used to it. When it comes to a source release, it is quite hard to guarantee its functionality. I would not dare to give a warranty if I were a publisher.
You probably couldn't get an company to insure your product(*) which means that your business(+) wouldn't have enough money to pay damages to users so, essentially, there might be a warranty but users are not getting any money.

*) I can't recall ever seeing such an insurance product when I was shopping for professional insurance a few years back.
+) Only a fool would be in a position where they were personally liable.
Every universe of discourse has its logical structure --- S. K. Langer.
Post Reply