Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How does the GNU license work?

I understand, that I am not allowed to do some modifications to Linux, then compile it, put it in CD and start selling or distributting without source code, right? But what about software that I develop for being used with Linux? Can I hide the source code of it and sell it? These thing are not clear to me.

share|improve this question

closed as off topic by heavyd, ChrisF, akira, quack quixote Jun 17 '10 at 16:45

Questions on Super User are expected to relate to computer software or computer hardware within the scope defined by the community. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about reopening questions here.If this question can be reworded to fit the rules in the help center, please edit the question.

this is better suited to a discussion forum. – quack quixote Jun 17 '10 at 16:46
Note: do not confuse the kernel called Linux (GPL license), with the operating system (large collection of separate programs) named GNU (GPL and other licenses), but very very often mistakenly called Linux. – richard Sep 19 '12 at 15:10
up vote 5 down vote accepted

I understand, that I am not allowed to do some modifications to Linux, then compile it, put it in CD and start selling or distributting without source code, right?

Correct and... because it's a copy-left license, if you create something based on the original source covered by this license, that must also be covered by the same license.

Ex. If you download the latest code from TuxBrowser and it's GPL, if you rewrite the internal engine and release a new browser TuxBrowserOnCrack it will also have to be released under GPL.

That's the reason why many people accuse this license of being 'viral' (IMHO, because it is).

Other terms include:

  • If you provide a binary, you must provide a means to make the source code available whether by providing it in the distribution package or by providing information on where to get it.
  • Or if you provide a binary you can choose to Not provide the source code with the binary package but you must provide a means to access the source code at a user's request.

By providing source code this includes all third-party packages/libraries or dependencies must also be available to the users so, any libraries you use with your software must also be under a licence that allows their source to be distributed.

I understand, that i am not allowed to do some modifications to Linux, then compile it, put it in CD and start selling or distributting without source code, right?

Wrong... you can, but first you need to:

  • make the it available under the same (GPL) license
  • give credit to the original source of the code that the work is derived from
  • include a copy of the license with the package
  • if the program is interactive (console app or GUI) it must display the copyright notice
  • the source code doesn't have to be distributed with the software but it does have to be made available at the user's request no matter how much it costs to you to make it available.

But what about software that I develop for being used with Linux? Can I hide the source code of it and sell it?

Yes, an application that runs on an operating system falls under the special exception. Plugins, or items that are loaded using a GPL licensed software don't automatically inherit the license.

If they did, it would be the equivalent of saying that:

  • if you loaded a photo in GIMP it automatically needs to be redistributed under GPL
  • if you created a plug-in script for a GPL software it would also have to be GPL
  • if you ran a rom in a GPL NES emulator the game would have to inherit the GPL

Even for a license that is as copy-left as GPL (which is traditionally the most copy-left) those requirements are beyond far-reaching; and, if that were the case, you wouldn't be able to use Firefox, Apache, or hundreds of other really popular Open Source applications because they're not licensed under the GPL.

So, in essence... You can sell GPL software all you want for however much you want. You just have to make the license known, make the license available, make sure all third-party libraries/dependencies can be distributed freely (GPL compatible), and make the source available. If you create any derived works from the source, they must follow all the same rules and inherit the same license.

That's why OpenSuse can be sold by Novell. Sure, Novell provides updates and a lot of extras on top of the Operating system when you're a paying customer but there's always a link somewhere on their site where you can download the source for free. They just won't offer any help or support to get it up and running. That's what the open source community is for.

Heres a link to the GPL v2 if you want the lawyer-speak version.

Here's a link to a human-readable explanation of GPL.

SideNote: If you're considering creating an Open Source original work not derived from GPL source I highly suggest you use a license more along the lines of Apache or MIT license, because they don't make people who derive their works off of yours inherit the same license. IMHO, viral licenses don't represent freedom in the truest sense because you don't have the freedom to create works based on them without being required to inherit them.

share|improve this answer
They do not give you real freedom, but they do preserve and guaranty freedom...something the BSD-License f.e. does not. Also, I think 'viral' is does not infect others/other works, only it's 'childs'. It's more similar to a gene then to a virus, imho. – Bobby Jun 17 '10 at 14:39
@Bobby that's why I included 'IMHO', it's more of a personal opinion. I have a lot of experience with open source projects (both as a user and as a developer) and I really don't like GPL. Requiring a license to be included in derived works goes against the idea of 'freedom' and only suits the interests of the FSF and Richard Stallman. If you don't get what I mean, look up the reasons why he created the FSF (and the MIT AI lab debacle). There's a reason the whole movement has such excessive 'religious' undertones. – Evan Plaice Jun 17 '10 at 14:49

WARNING: I'm not a lawyer!

The GNU GPL grants you the rights to

  • Use the program in any way
  • Study/Modify/Reuse the sourcecode
  • Selling support/work/other for the application (see Footnote)

but it needs you to

  • Always make the sourcecode available
  • If you change it, you must distribute the changes under the terms of this license

For your scenario, yes, you're allowed to develop and sell closed-source applications for Linux...but you're not allowed to use any GPL-Licensed sourcecode (or any other copyleft license for that matter) from other projects or Linux itself in it. F.e. GTK+ is licensed under the LGPL, which gives you the rights to use the toolkit for closed source application (linked against a binary), but you're still not allowed to alter and/or use the sourcecode of GTK+ itself.

Footnote: You're not allowed to sell allowed to charge a fee for a GPL application directly, you're, however, allowed to charge for your service, work and support (f.e. putting it on a CD, Hourly-charge for setting a Linux-Server up, Support-Contracts etc.). Still, you must make the sourcecode available to your clients.

share|improve this answer
"You're not allowed to sell a GPL application directly, you're, however, allowed to charge for your service, work and support" That's incorrect, you can charge to sell copies of the software under the terms of the license "General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for them if you wish)" (Quoted directly from GPL). – Evan Plaice Jun 17 '10 at 13:32
@Evan Plaice: I always understood it that way, that you're just allowed to charge for your own work, but not for the application itself (because it does not belong to you). – Bobby Jun 17 '10 at 14:32
Nope, that's not the case. See my answer for the specific details why. Specifically, check out the 'human-readable explanation of GPL' link at the bottom of the answer. Charging for service/support is only common because it is one of the only viable business models to actually make money from an open source project. – Evan Plaice Jun 17 '10 at 14:35
@Evan Plaice: Mh, good to know. Fixed it. – Bobby Jun 17 '10 at 14:42

WARNING: I too am not a lawyer!

To the best of my knowledge yes, you can build an application to run on top of Linux and sell distribute it without the source code. However, it is worth noting that because of the open source nature of linux if your application is consumer software and not enterprise, good luck getting people to purchase it.

share|improve this answer
I purchased my Free Software. – richard Sep 19 '12 at 15:12
Your comment doesn't help, and actually doesn't reflect reality in the market. Android devices run Linux kernels, they are consumer products and people buy them. – Daniel Baktiar Jun 25 '13 at 7:15

Not the answer you're looking for? Browse other questions tagged .