15

I'm working on a personal project that I'm planning on licensing under GNU Affero GPL. However, I found some code that's licensed under MIT that really want to utilize, but I'm not sure what I should do about licensing.

The rest of the code will be mine under GNU Affero, it's just a source file and a header file that I'm utilizing that's licensed under MIT.

I've read this Q here on Programmers about MIT/GPL code working together, and this one on SO about software under MIT using GPL libraries, as well as several others, but I'm still not entirely clear on what I should do with the licensing.

As far as I can tell, all I need to do is leave the MIT license on the library and include a note in the license file about the two different licenses and what code they apply to, is that correct?

RPiAwesomeness
  • 259
  • 2
  • 5
  • 2
    Maybe a duplicate: http://programmers.stackexchange.com/questions/204410/how-are-gpl-compatible-licenses-like-mit-usable-in-gpl-programs-without-being-su – Doc Brown Apr 21 '16 at 14:18
  • 4
    Oh, the irony of using the most restrictive possible copyleft license, while appropriating code from one of the least restrictive. – Robert Harvey Apr 21 '16 at 14:48
  • @RobertHarvey, It's the one disappointment I have with the MIT license. I'd love a version that lets people do whatever they want with my OS code, save use it in a GPL'ed project, but I've never found one. – David Arno Apr 21 '16 at 15:25
  • 2
    One choice might be to license your code under MIT, which would simplify everything. Do you _really_ need to protect your code with a restrictive license? And if you feel strongly about the goals of GPL, why are you using non-GPL code in your project? – Bryan Oakley Apr 21 '16 at 15:26
  • 6
    @DavidArno: to me, free is free. When I use MIT, you're welcome to use my code however you want, _including_ using it with GPL code. And if you get rich off of my code, I'll simply applaud your success. – Bryan Oakley Apr 21 '16 at 15:27
  • 1
    @BryanOakley, completely agree regarding getting rich off it. Good for them. I just get irritated with the idea of someone taking a open piece of software and wrapping it up in a restrictive GLP solution. It doesn't irritate me enough to stop using it though. :) – David Arno Apr 21 '16 at 15:35
  • 2
    @DavidArno: hah, yeah. I don't understand the whole "I want my code to be open, but I want to restrict how you use it" mentality. "Either make it open or don't" is how I look at it. The vast, vast, _vast_ majority of code isn't worth protecting anyway, so I don't understand why so much energy is putting toward protecting it. – Bryan Oakley Apr 21 '16 at 15:44
  • 1
    @DavidArno I can see why that's annoying, but from what I understand *that* code is still licensed under MIT, it's just *my* code that's licensed under GPL. – RPiAwesomeness Apr 21 '16 at 15:52
  • @BryanOakley: the reasoning behind this is "if I give you my code, you give my yours". – Doc Brown Apr 21 '16 at 18:28
  • 2
    @DocBrown: it's also like saying "here's a gift. Where's mine?". Altruism shouldn't come with restrictions IMHO. – Bryan Oakley Apr 21 '16 at 18:33
  • 2
    @BryanOakley you completely miss the point of GPL. If I make something open source I don't want someone using it in a proprietary solution and restricting users from doing whatever they want with the software. – Killah Jan 15 '17 at 11:57
  • GPL is about user freedoms, MIT is about developer freedoms. It's demagogy to claim one is absolutely more restrictive than another without specifying the part where it is more restrictive and to whom. – Avamander Dec 16 '17 at 17:04
  • It's disappointing to have such comments from Robert Harvey and Bryan Oakley. No one is looking for a philosophical opinion here, however misinformed. These licenses are for law. The only worthwhile opinions is whether it's legal or not, and how to do things legally. The copyright holder intentionally selected a license so that others will use as per the license -- your disapproval only clouds the issue. – zumalifeguard Aug 06 '21 at 16:47

1 Answers1

8

AFAIK, the typical GPL variants apply only to your work "as a whole", and the MIT license is "compatible" with GPL. That means, if parts of your program are under MIT license, that is fine, as long as you do obey to the terms of the MIT license for that part (which is what you have in mind). And the only requirement that license states is

... "The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software."...

Most Linux systems contain MIT licensed parts (like the X Window System) which are under MIT license. The GPL only applies to Linux "as a whole", not to the individual MIT licensed parts. Same will be true for your program if you combine those two licenses in a similar manner.

Doc Brown
  • 199,015
  • 33
  • 367
  • 565
  • 1
    So I don't have to anything special other than include a note in the license file that the project uses a MIT license for parts? – RPiAwesomeness Apr 21 '16 at 14:23
  • @RPiAwesomeness: either that, or you include the copyright and permission notice as part of the header & source file. – Doc Brown Mar 08 '17 at 21:47